Roku Developer Program

Join our online forum to talk to Roku developers and fellow channel creators. Ask questions, share tips with the community, and find helpful resources.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
jbrave
Channel Surfer

Re: annoying bug

was trying to pass one around. As it turns out, if you don't create a button on a springboard, it appears you don't get any messages period, so the problem is essentially solved.

- Joel
Screenshades: The first Screensaver for Roku2!
Musiclouds: The best free internet music, on your Roku!
Ouroborialis: Psychedelic Screensaver for Roku!
0 Kudos
evilmax17
Visitor

Re: annoying bug

"kbenson" wrote:
We ran into that non-functioning home screen problem about once a week while developing KidPaint. I think it was a combination of crazy code and a less mature environment at the time. I haven't seen this particular behavior in months now.

I've been seeing this behavior recently, but I don't have a reliable way to reproduce it. It seems to happen when roUrlTransfer.GetToString takes awhile or fails, but I don't have anything beyond that.

It results in a mostly non-responsive home screen. I can move left and right to different channels, but pressing OK does nothing. You can't launch any channels at all. The only way to fix it is a reboot.
My Roku Channels:
Viddler - viddler.com
Tested Fan - tested.com | Jamie & Adam
This is my next - theverge.com
1080p Showcase - RIP
Whiskey Media - RIP
======================
http://www.binarymoustache.com
0 Kudos
TheEndless
Channel Surfer

Re: annoying bug

I saw this quite a bit whenever the roAudioPlayer would crash (back when I was working on my SiriusXM and SHOUTcast channels), but haven't seen it much since. Are you doing anything with the roAudioPlayer by any chance?
My Channels: http://roku.permanence.com - Twitter: @TheEndlessDev
Instant Watch Browser (NetflixIWB), Aquarium Screensaver (AQUARIUM), Clever Clocks Screensaver (CLEVERCLOCKS), iTunes Podcasts (ITPC), My Channels (MYCHANNELS)
0 Kudos
evilmax17
Visitor

Re: annoying bug

"TheEndless" wrote:
I saw this quite a bit whenever the roAudioPlayer would crash (back when I was working on my SiriusXM and SHOUTcast channels), but haven't seen it much since. Are you doing anything with the roAudioPlayer by any chance?

I've been seeing it semi-frequently lately with the following scenario:


  • On an roPosterScreen, attempt to load an RSS XML feed on isListFocused()

  • Create an roUrlTransfer object, set my URL, SSL cert file, and basic authentication header.

  • Call roUrlTransfer::GetToString() to retrieve my XML feed of videos (something will go wrong here)

The GetToString() call never finishes, but the channel doesn't hang or crash. I can still move around the UI, but pressing Enter doesn't do anything. I can get back to the main menu if I press the Home button, but I can't launch any channels. A reboot is required.

Eventually if I wait long enough, the GetToString() call will finish, and I'll see the debug print statement that I put after it. The weird thing is, I'll get this print statement after I've already pressed the Home button, after I've already been on the main Roku menu for a good while. After that point, I can launch channels again. I would think that pressing the Home button would kill anything/everything associated to my channel, but that doesn't seem to be the case when this scenario occurs.

I'm not sure why the GetToString() call is acting weird. It could be that the server I'm accessing isn't behaving at that exact moment, but even if that was the case, it shouldn't make the Roku behave that way.
My Roku Channels:
Viddler - viddler.com
Tested Fan - tested.com | Jamie & Adam
This is my next - theverge.com
1080p Showcase - RIP
Whiskey Media - RIP
======================
http://www.binarymoustache.com
0 Kudos
TheEndless
Channel Surfer

Re: annoying bug

The UI screens run in a different thread than your application code, so that would explain why you're still able to use the UI while doing the web request. It sounds like your web request is taking a really long time to return for some reason. While it definitely sounds like something funky is going on with the Roku in that situation, there are some things you can do to work around it...

First, for long web requests, I'd recommend either putting up a "Please Wait..." dialog or clearing the currently displayed content items and displaying a "retrieving..." message, so the user can't browse around during the request, particularly if you're loading in response to a poster selection.

Second, I'd recommend using a AsyncGetToString model, so you can specify a timeout, instead of hanging indefinitely. The urlUtils.brs file in the videoplayer example has a nice example of how to do this in a way that behaves like the GetToString synchronous method, while providing the ability to timeout on longer than expected requests. You can further extend that example by capturing ResponseCode and ResponseHeaders if you have a need for them.
My Channels: http://roku.permanence.com - Twitter: @TheEndlessDev
Instant Watch Browser (NetflixIWB), Aquarium Screensaver (AQUARIUM), Clever Clocks Screensaver (CLEVERCLOCKS), iTunes Podcasts (ITPC), My Channels (MYCHANNELS)
0 Kudos