Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

old asset is displayed until log in to config screen #207

Closed
magnets99 opened this issue Jun 25, 2014 · 25 comments
Closed

old asset is displayed until log in to config screen #207

magnets99 opened this issue Jun 25, 2014 · 25 comments

Comments

@magnets99
Copy link

bit of a weird one this:
When i turn on the pi's in the morning yesterdays asset is displayed until you log in into the config, then it immediately starts working again and the viewer log under system info gives the impression it was working all along.
But the actual image from yesterday is displayed. I think it may be something to do with the fact i turn the pi's off at night.

To reproduce:
make 2 images, we'll call them A and B
load them up into screenly with A showing until 11pm this evening. and B showing from 3am tomorrow. Switch them both on, A should move to the active section
turn your pi off via the cron command
01 17 * * * sudo /sbin/shutdown -h now
in the morning of the next day (AFTER 3am) turn on your pi and let it load without going into the management screen

Observed behavior (bug)
Sceernly will load up and show asset A. once you log into the management screen it will start showing b before you change anything

Expected Behavior
that a stops showing and b becomes active once ntp sync is complete.

notes:
tried on two different pi's, all pi's have access to local ntp server. Problem remains after at least 3 hours. all assets are images.

@magnets99
Copy link
Author

alright, i can't get it to do this issue this morning. please mark this low priority until i can reliably get it to fail.

@magnets99
Copy link
Author

ok, it seems to be, old asset is displayed on boot if new asset is not yet active. I think there was another issue similar to this, i'll look for it now

@richard-to
Copy link
Contributor

@magnets99 Yes, I think you are referring to issue #209. That issue was fixed yesterday. Can you report back if that fixed your issue?

@magnets99
Copy link
Author

Hi,
will do, all my Pi's live in a no internet lan so it will take me a
while to update.
thanks for the advice though.

On 04/07/14 14:28, Richard To wrote:

@magnets99 https://github.com/magnets99 Yes, I think you are
referring to issue #209
#209. That issue was
fixed yesterday. Can you report back if that fixed your issue?


Reply to this email directly or view it on GitHub
#207 (comment).

@magnets99
Copy link
Author

i've updated them, will report back if it happens again, but feel free to close this issue as duplicate. Thanks for your help!

@magnets99 magnets99 reopened this Jul 27, 2014
@magnets99
Copy link
Author

I've updated it using apt-get upgrade, but my error persists. How can i check to see what version i'm running, and what should i be runnning?
Thanks

@magnets99 magnets99 reopened this Jul 27, 2014
@vpetersson
Copy link
Contributor

@magnets99, apt-get upgrade won't upgrade Screenly, jus the system. To update Screenly OSE, run:

$ ~/screenly/misc/run_upgrade.sh

From: http://www.screenlyapp.com/ose.html

@magnets99
Copy link
Author

thank you!
will try that tommorow

On 28/07/14 17:25, Viktor Petersson wrote:

@magnets99 https://github.com/magnets99, |apt-get upgrade| won't
upgrade Screenly, jus the system. To update Screenly OSE, run:

|$ ~/screenly/misc/run_upgrade.sh
|

From: http://www.screenlyapp.com/ose.html


Reply to this email directly or view it on GitHub
#207 (comment).

@magnets99
Copy link
Author

yup, that seems to have fixed it!

@vpetersson
Copy link
Contributor

Great.

@magnets99 magnets99 reopened this Aug 3, 2014
@magnets99
Copy link
Author

so.....
I had a friday asset. and no monday asset. When i came in this morning (monday) it is stuck displaying fridays's asset. Even if i go to management or settings page. Friday's asset remains on the display.

i'll try and get the log up now

@magnets99
Copy link
Author

is this the right log?
/var/log/supervisor/screenly-access.log

192.168.0.12 - - [31/Jul/2014 09:27:22] "GET /api/assets HTTP/1.1" 200 627
192.168.0.12 - - [31/Jul/2014 09:27:22] "GET /favicon.ico HTTP/1.1" 404 32
192.168.0.12 - - [31/Jul/2014 09:42:13] "DELETE /api/assets/0e4355f64b1a4b76bd7e8bc75fd3d9cb HTTP/1.1" 204 0
192.168.0.12 - - [31/Jul/2014 09:56:57] "POST /api/assets HTTP/1.1" 200 293
192.168.0.12 - - [31/Jul/2014 09:57:00] "PUT /api/assets/24c89074e6864772a74ce02abd0ee58c HTTP/1.1" 200 292
Bottle v0.12.7 server starting up (using WSGIRefServer(fast=True))...
Listening on http://0.0.0.0:8080/
Hit Ctrl-C to quit.

Bottle v0.12.7 server starting up (using WSGIRefServer(fast=True))...
Listening on http://0.0.0.0:8080/
Hit Ctrl-C to quit.

Bottle v0.12.7 server starting up (using WSGIRefServer(fast=True))...
Listening on http://0.0.0.0:8080/
Hit Ctrl-C to quit.

192.168.0.12 - - [04/Aug/2014 08:06:31] "GET / HTTP/1.1" 200 12418
192.168.0.12 - - [04/Aug/2014 08:06:31] "GET /static/js/screenly-ose.js HTTP/1.1" 304 0
192.168.0.12 - - [04/Aug/2014 08:06:31] "GET /static/js/main.js HTTP/1.1" 304 0
192.168.0.12 - - [04/Aug/2014 08:06:31] "GET /api/assets HTTP/1.1" 200 628
192.168.0.12 - - [04/Aug/2014 08:06:31] "GET /favicon.ico HTTP/1.1" 404 32
192.168.0.12 - - [04/Aug/2014 08:09:03] "GET /system_info HTTP/1.1" 200 5040
192.168.0.12 - - [04/Aug/2014 08:09:03] "GET /favicon.ico HTTP/1.1" 404 32
192.168.0.12 - - [04/Aug/2014 08:12:53] "GET / HTTP/1.1" 200 12418
192.168.0.12 - - [04/Aug/2014 08:12:53] "GET /api/assets HTTP/1.1" 200 628
192.168.0.12 - - [04/Aug/2014 08:12:53] "GET /favicon.ico HTTP/1.1" 404 32
192.168.0.12 - - [04/Aug/2014 08:13:10] "POST /api/assets HTTP/1.1" 200 293
192.168.0.12 - - [04/Aug/2014 08:13:11] "PUT /api/assets/c000ee2f22194ab78d66759d317f70ca HTTP/1.1" 200 291

@magnets99
Copy link
Author

from the screenly_viewer.log

Fri, 01 Aug 2014 17:04:47 Showing asset fri (image)
Fri, 01 Aug 2014 17:04:47 Sleeping for 10
Fri, 01 Aug 2014 17:04:57 Showing asset fri (image)
Fri, 01 Aug 2014 17:04:57 Sleeping for 10
Fri, 01 Aug 2014 17:05:07 Showing asset fri (image)
Fri, 01 Aug 2014 17:05:07 Sleeping for 10
Mon, 04 Aug 2014 07:43:58 Generating asset-list...
Mon, 04 Aug 2014 07:43:58 Playlist is empty. Sleeping for 5 seconds
Mon, 04 Aug 2014 07:44:03 Playlist is empty. Sleeping for 5 seconds
Mon, 04 Aug 2014 07:44:08 Playlist is empty. Sleeping for 5 seconds

even though the playlist is empty, it's still showing Friday's asset.

@magnets99
Copy link
Author

confirmed, if no new asset is loaded (not loaded but turned off). then the old asset is displayed even though it should not be.

@richard-to
Copy link
Contributor

Hi @magnets99

Can you describe the steps to reproduce the bug? I'll try to see if I can reproduce it.

EDIT:

Looks like you described the steps in your initial message. Are the steps still the same? And is there a quicker way to reproduce the issue?

@magnets99
Copy link
Author

not sure if there is a quicker way. basically the steps are:
load up an asset to run for an hour not other assests present or pending
shut down the pi via shutdown cron after half and hour
turn on the pi after 2 hours.
old asset is displayed when it should be a black screen. Even after time updates.

@richard-to
Copy link
Contributor

@magnets99

I didn't have time to run a longer test on my Raspberry Pi yet. But here is a test to try. Can you check if this shorter experiment works for you? I think this will help narrow down the possibilities a bit.

I ran a quick test on laptop using the following settings:

  • 1 asset from 10:10AM to 10:20AM.
  • No other inactive/active assets at all
  • Splash screen Off
  • Shuffle playlist Off

The viewer displayed the asset within the time interval. Next I turned off the viewer and then turned it on again at 10:22AM. I got a black screen.

Also here is the relevant part of my log:

Wed, 13 Aug 2014 10:22:03 Loading browser...
Wed, 13 Aug 2014 10:22:03 Browser loading file:///tmp/screenly_html/black_page.h
tml. Running as PID 3034.
Wed, 13 Aug 2014 10:22:03 Scheduler init
Wed, 13 Aug 2014 10:22:03 update_playlist
Wed, 13 Aug 2014 10:22:03 Generating asset-list...
Wed, 13 Aug 2014 10:22:03 generate_asset_list deadline: None
Wed, 13 Aug 2014 10:22:03 update_playlist done, count 0, counter 0, index 0, dea
dline None
Wed, 13 Aug 2014 10:22:03 Entering infinite loop.
Wed, 13 Aug 2014 10:22:03 Last update: 2014-05-14 20:11:22.140154
Wed, 13 Aug 2014 10:22:04 Received on 200-status
Wed, 13 Aug 2014 10:22:04 get_next_asset
Wed, 13 Aug 2014 10:22:04 refresh_playlist
Wed, 13 Aug 2014 10:22:04 refresh: counter: (0) deadline (None) timecur (2014-08
-13 18:22:04.989990)
Wed, 13 Aug 2014 10:22:04 get_next_asset after refresh
Wed, 13 Aug 2014 10:22:04 Playlist is empty. Sleeping for 5 seconds
Wed, 13 Aug 2014 10:22:04 Already showing file:///tmp/screenly_html/black_page.h
tml, keeping it.
Wed, 13 Aug 2014 10:22:09 Last update: 2014-05-14 20:11:22.140154

@vpetersson
Copy link
Contributor

@magnets99 / @richard-to - Actually, this might be related to the fact that the Pi doesn't have RTC. Hence if you power it off and then power it on later, the clock might be screwed up. Also, since the device doesn't have access to an NTP server (i presume), that might be the root cause and why you can't reproduce it.

@vpetersson vpetersson added this to the Sprint 3 milestone Sep 23, 2015
@vpetersson vpetersson removed this from the Sprint 2 milestone May 3, 2016
@vpetersson
Copy link
Contributor

@magnets99 Are you able to reproduce this on the latest version?

@madcackler
Copy link

I've been running into this myself, and after the update I was still getting same behavior.

@vpetersson
Copy link
Contributor

@madcackler Interesting.

Could you run the following and attach the file here?

$ cd ~/screenly
$ export PYTHONPATH=$(pwd)
$ python lib/diagnostics.py > ~/diagnostics.json 

Once done, could you attach the file here? That should help us troubleshoot the issue.

@magnets99
Copy link
Author

Hi Viktor,
I havn't seen it in a while, i'm running the new version but in the end I modified the hardware setup and just have the rpi powered up 24/7.
So to answer your question: No, but i'm using a workaround.

just cathcing up on the other comments. The pi does access a NTP server on our internal lan.

@vpetersson
Copy link
Contributor

@magnets99 Got it. Yeah I would recommend running the device 24/7 regardless. Closing out issue.

@denniskho
Copy link

Dear sir,
I also have same issue, how to solve this?
i already update and upgrade and run bash <(curl -sL https://www.screenlyapp.com/install-ose.sh)
problem still persist.
please advise.
Thanks

@magnets99
Copy link
Author

hi Dennis,
the problem recently came back to me, different cause but same symptom. It was a power supply that over the course of 24hours would eventually brown out and do strange things to the pi. Changing the power supply fixed all my issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants