Description:
When trying to launch a liveview instance on Windows 7 in the emulator, the command was unrecognized and the launch failed. Here is the console output:
[INFO] : Emulator process exited successfully
'"C:\Users\tester\AppData\Local\Appcelerator Studio\plugins\com.appcelerator.titanium.liveview.core_1.0.0.1375925433\node_modules\liveview\bin\liveview-server"' is not recognized as an internal or external command,
operable program or batch file.
[INFO] : Project built successfully in 2s 633ms
[INFO] : Emulator not running, exiting...
[LiveView] version 0.1.32
[LiveView] { [Error: listen EADDRINUSE] code: 'EADDRINUSE', errno: 'EADDRINUSE', syscall: 'listen' }
[LiveView] File Server Started on Port 8324
Address in use, retrying...
[LiveView] [Error: Not running]
Subsequent attempts on device also failed with the same error. Attempts on our windows 8 machines also failed with the same error on device and emulator.
Steps to reproduce:
1) Ensure the plugin version of liveview is uninstalled
2) Update to the latest RC studio version for windows
3) Launch an emulator or device build with liveview enabled
Result:
Failure to install/launch and errors in the console
Expected Result:
Emulator or device build launches, liveview event/file servers working, liveview functions as expected on device or emulator.
Praveen investigated and found that cleaning the project did help to resolve the issue. It lowers the priority some, but we should still look into potential cause for why liveview-server command wasn't being recognized.
The problem was observed by a customer as well, and cleaning the project didn't help for them. Also they were actually not trying to run the app with LiveView, but because the liveview hook is already in "ti config", the liveview-server executable is still being referenced somehow and causes the app to fail. The only workaround for them is to remove the liveview hook manually from the command prompt. [~csullivan] Could you take a look at this for 3.1.3? Thanks.
[~mxia] I have tested on windows 7 & 8 and I am able to run liveview fine, but I think there might be an issue with how the cli is handling the hook if it is executing liveview even if it is not enabled. Any ideas [~cbarber] ?
[~csullivan] [~mxia] If a CLI plugin is in the global paths.plugins setting, then all plugins found in those paths are loaded for every CLI command. The only time a plugin is conditionally loaded is when it's being loaded via the tiapp.xml.
I am unable to reproduce can we please get a bit more info from the customer.