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: 
destruk
Streaming Star

Missing or Invalid PHY (note)

I wish this error message was more descriptive, as it doesn't point to anything in particular. The forum here has suggested it's an issue with thumbnail graphics, but that isn't always the case.
After a bit of trial and error, it appears to be an internal undocumented sanity check on your content meta-data.
By 'undocumented' - I mean the Roku SDK only mentions this page as relevant -
http://sdkdocs.roku.com/display/sdkdoc/ifPath
phy: (String) the PHY volume

Anyway - if you are setting a streamurl to a relative file, shortened file, or anything other than an http:// https:// file:/ or other standard descriptor, it will generate this when it tries to populate that variable meta-data.
It also appears when you set the thumbnail metadata (sometimes?) - I didn't really test thumbnails to create this message.
Regardless - the fix here for me was to store the partial streamurl in a different variable I created, so I can set the streamurls just prior to actual video playback.
ie

o.StreamTemp=validstr(xml.StreamURL.GetText())

And then before the content is added to the videoscreen for playback I can edit it as needed to set the actual url it needs to be.
episode.StreamTemp="http://"+m.ServerPrefix+"/subfolder/subfolder/subfolder/"+episode.StreamTemp+etc etc etc
episode.StreamURLs[0]=episode.StreamTemp

I'm not sure how much ram this saves in roku - probably 50 characters per item, so it adds up quick with long content lists.
0 Kudos
4 REPLIES 4
EnTerr
Roku Guru

Re: Missing or Invalid PHY (note)

Ok, after seeing in console this mysterious warning:
*** ERROR: Missing or invalid PHY
i went searching and found the same - ifPath is the only one that mentions it - in passing.

I wondered in the past about the strange way local Roku resources are addressed and after some rumination now, here is what i gather:
PHY apparently is jargon for the "protocol" part of Roku's home-grown extensions to URI schemes. PHY is the name of a (pseudo)device where files are located. Maybe it was named "PHY" borrowing the term from the PHY (physical) network layer. If done "by the books", local URLs should have been preceded by "file:///", like so:

Roku URL "Proper" URL
------------ ---------------
pkg:/images/pong.png file:///pkg:/images/pong.png
tmp:/ephemeral.$$$ file:///tmp:/ephemeral.$$$
but won't blame Roku for that, considering how unsightly "file:///" prefix is (also, they don't support non-local file://host/path)

Literally though, all that the mysterious message means is "No colon (:) in file path argument" - no more and no less. I tried a few strings and all it cares about is if there is colon anywhere in the path. (Now that does not mean that anything with ":" is correct path - there is another warning "*** ERROR: Invalid path" too).

And in practical terms it means "you forgot to specify full path". 😉
EnTerr
Roku Guru

Re: Missing or Invalid PHY (note)

Hey, RokuCo -
is there any way that line# can be included in messages like this?
*** ERROR: Missing or invalid PHY
*** ERROR: Invalid path

I am getting now bunch of "*** ERROR: Invalid path" and for the life of me cannot figure where is coming from in roListScreen, posters are show normally. I am guessing the warning is coming from inside a component - but more diagnostic can be printed, right?
0 Kudos
TheEndless
Channel Surfer

Re: Missing or Invalid PHY (note)

"EnTerr" wrote:
Hey, RokuCo -
is there any way that line# can be included in messages like this?
*** ERROR: Missing or invalid PHY
*** ERROR: Invalid path

I am getting now bunch of "*** ERROR: Invalid path" and for the life of me cannot figure where is coming from in roListScreen, posters are show normally. I am guessing the warning is coming from inside a component - but more diagnostic can be printed, right?

I've found, in at least a few instances, that any AA with a "URL" attribute gets checked for validity, regardless of whether it's passed to a component that requires a URL attribute or not. Could that be the issue? Do you have any AAs with *URL attributes that are incomplete or invalid, even if they're not being used?
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
EnTerr
Roku Guru

Re: Missing or Invalid PHY (note)

I figured it out. Symptoms were so strange and reason so peripheral, i consider it didactic to share it:

I was getting those messages in roListScreen event loop, every time i move the selection. content[].HDPosterUrl was just fine, images were showing - and there was nothing suspicious in the event loop (i was just printing some diagnostic and not setting anything even). Additional prints to pinpoint the line where it happens were of not much help: it seemed to magically happen inside wait(port), which natch' is opaque.

An hour lost and... roAppManager.setThemeAttribute(). In a completely different place i have set theme attribute with a wrong value and now it was coming back to haunt me. Repeatedly. Why it kept re-parsing the attribute on every move, IDK. Maybe it should, since it was ListItemHighlightHD - maybe someone will keep changing it while selection moves (though not really, since you can't predict whether it will go up or down and change highlight to match next selection). But i know this, it ain't easy to troubleshoot.

So more diagnostic output with these, please RokuCo. Printing the problematic value alone would help, e.g.
"*** ERROR: Invalid path pk:g///images/goobar.png
0 Kudos
Need Assistance?
Welcome to the Roku Community! Feel free to search our Community for answers or post your question to get help.

Become a Roku Streaming Expert!

Share your expertise, help fellow streamers, and unlock exclusive rewards as part of the Roku Community. Learn more.