0

I tried to run my app in live view mode on an iPhone device from appcelerator studio and get the error :

[LiveView] File Server unavailable. Host Unreachable @ 192.168.1.122:8324
[LiveView]Please ensure your device and computer are on the same network and the port is not blocked.

conditions :
1. Device : iPhone 5S with IOS 9.2.1
2. Titanium SDK 5.1.1.GA
3. Firewall off and connected to the same wifi
4. xcode 7.2
5. Appcelerator Studio 4.4.0
6. Latest appcelerator CLI

can't we use live view when deploying to iOS device?

nb : it works when i use iOS simulator and android devices

Fokke Zandbergen
  • 3,866
  • 1
  • 11
  • 28

1 Answers1

2

I just looked through the LiveView code and confirmed this issue happens when the LiveView code inside your iOS app can't see the LiveView server running on your computer. You claim that both your computer and your device are on the same network and the firewall is off. I suppose the next thing to check is the LiveView server even running?

LiveView lives inside the Appcelerator Studio directory. On my machine it's located at /Applications/Appcelerator_Studio/plugins/com.appcelerator.titanium.liveview.core_1.1.0.1445037865.

You can manually check the server status by running:

/Applications/Appcelerator_Studio/plugins/com.appcelerator.titanium.liveview.core_1.1.0.1445037865/node_modules/liveview/bin/liveview server status

There's actually a couple other subcommands you can pass in: start, stop, and restart. If the status command above says that the server is running, stop it using:

/Applications/Appcelerator_Studio/plugins/com.appcelerator.titanium.liveview.core_1.1.0.1445037865/node_modules/liveview/bin/liveview server stop

Build your app again and Studio will start the LiveView server again and hopefully this time it works. I don't think you need to manually start the LiveView server. I'm not even sure if that would work.

I hope that fixes your problem.

Chris Barber
  • 456
  • 2
  • 8
  • thanks for your answer, i tried your solution and still no luck [ERROR] : Script Error Couldn't find module: localeStrings for architecture: arm64 – David Loekito Feb 06 '16 at 13:48
  • i think it's bug, i found same case https://jira.appcelerator.org/browse/TIMOB-18598 – David Loekito Feb 06 '16 at 13:56
  • Thanks a lot for this. I was able to fix my workflow without Studio with this hint. I've created an .sh script to to stop the server prior building a new one. Then triggered appc run with my configuration and --liveview inmediately after and worked like a charm. The server now starts correctly everytime. With this finally i'm able to develop using LiveView with Sublime Text. Beautiful. Now for testing directly on an iPad for example i just need to execute ./adhoc.sh – lithiumlab May 09 '17 at 22:33
  • In my case when checked with `server status` it throwed multiple instances running (more than 15). When i issued the server stop command all those instances dissapeared and the next build was able to star the server with no problems. – lithiumlab May 09 '17 at 22:41