-
-
Notifications
You must be signed in to change notification settings - Fork 159
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
Can't use 'ios image *' cli commands as intended #58
Comments
Interestimg, which device and which ios version is that? |
iPhone SE, iOS 13.5.1, Ubuntu 18.04.5 LTS |
I can actually reproduce it on my iphone 5s with iOS 12, should be an easy fix but I see you sent a PR already |
The issue is actually here: go-ios/ios/imagemounter/imagemounter.go Line 60 in 4354e90
You can see that I am getting a dictionary or map[string] interface{} as response from the device
and I am expecting it to contain an ImageSignature array. For a fix, I would grab the version of the device first and then modify the code to treat devices depending on their version. |
:D I wish I knew how to debug this project but I'll check how it happens :P But what you are saying makes sense, you can reject my PR, unfortunately I have only device available so I can't do very comprehensive testing :( Can you explain to me why it returns proper response when there are images but empty response when there are none? What exactly is missing in the case without images? |
What IDE are you using? Both responses are proper, it is just that Apple changes their interfaces now and then. I usually write my code in a fail fast manner to prevent inexplicable or unpredictable behavior, so if anything unexpected happens it immediately fails. That makes it easier to quickly find errors and fix them properly. |
I am using Visual Studio Code but I don't actually run the project through it, I just use 'go build' to make the executable and test with it ( this is as far as my current Go knowledge goes :D ) I am inclined to try and contribute to the project but it will probably take me months to understand everything and do something on my own :) Maybe I should just go and find one more second hand device to test on at least 14+. Thank you for the comprehensive answer! About the Appium talk - how can I attend it? |
I'll be at Appium Conf https://appiumconf.com/ I can write a quick fix for the image mounting issue btw. This will take like 5 minutes so I can do it later today after work. |
Fixing this will be great, I can keep working without updating my iPhone yet :D I'll do my best to attend the conf, wasn't actually aware it is happening so thanks for the notice. If you are willing to explain a little more that will be great but please only on your own accord, since using up your time because I give you 10$ makes me feel bad :D |
Haha no worries. It's a hobby project so I enjoy spending some extra time :-D |
Seems to work as expected - thanks a bunch! |
If I have an image already mounted on the device and I execute 'ios image list' I get a proper looking response like this:
{"level":"info","msg":"2f44230545372e7e64bdd6f19ee7c37154d1ea1359bb84db4b0ad1220137cfe5e8021dac74faf5f6163ab1bfb7705da56b5046cb6ae12a041f10c3c0e9175348d4551f05b48c255ad25ba1bfd0fee8d6f07f71389a6139f5341b2bae7c4e39bc57b0be6a721550ef8fcde7711bb64e6b523f839cd3df741272cb135ec986712e","time":"2021-08-23T10:20:59+03:00"}
If I have an image already mounted on the device and I try to mount another I also get a proper looking response like this:
{"level":"fatal","msg":"there is already a developer image mounted, reboot the device if you want to remove it. aborting.","time":"2021-08-23T10:21:24+03:00"}
BUT
if I don't have an image already mounted on the device and I try executing either 'ios image list', 'ios image mount' or 'ios image auto' I always get the same error:
{"err":"invalid response: \u003cnil\u003e","level":"fatal","msg":"failed getting image list","time":"2021-08-23T10:23:33+03:00"}
The issue occurs regardless if I pair the device beforehand or not
Tested on Ubuntu 18.04.5 LTS
The text was updated successfully, but these errors were encountered: