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

Game installs but not start with iOS 13.6.1 #517

Closed
1 of 3 tasks
fgnm opened this issue Sep 12, 2020 · 4 comments
Closed
1 of 3 tasks

Game installs but not start with iOS 13.6.1 #517

fgnm opened this issue Sep 12, 2020 · 4 comments

Comments

@fgnm
Copy link
Contributor

fgnm commented Sep 12, 2020

Issue details

Plugin successfully compile, sign and install the app on the device, but when try to run it the console shows

Process finished with exit code -1

Without any other explanation. If I start manually the game from home screen it works as expected, but no console for logging.

Build Tools:

  • IDEA plugin
  • Eclipse plugin
  • Gradle plugin

Versions:

  • Robovm: 2.3.10
  • Xcode: 11.7 on Catalina (but I got the same issue also with Xcode 10 on Mojave)
  • JDK: OpenJDK 8

Build Targets:
I got this behaviour only with an iPhone 7 with iOS 13.6.1, while on an iPhone 5 with iOS 10.3.4 no issue and everything works as expected. Simulator works well too.

I'm not able to find any other stacktrace or error, is there an additional log file where should I look for?

Thanks

EDIT
Just found this in RoboVM console

[INFO] 20:39:51.885 Looking up developer disk image for iOS version 13.6.1 (17G80) in /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport
[INFO] 20:39:51.903 Copying developer disk image /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/13.1/DeveloperDiskImage.dmg to device
[INFO] 20:39:52.217 Mounting developer disk image
[ERROR] 20:39:52.299 AppLauncher failed with an exception:
[ERROR] 20:39:52.299 java.io.IOException: Failed to mount /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/13.1/DeveloperDiskImage.dmg on the device.
[ERROR] 20:39:52.299 	at org.robovm.libimobiledevice.util.AppLauncher.mountDeveloperImage(AppLauncher.java:681)
[ERROR] 20:39:52.299 	at org.robovm.libimobiledevice.util.AppLauncher.launchInternal(AppLauncher.java:707)
[ERROR] 20:39:52.299 	at org.robovm.libimobiledevice.util.AppLauncher.launch(AppLauncher.java:1057)
[ERROR] 20:39:52.299 	at org.robovm.compiler.target.ios.AppLauncherProcess$1.run(AppLauncherProcess.java:67)

Not sure exactly what it is

@fgnm
Copy link
Contributor Author

fgnm commented Sep 12, 2020

Maybe I've found a possible reason. This is the function that matches DeviceSupport folder:

static File findDeveloperImage(File dsDir, String productVersion, String buildVersion)

Currently, I've no folder 13.6 inside /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport.
In this case regex matches 13.1 folder which I think is not compatible with iOS 13.6.1.

So, in DeviceSupport folder I have 13.5 and 13.7, but not 13.6. Now I'm not sure which should be the working one for iOS 13.6, Xcode is able to install and run apps without problem, so must be one of these.

@dkimitsa
Copy link
Contributor

hi,
indeed if there is no exact version, logic will try another regex template.
in your case its going down to 13.* pattern. And all 13.1, 13.5 and 13.7 match it, random (in order of file system) of these will be used.

In your case you have few options:

  • run any app with Xcode -- it will install dev tools. then RoboVM should not try installing any;
  • create a symbolic link in DeviceSupport for version 13.6.1 from one of the above (probably 13.5).

@fgnm
Copy link
Contributor Author

fgnm commented Sep 12, 2020

Thanks for the answer!
I've tested a little bit more, and it seems that Xcode 11 does not needs 13.6 folder to run apps on iOS 13.6.1; If I've understood well, 13.6 device support will be released with Xcode 12 (https://github.com/iGhibli/iOS-DeviceSupport/commits/master), while Xcode 11 still uses 13.5 tools to run apps on iOS 13.6.x too.

Since iPhone 7 just asks me to update to 13.7 I've now fixed the situation, but I may suggest an improvement to findDeveloperImage function: instead to choose the directory random maybe could be worth to sort all founded folders and check the most compatible one.

dkimitsa added a commit to dkimitsa/robovm that referenced this issue May 3, 2023
reason: libmobiledevice was failing on every situation then: device is not connected, blocked or pairing not complete. considering build process and deployment might take minutes its sad to fail just due to blocked device.
changes: mitigation for these cases done by allowing 20 seconds for user to act to solve the situation:
- if no device connected -- waiting for device
- if device is locked -- waiting for unlock
- if pairing in progress -- waiting to complete

other changes:
- changed logic for picking dev image -- all version are parsed and picked exact or lower (fix for MobiVM#517)
- idea plugin: install was moved inside Run process. As before it was happening on UI thread and entire Idea was frozen (there was no update or locked device retries message);
- using Java9 language level for RoboVM compiler/plugins.
- amount for TODO added to point for code fragments that to be refactored (like Launchers, junit client depends on old structure)
@dkimitsa
Copy link
Contributor

dkimitsa commented May 3, 2023

fixed in #726

Tom-Ski pushed a commit that referenced this issue May 4, 2023
…726)

reason: libmobiledevice was failing on every situation then: device is not connected, blocked or pairing not complete. considering build process and deployment might take minutes its sad to fail just due to blocked device.
changes: mitigation for these cases done by allowing 20 seconds for user to act to solve the situation:
- if no device connected -- waiting for device
- if device is locked -- waiting for unlock
- if pairing in progress -- waiting to complete

other changes:
- changed logic for picking dev image -- all version are parsed and picked exact or lower (fix for #517)
- idea plugin: install was moved inside Run process. As before it was happening on UI thread and entire Idea was frozen (there was no update or locked device retries message);
- using Java9 language level for RoboVM compiler/plugins.
- amount for TODO added to point for code fragments that to be refactored (like Launchers, junit client depends on old structure)
@Tom-Ski Tom-Ski closed this as completed Aug 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants