wix / AppleSimulatorUtils

A collection of command-line utils for Apple simulators.
Other
639 stars 62 forks source link

Xcode 15 > Unable to run commands #116

Closed bryanlatten closed 1 year ago

bryanlatten commented 1 year ago

Description

After upgrading to xcode 15, applesimutils can't seem to run commands against any simulator. I'm using applesimutils in service of detox framework. Prior to xcode upgrade, everything worked great.

ChildProcessError: Command failed: applesimutils --byId 452474B3-B45E-46BB-B2D5-99D919815B0B --clearKeychain
    *** -[__NSPlaceholderArray initWithObjects:count:]: attempt to insert nil object from objects[5]. See "applesimutils --help" for usage.
     `applesimutils --byId 452474B3-B45E-46BB-B2D5-99D919815B0B --clearKeychain` (exited with error code 255)

If you are describing an issue with brew install:

Steps to Reproduce

$ xcrun simctl list | grep 1C22E317-AC77-483C-9689-5A5AC4C1E51A
iPhone 14 (1C22E317-AC77-483C-9689-5A5AC4C1E51A) (Booted)

$ applesimutils --byId 1C22E317-AC77-483C-9689-5A5AC4C1E51A --clearKeychain
*** -[__NSPlaceholderArray initWithObjects:count:]: attempt to insert nil object from objects[5]. See “applesimutils --help” for usage.

Expected Behavior Commands should return successfully after taking action

Screenshots If applicable, add screenshots to help explain your problem.

Environment

Additional Context Thanks for the help!

B0Y3R commented 1 year ago

+1 Having the same issue

CameronWhiteside commented 1 year ago

Same here as well

asafkorem commented 1 year ago

Thanks for the report @bryanlatten, I'll look into it in a few days.

MKmiecik1 commented 1 year ago

The same issue is here, so looks like global, thanks @asafkorem for info, waiting for results.

cunderw commented 1 year ago

+1 here, this is fixed by https://github.com/wix/AppleSimulatorUtils/pull/115

ShahilMangroliya commented 1 year ago

+1 here, this is fixed by #115

how to install that specific PR

B0Y3R commented 1 year ago

If anyone needs a workaround while waiting for this fix, re-installing xcode 14, dragging it into the applications and choosing replace allowed me to get around this for now.

you can find the xcode 14 install here: https://developer.apple.com/download/all/?q=xcode

cunderw commented 1 year ago

+1 here, this is fixed by #115

how to install that specific PR

Clone forked repo and follow the instructions to build the binary. Then replace the binary on your system with the output.

cunderw commented 1 year ago

If anyone needs a workaround while waiting for this fix, re-installing xcode 14, dragging it into the applications and choosing replace allowed me to get around this for now.

you can find the xcode 14 install here: https://developer.apple.com/download/all/?q=xcode

You can also build the binary yourself from pr #115

asafkorem commented 1 year ago

https://github.com/wix/AppleSimulatorUtils/pull/115 was merged. I will release a new version of ASU soon

asafkorem commented 1 year ago

AppleSimulatorUtils v0.9.10 was released with a fix. Thanks to @ksuther for his great contribution

In order to upgrade ASU using brew:

brew tap wix/brew
brew update
brew install wix/applesimutils
asafkorem commented 1 year ago

Please let me know if this issue still happens even after the upgrade. @bryanlatten @B0Y3R @CameronWhiteside @MKmiecik1 @cunderw

bryanlatten commented 1 year ago

@asafkorem @ksuther looks very much solved, thank you!

B0Y3R commented 1 year ago

@asafkorem @ksuther Thank you!!