Forum Discussion

Luchin's avatar
Luchin
Channel Surfer
3 years ago

ECP (port 8060) not working within dev app in OS 12.0

Hi everyone,

Since update to OS 12.0, the ECP commands are not working within the dev app, whereas in OS 11.5 and before it worked just fine. Are you having the same issue on your Roku devices ? 

It seems that Roku is now blocking port 8060 even for in-app testing (within the dev channel app) because I got now 403 as response code when previously it was always 200.

'cmd = [ECP command]
'RokuIP = [local IP of Roku device, RFC1918 address]

request = CreateObject("roUrlTransfer")
m.port = CreateObject("roMessagePort")
request.setMessagePort(m.port)
urlString = "http://" + RokuIP + ":8060/" + cmd
request.SetUrl(urlString)

if request.AsyncGetToString() then
' or if request.AsyncPostFromString("") then
msg = m.port.waitMessage(0)
print msg.GetResponseCode()
end if

So far, this new restraint for the dev app was never notified by Roku as being part of the OS 12.0 update. Such control is understandable and already existing since a while for published channel apps but it's a major setback for development as the main goal of the dev app is testing !

If instead an ECP command is sent from a local pc, the same Roku device on OS 12.0 executes it and the response code is 200. So definitely this new observed restraint is affecting the dev app.

>~ curl -s -o /dev/null -w "%{http_code}" "http://"$RokuIP":8060/"$cmd
200

5 Replies

  • Chris-DP's avatar
    Chris-DP
    Binge Watcher

    This was an intentional change from Roku ad people where abusing this to link to other apps and such. This violates there certification policy’s so it was blocked from within the device.  

    • Luchin's avatar
      Luchin
      Channel Surfer

      Hi Chris,

      Thanks for your reply. Reasonably I can only in partial agree with your explanation and here's why:


      Chris-DP wrote:

      ... This violates there certification policy’s so it was blocked from within the device.  


      As mentioned, that kind of control is understandable for published channels in line with the certification policy which was notified time ago by Roku and the community is well aware. However, dev apps are primarily intended for testing and not to be published right away as such.

      About the misemploy statement, please notice that all channel apps must pass static analysis before they can be published, therefore adding restraints for the dev channel app is non-sense.

      ECP commands are a useful tool during the development phase, so hopefully Roku will waive soon this pointless limitation and reenable ECP commands within the device for in-app testing purposes (as it was before OS 12.0).

      • RokuBen's avatar
        RokuBen
        Community Moderator

        I've passed on this suggestion to the dev platform team, and this proposal is under consideration.  They did not expect it to affect in-app testing.  In the meantime, you could use a webserver on your local machine as a proxy to connect back to ECP so you're not making a local connection from the device.