RubyMotion cannot find simulator devices watch app - ios

I have a RubyMotion iOS app and watch app. The project root contains the iOS and a subdirectory my_watch_app contains the watch app. I followed the guide. Everything is good except for when I try to run the watch app with rake watch. It says it cannot find a simulator device. The main app runs fine.
[!] Cannot find any simulator devices, please add devices in Xcode -> Window -> Devices.
UPDATE To clarify: I had watches paired with devices already. Running rake watch --trace showed that RubyMotion could not resolve a watch to use.

You should add a paired watch to your target iPhone.
Select Device and Simulators in Window menu.
Choose Simulators segmentation.
Select your target iPhone.
Click + button in PAIRED WATHES table.
Select Apple Watch model which is after series 2.
add a paired watch

I ended up deleting all simulators that Xcode 10 creates by default and trying with an iPhone 6s. In my case, the default simulator that wanted to run was the iPhone 6s but I deleted it to use an iPhone 8 by default. I kept pairing watches with the device until I found that the Apple Watch Series 2 42mm worked.
I am only able to run watch apps by pairing Apple Watch Series 2 42mm to a simulator.
I can run different simulators using device_name and specifying the iPhone device (RubyMotion launches the iPhone and Watch app at the same time). Again, the device specified must have a Apple Watch Series 2 42mm paired to be able to run rake watch device_name="{{DEVICE}}".
For my iPhone 6s simulator with a Apple Watch Series 2 42mm
rake watch device_name="iPhone 6s"
For my iPhone 8 simulator with a Apple Watch Series 2 42mm
rake watch device_name="iPhone 8"

Related

How to connect iPhone simulator to Apple Watch Simulator in Xcode?

I have trying to run my Apple watch application which is also available in iPhone but is showing (using WCSession paired status is false). So how to connect the iphone simulator to apple watch simulator. Please help me on this

See recorded activities on iPhone simulator?

Is it possible to get the Activity app on an iPhone simulator?
Working on an Apple Watch workout app and it's a pain to keep building on my actual device in order to see the saved workouts, the simulator is a LOT faster but I can't seem to find anything about this.
It's not a programming related question so I'm sorry if this is not the correct place to ask.
Workouts performed in a Watch simulator will reflect in the Health app on the paired iPhone simulator.
To pair a Watch and iPhone simulator in Xcode 11:
Window > Devices and Simulators
Select Simulators tab
Tap '+' at the bottom left
Add an iPhone simulator and make sure the 'Paired Apple Watch' checkbox is checked
Add a Watch simulator
Start the Watch sim and record a workout. Check the Health app on the paired iPhone simulator and you should see that your Watch workout was recorded.

How to fix iPhone deployment target ? (App Store)

So I tried to ship my iPhone app into the App Store. but it get rejected because when the App reviewer test my app they are using iPad and it seems my app is messed up.
and this was the rejection message:
We noticed that your app did not run at iPhone resolution when reviewed on iPad running iOS 10.3.1. Specifically, we were unable to Sign Up using an iPad.
So I searched that I need to make the deployment info devices into Universal. It works well on iPad when I tested out. But the problem is I'm shipping this app for iPad. and when I go to iTunes connect, they were asking for iPad screenshots.
So should I set the device deployment for iPhone or Universal?
The app must work in iPad also. choose the devices iphone only and try to run your app in ipad in 1x and 2x view.
If you want to build for iPhone only, you will need to go to the project settings > General > Devices and choose "iPhone". If you choose "Universal" then you are building for both iPhone and iPad, which is why you need screen shots for the iPad as well. If you build for iPhone only, though, the app can still run on iPad, it will get scaled up.
As for the reason why it is not working on iPad using iOS 10.3.1, you'll have to run it on a device with that version of the OS and do some debugging. The information you gave here is not enough.

Cannot run my app on iPhone because it's not paired with a watch?

I updated one of my apps to also run a little code on Apple Watch. I do not own an Apple Watch. After taking the time to do this, I found that Xcode refused to run my app on my phone, because the phone is not paired with an Apple Watch. Is it supposed to work that way? What about all of the customers who do not yet own an Apple Watch? Can they not use the app any longer?
Obvious it is. Because if you don't have an iWatch, you have to run your app on simulator only. To get iWatch simulator, click on iOS simulator -> Hardware -> External Displays, and then select Apple Watch-32mm OR Apple Watch-42mm. Firstly run your app on iPhone simulator then run iWatch app, that automatically will run on iWatch simulator.
If you just change your iphone app and run it without watch.
Click the button (it will open like drop down) of on your xcode near app run and stop buttons, just select your iphone app (its name without watchkit) and run it. It will show you just phones in selectable devices for emulators.
Other one (watchkit) show you phones + watch like "iphone 7 + Apple Watch Series 38 mm". If you select watchkit and run it. It will expect apple watch.

Reset settings on iPhone now device doesn't show in Xcode to run application

I was having an issue with Core Location in my app so I followed this advice (the selected answer) and reset my network and location settings on my device. Now that I've done that, my device isn't showing up as an option to build and run the app in the top left corner of Xcode. It just says "iPhone" when it should say "Aaron's iPhone 4S" which is what I named the device I'm testing on. What happened and how do I add it back in?
I am using Xcode 6.3.2 and an iPhone 4S with 8.3
Here is a screenshot of the Devices window:
It just says "iPhone" because name of your iPhone is "iPhone". So your iPhone is in list of devices, I think you can build and run the application as normal. Check setting of your iPhone to make sure the name of device.

Resources