-
Notifications
You must be signed in to change notification settings - Fork 987
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
More logging for simulator selection and deployment #596
Conversation
Codecov Report
@@ Coverage Diff @@
## master #596 +/- ##
==========================================
- Coverage 74.58% 74.24% -0.34%
==========================================
Files 11 11
Lines 1826 1833 +7
==========================================
- Hits 1362 1361 -1
- Misses 464 472 +8
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍. Just two tiny remarks. Please feel free to disagree
One other minor thing: would be nice if the paths for the ios-sim logging were relative to the project. That would improve readability but it could be more trouble than it's worth too |
The apppath and iossim binary? I didn't touch those, and assumed there was a reason for the absolute paths here :/ |
Yes, and the log path. That might well be the case. It's safest to use absolute paths but it should™ also work with relative paths since you cwd to the project dir. But you never know that they don't mess up in ios-sim. And we would need three extra lines just to have prettier paths for logging... |
Thanks for the feedback, incorporated the one I understood. Please feel free to edit the files yourself to get this ready to merge (as I won't be available the next few days). |
Okay, if the tests (eventually) pass, let's merge this as-is and ship it in 5.0.1. |
Thanks for the cleanup @dpogue! |
Motivation and Context
Currently the simulator selection and app deployment on the selected simulator is a bit of a black box, the logging is insufficient to properly understand and retrace what is happening.
Description
xcodebuild
command, output theemulatorTarget
that will be used as part of-destination
option:Deploying to simulator
ios-sim
Running command: /private/var/folders/nz/vv4_9tw56nv9k3tkvyszvwg80000gn/T/tmp-2604oc4wBu2VePt9/node_modules/ios-sim/bin/ios-sim launch /private/var/folders/nz/vv4_9tw56nv9k3tkvyszvwg80000gn/T/tmp-2604oc4wBu2VePt9/platforms/ios/build/emulator/HelloCordova.app --devicetypeid com.apple.CoreSimulator.SimDeviceType.iPhone-XR --log /private/var/folders/nz/vv4_9tw56nv9k3tkvyszvwg80000gn/T/tmp-2604oc4wBu2VePt9/platforms/ios/cordova/console.log --exit
ios-sim
withios-sim log:
for context:ios-sim
and fail (instead of hanging):(Related: The output this creates would benefit from changes to
ios-sim
: ios-control/ios-sim#255 + ios-control/ios-sim#256 (8.x))Testing
This has been used in
cordova-paramedic
to better understand cordova-ios behaviour and uncover a few problems around simulator selection and deployment.Checklist