Jump to content

Background downloads not always working


Bazzu85

Recommended Posts

Bazzu85

Hi,

I'm on Oppo Find X2 Lite with android 11.

This is the current situation:

image.png.4a6903af200f7023ca7f55748ec696d4.png

image.png.f5a89eaf040cea58c5106e0fd50bd393.png

image.png.46c2ec9bf6e8096ac3d7aedb218a9f18.png

image.png.c2698a0c115bfe01ade6c38a8ccd8a88.png

Ep 9 and 10 was watched this morning on the Chromecast TV. 

From yesterday the android mobile app isn't been touched/opened. The battery optimisation is setted to "don't optimise".

I expect to have the episode 11 downloaded at this moment without have to open the app..

suggestions?

Link to comment
Share on other sites

Hi, What happens if you open the app so it can communicate with the server?

Link to comment
Share on other sites

Bazzu85
50 minutes ago, cayars said:

Hi, What happens if you open the app so it can communicate with the server?

The download starts..

I see now that the battery optimisation is setted to "always ask" and not to "don't optimise" like yesterday..

Googling a little maybe I found a bug in ColorOs that reset the battery optimisation settings..

I'll update tomorrow

Link to comment
Share on other sites

You can't swipe close the app or the Android OS will not run the app's  registered background process. 

That doesn't mean you have to keep the app on top in the foreground, its' OK to move it to the background, but you just can't force close it.

Link to comment
Share on other sites

Bazzu85
19 hours ago, Luke said:

You can't swipe close the app or the Android OS will not run the app's  registered background process. 

That doesn't mean you have to keep the app on top in the foreground, its' OK to move it to the background, but you just can't force close it.

as far as I know, if you put the app in background and swipe close from the recent app menu, the app still runs in background. At this moment the android battery optimisation do his work.

This morning I fixed the oppo battery optimisation bug. If you keep active the "Sleep standby optimisation", ColorOs overnight reset the user battery optimisation. So in the past nights emby was reverted always to "always ask" from "don't optimise".

BTW this morning emby is still in "don't optimise" mode. And is not in the recent apps.

Watched 2 episodes of synced shows and after an hours, not downloads.

So I made a test, from the tablet I added a new show to the oppo downloaded one, and on phone the downloads started..the app was closed from yesterday..

So can you explain how the background downloads works? Are there differences between update a current download or download a new entry?

thx as always

edit:

Today I made some test on the downloads..here's the results with app  in "don't optimise" mode and not in the recent apps.

The use case is this: https://imgur.com/a/5efNOCc

Test 1. Mark the episode as played. I expect that the next episode will be downloaded. result: No automatic download https://imgur.com/a/VUysytE

Test 2: after test 1, entered in the download and clicked Save: result: No automatic download https://imgur.com/a/zPF8zXI

Test 3: after test 2, set the number of episode to download from 1 to 2. result: automatic download triggered https://imgur.com/a/SMjOZ90

so @Luke what you think? 

Edited by Bazzu85
Link to comment
Share on other sites

Bazzu85

additional tests..

With the android app running in foregroung I marked as played an episode, but the sync job is not updating.

My current tought is that there is something buggy or missing when a episode is marked as played and the relative download job is not updated..

Link to comment
Share on other sites

What do you see here?
image.thumb.png.671f2bc8616ce2085e0c88f7a421a376.png

What happens if you kick off the job clicking the arrow icon all the way to the right?

Link to comment
Share on other sites

Bazzu85
3 minutes ago, cayars said:

What do you see here?
image.thumb.png.671f2bc8616ce2085e0c88f7a421a376.png

What happens if you kick off the job clicking the arrow icon all the way to the right?

Here's:

image.png.8ad83f33331943a226cbcd2945f1f176.png

watching the download section, no change

The only method I found to start the sync is:

- open the android app (resuming from background doesn't trigger the sync)

- modify the sync

Link to comment
Share on other sites

Bazzu85
12 minutes ago, cayars said:

Did you run the convert media feature first?

check this video I made: 

 

Link to comment
Share on other sites

What exactly were you trying to show in that video?

Link to comment
Share on other sites

Bazzu85
1 minute ago, cayars said:

What exactly were you trying to show in that video?

That marking an episode as watched doesn't trigger the sync of the next one on phone.

Only forcing an update of the sync works (I modified the number of episode from 1 to 2). And is not an android battery optimisation problem obviously..

Link to comment
Share on other sites

Yes but you marked it watch on the PC and not the phone correct?
On the phone does it show as watched?
I'm not sure how often that info get's updated which is why I'm asking.

Link to comment
Share on other sites

Bazzu85
1 hour ago, cayars said:

Yes but you marked it watch on the PC and not the phone correct?
On the phone does it show as watched?
I'm not sure how often that info get's updated which is why I'm asking.

I marked as watched the server file, the play status is synced across device...so on the phone is watched too...but the sync as you see didn't update..

I don't understand the question?

the sync was setted to download 1 episode of the show unplayed. Marking the downloaded episode as played on server need to trigger the new download in my head..

but what I want to know is if there is a time that must pass before the sync occurs automatically? opening the app every time is not a good thing..

Edited by Bazzu85
Link to comment
Share on other sites

You can forget the question as you really answered it already.
I think at this point we would need one of the devs to comment on what kicks of the download process in situations like this.

@ebr any wisdom on this?

Link to comment
Share on other sites

It can take a little while. First the background process of the app has to report the activity to the server 

Then, later, the server convert media scheduled task runs to convert the media if that is required.

Then after that, the server sends a notification to the app that a new item is ready for download. This comes via Google push notification services.

If the app receives it then it requests the android os to immediately run the background process. If it doesn't receive the push notification because let's say you're running a custom Android rom or you have some configuration on the device preventing it from being received, then the app will still eventually figure out that something new is ready for download but it will take longer.

Link to comment
Share on other sites

Bazzu85
23 minutes ago, Luke said:

It can take a little while. First the background process of the app has to report the activity to the server 

Then, later, the server convert media scheduled task runs to convert the media if that is required.

Then after that, the server sends a notification to the app that a new item is ready for download. This comes via Google push notification services.

If the app receives it then it requests the android os to immediately run the background process. If it doesn't receive the push notification because let's say you're running a custom Android rom or you have some configuration on the device preventing it from being received, then the app will still eventually figure out that something new is ready for download but it will take longer.

What I'm seeing is that the first point is not my scenario (the episodes are watched on other devices).

The second point is not my case (original quality).

From the third point I follow you but in the server the sync is not updated. Is in "downloaded" status if you watch the video.

When marking as played on other device semms that no one update the sync job.

Link to comment
Share on other sites

Quote

The second point is not my case (original quality).

It still is your case actually because that's where it realizes the conversion isn't needed and then proceeds with the rest of the steps that I mentioned.

Link to comment
Share on other sites

Bazzu85
15 minutes ago, Luke said:

It still is your case actually because that's where it realizes the conversion isn't needed and then proceeds with the rest of the steps that I mentioned.

But I repeat, if I don't open manually the app or modify the sync, the download doesn't start automatically.

The app is running in background, I'm sure of this (check the video, modifying the number from 1 to 2 make the download start on phone without touching it). 

Link to comment
Share on other sites

Sometimes it can take a little while and you may just need to be patient.

Link to comment
Share on other sites

Bazzu85
11 hours ago, Luke said:

Sometimes it can take a little while and you may just need to be patient.

A little while is 10+ hours? Because after this time, still no download on phone. Several episode need to be transferred but the sync is still in "downloded" status. 

Check the screenshots: https://imgur.com/a/E98RSpY

edit:

@Luke can you please make this test?

  1. Open the android app (preferably android 11 , my test on android 8 tablet are working ) .
  2. Put it in background
  3. On the server, take a show
  4. Create a download entry to the android app with this options:
    1. Quality: original
    2. Download unplayed video only: true
    3. Automatically download new content: true
    4. Item limit: 1
  5. Wait that the first unplayed episode are downloaded to phone (don't open the app)
  6. Always on server go to the show and mark as played the downloaded episode. The expected behaviour is that at a certain time the next unplayed episode will be downloaded to the android app
  7. Wait that the download occurs..

In my test, the point 7 doesn't occurs automatically on phone. Even waiting 10+ hours as reported on top of this post. On tablet instead after some minute the download starts

Can you or some other user give me a feedback?

My phone is Oppo Find X2 Lite with Android 11 -> test ko

My tablet is Huawei MediaPad T5 10 with Android 8 -> test ok

thx

 

Edited by Bazzu85
Link to comment
Share on other sites

  • 5 weeks later...

Yes and I have not seen any problems. I would suggest trying the new 3.2+ app update that is currently going out.

Link to comment
Share on other sites

Bazzu85

Just updated yesterday, and the episodes are not downloading without a manual intervenction..

Watching something on a device <> from my phone, the server doesn't send the new episode to the phone...

the only way is to manually open the app on the phone to trigger the sync.

I tested this after a couple of day of no app activity on phone, and normal google tv watch...when on day 3 I opened the app all downloads starts..

 

Link to comment
Share on other sites

  • 2 weeks later...

@Bazzu85, if you force close the app, then the android OS will not run the app's background download process. You don't have to keep the app in the foreground though.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...