I copied the snippet you posted into a main.lua file, and it worked as expected. I tried it on Build 3692 and 3677- both without issue. Could you be having a firewall issue or similar on your computer?
My apologies- native.newVideo does run from the Mac version of the simulator.
So, I built and ran something with the native.newVideo snippet from the docs and found that it fails on my test device running Android version 12, but functions as expected on an older device running Android version 8. Similarly, my newer Fire tablet, running Fire OS 7 (based on Android 9), would not run the video, but an older Kindle running Fire OS 5 (based on Android 5) played the video.
@kakula brought up Windows to counter my question about if it might be a firewall issue. They already know that it doesn’t work on Windows. (I didn’t know that because I was testing it in the simulator on a Mac.)
Per my follow-up post, I did a little experiment and discovered that native.newVideodoes not work on device for Android devices using newer versions of the OS, but does work on devices running older versions of the OS.
Since native.newVideo runs on my Android 8 device (API level 27) but does not run on my newer Kindle Fire (API level 28) one would speculate that something changed on the Android side. Perhaps a permission beyond just INTERNET is now required.
As to your questions: What should happen is that, after a brief buffering period, video should start playing. What should not happen is nothing for ten seconds followed by a popup saying “The video cannot be played” and event phase: failed and event phase: ended showing up in logcat. I built my test app using 3677.
If someone would like to perform a similar test using the latest build, I would encourage them to do so.
If someone has success using native.newVideoon a device running API level 28 or higher, it might be helpful if they shared their build settings.
I mean we can add more information to help solve this problem.
I thought it had something with PR #512, but I was wrong, after tested 3685 and 3686 (PR just between those versions) on Android 13, Sample/Media/NewVideo neither work on those version, it just show Unable to play.