iOS Simulator refuses to connect to local. hostname - ios-simulator

I am working on an iOS app that connects to a web service. For development and testing, we use Bonjour to find servers on the local network, and during sign-in the app offers to connect to one of them instead of the production site.
Since upgrading to El Capitan, I am unable to connect from the Simulator to a web server running on the same Mac. I am able to reproduce this issue using Simulated Mobile Safari and the web server that comes with the stock Python in OS X.
Open Terminal, start a web server: python -m SimpleHTTPServer 8000
Open Safari inside the Simulator, enter URL: http://my-computer-name.local.:8000/
Simulated Mobile Safari displays "Safari cannot open the page because it could not connect to the server."
Additionally, the following message appears in the Console each time I try to load the URL:
assertiond[____]: assertion failed: 15A284 13A340: assertiond + 13207 [28CC4371-F3F9-3578-9436-310B23A2C638]: 0x1
Other possibly relevant facts:
Desktop Safari is able to connect using the URL http://my-computer-name.local.:8000/
Real Mobile Safari (on an iOS device on the same network) is able to connect using the URL http://my-computer-name.local.:8000/
Simulated Mobile Safari is able to connect using the URL http://127.0.0.1:8000/ (I need it to work with the Bonjour provided hostname, though).
Simulated Mobile Safari is able to connect to another machine with an URL like http://other-computer.local.:8000/
I'm using Simulator Version 9.0 (SimulatorApp-620 CoreSimulator-179)
OS X El Capitan 10.11 (15A284)
Amusingly, searching the web for the UUID 28CC4371-F3F9-3578-9436-310B23A2C638 yields only a handful of job posts. (You can make $15 for fixing this bug!)
This does not appear to be related to App Transport Security. My app behaves this way when ATS is disabled.
Are you able to reproduce this problem? Am I missing something?

I worked the issue around by adding an entry to the local OSX /etc/hosts file:
Append your FQDN after "localhost":
127.0.0.1 localhost mymachine.mydomain.local

Related

Can't get local testing working with BrowserStackLocal.exe desktop app on Windows 10

Browserstack has discontinued its chrome extension for local app testing and has moved to a desktop app/.exe that you have to download to do local testing.
I can't seem to get this working running Windows 10 and I'm wondering if anyone else has had this problem and resolved it.
When I download and execute their desktop app, it tells me local testing is enabled:
https://imgur.com/a/2ey7N3U
When I then use Browserstack Live to test local development I get an error message saying local testing is not enabled and it gives me the option to download their desktop app, which I have and says local testing is enabled:
https://imgur.com/a/YMd0LOj
I have tried uninstalling and reinstalling the desktop app/.exe, it gives me the same results.
I've confirmed with our network team that I am not behind a proxy which is an option to manage the desktop app (under "advanced settings" in the first screenshot above).
Our network team has also whitelisted all traffic from (asterisk).browserstack.com (the actual asterisk character is stripped here) and they're telling me "Additionally I watched his traffic on the firewall as he tried to use the browserstack software and no traffic was blocked
I've also been in contact with browserstack support but have basically been feeding their responses to our network team and our network team's responses back to browserstack. At the end of the day, I still can't get local testing working.
Does anyone have any ideas what might be happening and how I can resolve it?
I encountered the same behavior while setting up Local Testing with the BrowserStack Local Desktop app that was released after the announcement by Google about the end of support for Chrome apps (Click here). However, I was able to set-up Local Testing post configuring the proxy server details as mentioned over here.
I would suggest checking with your IT team if traffic for *.browserstack.com is being routed via a specific proxy at your end and configuring the proxy details in the 'Advanced Settings' for the desktop app.
In case this doesn't work, do contact BrowserStack Support

Shiny app doesn't work after domain name change

I got a problem regarding Shiny app (or about the web server).
The app is hosted and works well here: http://shiny.eeb.ucla.edu/GermlineAtlas/
The web administrator point this site to a new domain: https://germline.mcdb.ucla.edu/
It works in some devices (both Mac and Windows), but not mine (MacBook with Catalina 10.15.6).
I tried open with Safari and Chrome, same error:
It is shaded, I could switch between tab, but the buttons and reactions do not function.
Again it currently happen only on my machine...Hope you could give me some advice!!!!
Thanks,
Problem solved...turn off my antivirus system.

Visual Studio Tools for Apache Cordova - iOS Debugging Fails

I'm no longer able to debug my Cordova app on the iOS simulator. I get the dreaded "We're unable to find the app ... you're trying to debug." error. I've tried all the troubleshooting steps, but nothing has worked so far.
I should note that this was working just fine. I was able to debug my app multiple times, with no issues, and then suddenly this error started, and nothing I've tried has fixed it.
Interestingly, the actual build logs in Visual Studio make it look like everything went fine:
Requesting debug on remote iOS device for buildNumber 6805 on server https://<redacted>:3000/cordova...
Debugging - Successfully Debugging on the device
{webDebugPort=9221}
Anyone have any ideas?
UPDATE 1
Tried this on my local OS X device, too, and got a similar result. Here are the actual build logs:
Unable to attach to debug. Check that http://Matts-Mac-mini:9221 is accessible.
We were unable to find the app you’re trying to debug. Check that the device is connected, awake, and unlocked. Also, make sure it has Web Inspector enabled.
------ Cordova tools 6.1.1 already installed.
Requesting emulate on iOS Simulator for buildNumber 522 on server http://Matts-Mac-mini:3000/cordova...
Emulated - Successfully sent to ios Simulator
------ Cordova tools 6.1.1 already installed.
Requesting debug on remote iOS device for buildNumber 522 on server http://Matts-Mac-mini:3000/cordova...
Debugging - Successfully Debugging on the device
{webDebugPort=9221}
It looks like things fail, but then the later messages (which appear right away) make it look like things worked. And the app is indeed running in the simulator on my Mac.
After the discussion in the comments, I believe that the issue here is using a shared machine for debugging. If there are multiple iOS simulators running on a machine at the same time (Typically because there are multiple users connected to the machine each running their own simulator) then remotebuild cannot guarantee that you connect to the correct simulator. This is because we use ios-webkit-debug-proxy which assumes that only a single iOS simulator exists, and doesn't expose a way to restrict which one it connects to.
If you are trying to debug an app in the simulator and there is another user with a different simulator, you may connect to the wrong simulator where your app will not be running, and that can cause the error that you see.

Unable to CreateProject in PhoneGap

I am new in PhoneGap.
After installing PhoneGap desktop application for Windows 7, I tried to create a simple hello world application. After specifying project name, path, when I click on Create Project button, initially, it gives error as "connect ETIMEOUT 192.30.252.128:443" - This is due to the reason that I am in corporate network.
Further, if I try to disconnect from any network then I am getting "getaddrinfo enoent github.com:443" - This is due to the reason that I am not connected to any network.
Is there any way to use PhoneGap in corporate network?
I tried changing my port form 3000 to 2000 or something else, but that did not work.
Thank you
The only way to get PhoneGap Desktop to work on a corporate network is to get your IT department to either allow exceptions in the network's security policy for the PhoneGap Desktop.
At my office, we were able to get a wireless hotspot set up and configured for dev & testing with the PhoneGap Desktop App.

Can I enable the Firefox developer tools network panels to show local request as chrome?

While using Firefox network panel I noticed that it shows only "http://" requests in its panel whereas chrome shows all (images, css, js,....).
Is there any way to enable local requests monitoring in Firefox network panel..
Thanks in advance
This is not currently possible, and is being tracked in Bug 1000540.
For local testing, consider working around this bug by running a local HTTP server. If you have Python installed, you can run python -m SimpleHTTPServer to serve the current directory over port 8000.

Resources