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

XCode 10.1 not supported -> isAvailable #43

Closed
nilsnilsnils opened this issue Oct 16, 2018 · 10 comments
Closed

XCode 10.1 not supported -> isAvailable #43

nilsnilsnils opened this issue Oct 16, 2018 · 10 comments

Comments

@nilsnilsnils
Copy link

nilsnilsnils commented Oct 16, 2018

The key "availability" has changed to "isAvailable".
Therefore no devices will be found.
-> SimulatorController.swift:37

@johndpope
Copy link

#44

@Mirconet
Copy link

Mirconet commented Oct 31, 2018

Change SimulatorController.swift:34 -> if let deviceList = deviceList as? [[String:AnyObject]] {
The value for the key "isAvailable" is a boolean.
Then change SimulatorController.swift row 36 - 39 to:

if let state = deviceJson["state"] as? String,
let availability = deviceJson["availability"] as? String,
let name = deviceJson["name"] as? String,
let udid = deviceJson["udid"] as? String {

@dungc
Copy link

dungc commented Nov 2, 2018

Thank you @Mirconet,it's worked.

masteage pushed a commit to masteage/OpenSim that referenced this issue Nov 7, 2018
@ogezue
Copy link

ogezue commented Nov 9, 2018

when is a release planned?

@RomainQuidet
Copy link

+1 need an update :) thanks !

@RomainQuidet
Copy link

The pull request #44 does not correct the issue.

the json parsed is structure as this for available devices:
{ "availability" : "(available)", "state" : "Shutdown", "isAvailable" : true, "name" : "iPhone 5s", "udid" : "769F8F0A-66FA-41F5-8FAA-17E803044DB8", "availabilityError" : "" }

and for not available device:
{ "availability" : "(unavailable, runtime profile not found)", "state" : "Shutdown", "isAvailable" : false, "name" : "Apple TV 4K (at 1080p)", "udid" : "352FBDD8-0776-45CB-8CEE-97625CB8F9F0", "availabilityError" : "runtime profile not found" }

@RomainQuidet
Copy link

So isAvailable json key is used now, but availability is still (available) or (unavailable etc...)

@RomainQuidet
Copy link

anyway, the command line used xcrun simctl list -j devices does not list my ios 12 simulator devices ....

@RomainQuidet
Copy link

it does list it but the json parser fails now as availability is not anymore a string but a boolean. Swift dictionary must be homogeneous... as? [[String: String]] fails

@Bunn
Copy link
Collaborator

Bunn commented Nov 14, 2018

Fixed on the latest release: https://github.com/luosheng/OpenSim/releases/tag/0.4.1

@Bunn Bunn closed this as completed Nov 14, 2018
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

7 participants