Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Could not start com.apple.dt.simulatelocation! #106

Closed
1 task
ctrlcmdshft opened this issue Jan 31, 2022 · 25 comments
Closed
1 task

[BUG] Could not start com.apple.dt.simulatelocation! #106

ctrlcmdshft opened this issue Jan 31, 2022 · 25 comments
Labels
bug Something isn't working

Comments

@ctrlcmdshft
Copy link

Describe the bug
Fresh install of Location Simulator app will not set location. I ran app via Xcode to see what's going on and this error comes up when trying to set location [ERROR]: Could not start com.apple.dt.simulatelocation!

To Reproduce
Steps to reproduce the behavior:

  1. run app try to set location
  2. error pops up saying error changing location, could not change the location

Expected behavior
Should Set location

Desktop (please complete the following information):

  • Installed via homebrew ?
  • macOS: 12.2 Monterey
  • LocationSimulator version 0.1.8 Beta 8

Smartphone (please complete the following information):

  • Device: iPhone 12 Pro
  • OS: iOS 15.4 Beta 1
@ctrlcmdshft ctrlcmdshft added the bug Something isn't working label Jan 31, 2022
@Schlaubischlump
Copy link
Owner

Most likely a problem with the iOS 15.4b1 Developer Disk Image. This problem will solve itself, when iOS 15.4 is officially released. Take a look at #105 to find instructions of how to replace the Developer Disk Image file with a working one, which you can find if you google a little bit or search github.

@Schlaubischlump Schlaubischlump changed the title Not getting location [BUG] [BUG] Could not start com.apple.dt.simulatelocation! Jan 31, 2022
@ctrlcmdshft
Copy link
Author

#105 didn't work using prior bundles still same issue

@Schlaubischlump
Copy link
Owner

Prior bundles will not work. pdso has most likely uploaded the wrong iOS 15.4 DeveloperDiskImage. Since you have Xcode installed, you can just copy /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/15.4/DeveloperDiskImage.dmg and the signature file to the Application Support directory.

@ctrlcmdshft
Copy link
Author

Didn't work pulling the files from Xcode so probably another issue idk. Now the app won't even show map like before. Apps blank even after reinstall

@Schlaubischlump
Copy link
Owner

Strange... That shouldn't be the case. I never had a blank screen. Maybe the saved application state got corrupted. Is your normal maps app working correctly ?

@Schlaubischlump Schlaubischlump added the awaiting user response Waiting for an answer from the user label Feb 3, 2022
@ctrlcmdshft
Copy link
Author

MacOS maps works fine still having issues getting this to work I may wipe my max install and do fresh install soon so I’ll see if that helps

@ctrlcmdshft
Copy link
Author

Ok so before wiping and redoing the OS i decided to download Beta 7 and it works fine for me

@Schlaubischlump
Copy link
Owner

Beta 7 is working, but Beta 8 isn't working ? Which iOS version are you using. Beta 7 has no support for iOS 15 at all.

@ctrlcmdshft
Copy link
Author

Yes correct beta 7 is working for me. I’m on iOS 15.4 beta 1

@Schlaubischlump
Copy link
Owner

I assume you have mounted the DeveloperDiskImage with XCode ? Because otherwise this would definitely not work. Xcode will do this automatically if you connect your iPhone, will Xcode is open.

Strange that Beta 8 is not working... Have you disable SIP (System Integrity Protection) or something like that ? Which Mac OS Version are you using?

@ctrlcmdshft
Copy link
Author

Fresh boot open location simulator beta7 connect to phone and it just works. Xcode isn't running and nothing is mounted. Running newest macOS beta.

@Schlaubischlump
Copy link
Owner

Fresh boot of the iPhone I assume ? If this is the case, than I have absolutely no idea why this is working. Beta 7 does not even include a download link for this DeveloperDiskImage.

@bailaowai
Copy link

bailaowai commented Mar 6, 2022 via email

@Schlaubischlump
Copy link
Owner

Which iOS version are you using ?

@bailaowai
Copy link

bailaowai commented Mar 7, 2022 via email

@Schlaubischlump
Copy link
Owner

iOS 15.4 Beta or iOS 15.3?

@bailaowai
Copy link

bailaowai commented Mar 7, 2022 via email

@Schlaubischlump
Copy link
Owner

This is the macOS version number. This is good to know as well, but most importantly I need to know the iOS version on your iPhone. You can find it in 'Settings' -> 'General' -> 'About'.

@bailaowai
Copy link

bailaowai commented Mar 7, 2022 via email

@Schlaubischlump
Copy link
Owner

Yeah that makes perfectly sense. I didn't think about iOS 15.3.1... This will most likely require the 15.2 DeveloperDiskImage as well. I'll fix the error and upload a new version in the coming days. Hopefully tonight. I'll update this thread when I have uploaded the new version of LocationSimulator.

@bailaowai
Copy link

bailaowai commented Mar 7, 2022 via email

@Schlaubischlump
Copy link
Owner

Schlaubischlump commented Mar 7, 2022

I thought I knew what the error is, but I just tested LocationSimulator with iOS 15.3.1 and everything is working as expected on my devices. That means I have no idea why you get this error...

Could you try the following:

  1. Open the folder /Users/YOU_USERNAME/Library/Application Support/LocationSimulator/iPhone OS
  2. If the folder exists, delete all folders inside of it.
  3. If the folder does not exists check if /Users/YOU_USERNAME/Library/Containers/com.schlaubi.LocationSimulator/Data/Library/Application Support/LocationSimulator/iPhone OS exists and delete everything inside of this folder
  4. Reboot you iPhone
  5. Connect your iPhone, open LocationSimulator, wait till the download is finished and see if the same error occurs again

@bailaowai
Copy link

bailaowai commented Mar 7, 2022 via email

@ctrlcmdshft
Copy link
Author

After messing around mine isn't working again still running MacOS Current Beta as Well as iOS Current Beta. After a clean install of LocationSimulator when opening LocationSimulator i get no image of a map or any downloads

@Schlaubischlump
Copy link
Owner

Problem:
Each time apple releases a new beta build you have to download a new version of the DeveloperDiskImage for this beta. This is problematic because:

  1. The repo with the DeveloperDiskImages must be updated before you connect your device.
  2. If LocationSimulator detects that you already downloaded a DeveloperDiskImage for a beta version, it will NOT download the updated image.

Solution:
That means each time you upgrade to a new beta version you have to wait ~2 days, until the new DeveloperDiskImage is uploaded on the corresponding github repo and after that perform the steps I mentioned above:

  1. Open the folder /Users/YOUR_USERNAME/Library/Application Support/LocationSimulator/iPhone OS
  2. If the folder exists, delete all folders inside of it.
  3. If the folder does not exists check if /Users/YOUR_USERNAME/Library/Containers/com.schlaubi.LocationSimulator/Data/Library/Application Support/LocationSimulator/iPhone OS exists and delete everything inside of this folder
  4. Reboot you iPhone
  5. Connect your iPhone, open LocationSimulator, wait till the download is finished and see if the same error occurs again

Explanation (technical):

Why did it work then for a short time and why do I have to reboot the iPhone in the steps above ?

If the DeveloperDiskImage is uploaded once to your iPhone, it will not be uploaded again until the iPhone is rebooted. LocationSimulator is not the only program that can upload DeveloperDiskImages. E.g Xcode can do this as well. Lets say Xcode uploaded the correct DeveloperDiskImage before LocationSimulator could upload the outdated one. In this case LocationSimulator will work fine, until you reboot your iPhone (or some other condition unmounts the image) and the DeveloperDiskImage needs to be uploaded again.

Why doesn't the map load ?

Because of a bad coding decision on my side, LocationSimulator will block the UI for a short period of time, while a DeveloperDiskImage is uploaded to your iPhone. If this upload can not be performed or is too slow (because of a wrong DeveloperDiskImage) the UI will block and the app appears to stop responding. Normally this is not a big deal because:

  1. We are talking about ~1 or 2 seconds the UI will block only if no DeveloperDiskImage is uploaded yet.
  2. Even if I change the code, so that the UI does not block, this won't fix the underlying error that the DeveloperDiskImage is wrong. You will just not notice that an error occurred, but it still won't work.
    Would variant 2. with a nice error message be better than 1 ? Yes definitely. Will it fix my problem: No.

Consequences:
The explanations above are the reason, why I don't support beta iOS versions. Once apple has released a stable iOS version the DeveloperDiskImage will NOT change again for this iOS version. That being said: feel free to use beta versions on your iPhone, but don't expect LocationSimulator to fix your corrupted DeveloperDiskImages download once the final or a new beta version is online. You have to fix this yourself by performing the steps mentioned in the solution.

@Schlaubischlump Schlaubischlump removed the awaiting user response Waiting for an answer from the user label Mar 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants