Simulator

RSS for tag

Rapidly prototype and test builds of your app during the development process using Simulator.

Simulator Documentation

Posts under Simulator tag

334 Posts
Sort by:
Post marked as solved
2 Replies
289 Views
I've managed to build this locally via xcode but when trying to create xcframeworks of this, I am unable to create a simulator archive to add to the xcframework. Framework B has Excluded Architectures = [x86_64, arm64] for 'Any iOS Simulator SDK' Framework A imports Framework B but has Exclude Source File Names = FrameworkB.framework, FrameworkB.xcframework] for Any iOS Simulator SDK' So when using xcodebuild command /usr/bin/xcodebuild clean archive \   -scheme FrameworkB \   -archivePath PATH/FrameworkB-iphoneos.xcarchive \   -configuration Release \   -sdk iphoneos \   SKIP_INSTALL=NO \   BUILD_LIBRARY_FOR_DISTRIBUTION=YES \   BUILD_DIR=PATH/build \   DEVELOPMENT_TEAM=TEAMID \   GCC_PREPROCESSOR_DEFINITIONS=""\   SWIFT_ACTIVE_COMPILATION_CONDITIONS=""     /usr/bin/xcodebuild clean archive \ -scheme FrameworkB \ -archivePath PATH/FrameworkB-iphonesimulator.xcarchive \   -configuration Release \ -sdk iphonesimulator \ -destination='generic/platform=iOS Simulator' \ SKIP_INSTALL=NO \ BUILD_LIBRARY_FOR_DISTRIBUTION=YES \   BUILD_DIR=PATH/build \   DEVELOPMENT_TEAM=TEAMID \   GCC_PREPROCESSOR_DEFINITIONS=""\   SWIFT_ACTIVE_COMPILATION_CONDITIONS="" /usr/bin/xcodebuild -create-xcframework \   -framework PATH/FrameworkB-iphoneos.xcarchive/Products/Library/Frameworks/FrameworkB.framework \ -framework PATH/FrameworkB-iphonesimulator.xcarchive/Products/Library/Frameworks/FrameworkB.framework \   -output PATH/FrameworkB.xcframework In the clean archive step for iOS Simulator I get warning: None of the architectures in ARCHS (arm64, x86_64) are valid. Consider setting ARCHS to $(ARCHS_STANDARD) or updating it to include at least one value from VALID_ARCHS (arm64, arm64e, i386, x86_64) which is not in EXCLUDED_ARCHS (arm64, x86_64). As I've excluded both them archs. This fails to produce a binary inside the xcarchive though. Which leads to error: unable to read the file at 'PATH/FrameworkB-iphonesimulator.xcarchive/Products/Library/Frameworks/FrameworkB.framework/FrameworkB' I would like to avoid all of this but this is the only way I've managed to get the project to build for arm64 simulator with the new M1 Macs. Before FrameworkB built using x86_64 but contains libraries which don't support arm64. I have to exclude both archs though since Exclude Source File Names you can only specify Any iOS Simulator SDK rather than Only ARM64 iOS Simulator. I've tried Excluding FrameworkB when importing the xcframework but I get While building for iOS Simulator, no library for this platform was found
Posted
by
Post not yet marked as solved
1 Replies
117 Views
When I run my app on the iOS simulator that apps runs perfectly. When I try to simulate my app on my iPhone it says build failed. I am using Xcode 13 my Mac is update to Mac OS Monterey and my iPhone is on the latest iOS version. How do I fix this?
Posted
by
Post marked as solved
1 Replies
216 Views
I am developing an app with a widget available. Until recently the widget was being shown on both an iPhone and an iPad devices. Then I changed some logic in the widget, and now it only displays on the iPhone. I also use the Xcode simulators in the development, and the widget is available on both iPhone and iPad simulators, with same code. Summarizing the status for the widget. Simulators iPhone (13 Pro Max, iPhone 12) - OK iPad Pro (12.9" 5th Gen) - OK Devices iPhone (11) - OK iPad (Air 2) - Not available I can attach the Widget extension to the debugger for the simulators and the iPhone device. However the process in not there when I use the iPad device, so cannot attach the widget code to the debugger. Even if I attach the widget extension by name to the debugger, it is as if it is not running. I can run the widget extension directly on the iPad device (using an appropriate build scheme) and the details of the info displayed by the widget is the same as for the iPhone. So it is not running the widget on an iPad that is the problem. It seems like the widget extension is not embedded in the app code when the app is loaded on to an iPad device. Has anyone experienced anything similar? Not necessarily with a widget, it could be with another framework extension.
Posted
by
Post not yet marked as solved
0 Replies
87 Views
Hi Team, When Open Xcode simulator graphics are stuck. i don't know what is problem. I using 13.3 with Monterey OS. i attach screenshot please check it. Thanks
Posted
by
Post not yet marked as solved
0 Replies
204 Views
Hello, We are experiencing failing UI Tests on M1 devices (Xcode 13.3.1) while they pass well on Intel devices. The most common errors are: App stucks on splashcreen resulting in xctassert timeout Scrolling is not working properly (like there is no deceleration) resulting in wrong screen position and not found elements Notes: Simulator is running without Rosetta We have to exclude arm64-simulator arch support because of third party libraries Has anyone encountered such a problem? Thanks!
Posted
by
Post not yet marked as solved
1 Replies
142 Views
Hello, I'm trying to record an app preview, I was wondering if it's possible to run multiple simulators at one time with the same screen, so like is it possible for example if I click a button it clicks the button for all simulators? I want to sync all the simulators.
Posted
by
Post not yet marked as solved
0 Replies
189 Views
I’m working on a matching game. In my app, I would like a functionality that tracks the touches of two nodes at time. When the user touches the nodes and if the textures displayed after the user touches the nodes match; I don’t want the user to be able to interact with the two nodes anymore. However, if the textures displayed after the user touches the two nodes do not match. I want the two nodes the user touched to reset back to their original position before the user touched the nodes. For example, let’s say the user touches the node named “fruit match card1” and it displays the texture of an “apple” then they touch the node named “fruit match card 2” and it also displays the texture of an “apple”. Since, these two nodes display the same texture that match. I don’t want the user to be able to interact with those nodes anymore since they clicked nodes that display the same texture. However, let’s say the user touched the node named “Fruit match card 1” and it displays the “Apple” texture. Then they touched the node named “Fruit match Card 3” and it displays the “Grapes” texture. Since, these two nodes do not display the same texture I want those nodes to reset back to their original position before the user touched them. Any advice or help on how I can have those kind of functionalities in my app? Basically having a functionality that tracks the touches of two nodes at a time and also a functionality that will reset the nodes back to their original position of the textures of the two nodes touched do not match? Thanks! Here is my current code: import Foundation import SpriteKit class EasyScreen: SKScene { override func didMove(to view: SKView) { var background = SKSpriteNode(imageNamed: "Easy Screen Background") let timerText = SKLabelNode(fontNamed: "Arial") timerText.fontSize = 40 timerText.fontColor = SKColor.white timerText.position = CGPoint(x: 20, y: 400) timerText.zPosition = 1 var counter:Int = 90 timerText.run(SKAction.repeatForever(SKAction.sequence([SKAction.run { counter-=1 timerText.text = " Time: \(counter)" print("\(counter)") if counter <= 0{ let newScene = TryAgainScreen(fileNamed: "Try Again Screen") newScene?.scaleMode = .aspectFill self.view?.presentScene(newScene) } },SKAction.wait(forDuration: 1)]))) background.position = CGPoint(x: 0, y: 0) background.size.width = self.size.width background.size.height = self.size.height background.anchorPoint = CGPoint(x: 0.5,y: 0.5) let matchCardOne = SKSpriteNode(imageNamed: "Fruit Match Card") let matchCardTwo = SKSpriteNode(imageNamed: "Fruit Match Card") let matchCardThree = SKSpriteNode(imageNamed: "Fruit Match Card") let matchCardFour = SKSpriteNode(imageNamed: "Fruit Match Card") let soundButton = SKSpriteNode(imageNamed: "Sound On") matchCardOne.name = "FruitMatchCard1" matchCardTwo.name = "FruitMatchCard2" matchCardThree.name = "FruitMatchCard3" matchCardFour.name = "FruitMatchCard4" soundButton.name = "Sound" matchCardOne.size = CGSize(width: 150, height: 300) matchCardTwo.size = CGSize(width: 150, height: 300) matchCardThree.size = CGSize(width: 150, height: 300) matchCardFour.size = CGSize(width: 150, height: 300) soundButton.size = CGSize(width: 75, height: 75) matchCardOne.zPosition = 1 matchCardTwo.zPosition = 1 matchCardThree.zPosition = 1 matchCardFour.zPosition = 1 soundButton.zPosition = 3 matchCardOne.anchorPoint = CGPoint(x: 0.5, y: 0.5) matchCardTwo.anchorPoint = CGPoint(x: 0.5, y: 0.5) matchCardThree.anchorPoint = CGPoint(x: 0.5, y: 0.5) matchCardFour.anchorPoint = CGPoint(x: 0.5, y: 0.5) soundButton.anchorPoint = CGPoint(x: 0.5, y: 0.5) matchCardOne.position = CGPoint(x: -125, y: 60) matchCardTwo.position = CGPoint(x: -125, y: -260) matchCardThree.position = CGPoint(x: 70, y: 60) matchCardFour.position = CGPoint(x: 70 , y: -260) soundButton.position = CGPoint(x: -180, y: -600) addChild(background) addChild(matchCardOne) addChild(matchCardTwo) addChild(matchCardThree) addChild(matchCardFour) addChild(timerText) addChild(soundButton) } override func touchesBegan(_ touches: Set<UITouch>, with event: UIEvent?) { self.view?.isMultipleTouchEnabled = false let touch = touches.first let positionInSceneOne = touch!.location(in: self) let tappedNodes = nodes(at: positionInSceneOne) for node in tappedNodes{ if let tappedCard = node as? SKSpriteNode { if tappedCard.name == "FruitMatchCard1" { tappedCard.texture = SKTexture(imageNamed: "Apple") } } } let touchTwo = touches.first let positionInSceneTwo = touch!.location(in: self) let tappedNodesTwo = nodes(at: positionInSceneTwo) for node in tappedNodesTwo{ if let tappedCard = node as? SKSpriteNode { if tappedCard.name == "FruitMatchCard2" { tappedCard.texture = SKTexture(imageNamed: "Apple") } } } let touchThree = touches.first let positionInSceneThree = touch!.location(in: self) let tappedNodesThree = nodes(at: positionInSceneThree) for node in tappedNodesThree{ if let tappedCard = node as? SKSpriteNode { if tappedCard.name == "FruitMatchCard3" { tappedCard.texture = SKTexture(imageNamed: "Grapes") } } } let touchFour = touches.first let positionInSceneFour = touch!.location(in: self) let tappedNodesFour = nodes(at: positionInSceneFour) for node in tappedNodesFour{ if let tappedCard = node as? SKSpriteNode { if tappedCard.name == "FruitMatchCard4" { tappedCard.texture = SKTexture(imageNamed: "Grapes") } } } }
Posted
by
Post not yet marked as solved
1 Replies
176 Views
Recently, I think since I updated XCode, my iOS Simulator no longer opens "as expected". It can take 5 minutes or more. It just sits on the loading spinner &/or apple logo for a very long time....sometimes over 15 minutes. I have tried deleting & reinstalling, but no change. I have tried restarting. Typically, I use Expo to develop in React Native and they have a built in CLI which starts their dev server & opens your simulator of choice. I can't rely on this. I also try opening manually via Spotlight &/or open -a Simulator prior to running my Expo app. But this also does not solve my issue. I also tried to "reset" the simulator with sudo killall -9 com.apple.CoreSimulator.CoreSimulatorService command Is there anything wrong with my version? Are there other updates I can make? Simulator details: Version 13.3.1 (977.2) SimulatorKit 618 CoreSimulator 802.6 Macbook details: iOS 12.3.1 (21E258) MacBook Pro (16-inch, 2019) 2.4 GHz 8-Core Intel Core i9 64 GB 2667 MHz DDR4 Attached is a crash report . Crash log report
Posted
by
Post not yet marked as solved
1 Replies
283 Views
I am having problems on Xcode13.3.1, Monterey 12.2.1, Apple M1 Max. Sending an UpdateApplicationContext update from a paired iPhone simulator is not received on the paired Apple Watch Simulator in the didRecieveApplicationContext. However, sendMessage from the apple watch simulator does update the iphone simulator app properly. It is however, not possible to send anything from the paired iPhone simulator to the paired Apple Watch Simulator. When working with actual devices everything works properly with WatchConnectivity with passing information back and forth via updateapplicationcontext and sendmessage calls. Can anyone confirm this is a bug or if there is something wrong with my setup?
Posted
by
Post marked as solved
1 Replies
450 Views
I have a project running on Xcode 13.2.1 (M1 Pro Macbook - running under Rosetta) and after build and run the application, when simulator launches the app I get this error and the app crashes: rosetta error: /Users/MyNamed/Library/Developer/CoreSimulator/Devices/1BD3D129-CA10-43C9-AEFF-F0432D47365A/data/Containers/Bundle/Application/CAED47CA-E288-4681-9771-88E2ECE34321/MyApp.app/MyApp: load commands too large error: attach by pid '93801' failed -- lost connection Full report below: Translated Report (Full Report Below) ------------------------------------- Incident Identifier: 67A2A1BD-4B41-4D2A-8A1B-854A5B217346 CrashReporter Key: D55AE94A-30DB-57BB-6735-CCA816367BE0 Hardware Model: MacBookPro18,1 Process: MyApp [93801] Path: /Users/USER/Library/Developer/CoreSimulator/Devices/1BD3D129-CA10-43C9-AEFF-F0432D47365A/data/Containers/Bundle/Application/CAED47CA-E288-4681-9771-88E2ECE34321/MyApp.app/MyApp Identifier: com.id.iphone Version: 226 (1) Code Type: X86-64 (Native) Role: Foreground Parent Process: launchd_sim [83891] Coalition: com.apple.CoreSimulator.SimDevice.1BD3D129-CA10-43C9-AEFF-F0432D47365A [8513] Responsible Process: SimulatorTrampoline [735] Date/Time: 2022-04-28 11:21:32.1672 +0100 Launch Time: 2022-04-28 11:21:27.9880 +0100 OS Version: macOS 12.0.1 (21A559) Release Type: User Report Version: 104 Exception Type: EXC_BREAKPOINT (SIGTRAP) Exception Codes: 0x0000000000000001, 0x00007ff7ffd34af8 Exception Note: EXC_CORPSE_NOTIFY Termination Reason: SIGNAL 5 Trace/BPT trap: 5 Terminating Process: exc handler [93801] Highlighted by Thread: 0 Backtrace not available No thread state (register information) available Binary Images: Binary images description not available Error Formulating Crash Report: _dyld_process_info_create failed with 6 dyld_process_snapshot_get_shared_cache failed Failed to create CSSymbolicatorRef - corpse still valid ¯\_(ツ)_/¯ EOF ----------- Full Report ----------- {"app_name":"MyApp","timestamp":"2022-04-28 11:21:34.00 +0100","app_version":"226","slice_uuid":"5e179e1a-0c44-3168-abd4-8598cec7dc86","build_version":"1","platform":0,"bundleID":"com.myapp.iphone","share_with_app_devs":0,"is_first_party":0,"bug_type":"309","os_version":"macOS 12.0.1 (21A559)","incident_id":"67A2A1BD-4B41-4D2A-8A1B-854A5B217346","name":"MyApp"} { "uptime" : 39000, "procLaunch" : "2022-04-28 11:21:27.9880 +0100", "procRole" : "Foreground", "version" : 2, "userID" : 504, "deployVersion" : 210, "modelCode" : "MacBookPro18,1", "procStartAbsTime" : 948785111065, "coalitionID" : 8513, "osVersion" : { "train" : "macOS 12.0.1", "build" : "21A559", "releaseType" : "User" }, "captureTime" : "2022-04-28 11:21:32.1672 +0100", "incident" : "67A2A1BD-4B41-4D2A-8A1B-854A5B217346", "bug_type" : "309", "pid" : 93801, "procExitAbsTime" : 948883872901, "translated" : true, "cpuType" : "X86-64", "procName" : "MyApp", "procPath" : "\/Users\/USER\/Library\/Developer\/CoreSimulator\/Devices\/1BD3D129-CA10-43C9-AEFF-F0432D47365A\/data\/Containers\/Bundle\/Application\/CAED47CA-E288-4681-9771-88E2ECE34321\/MyApp.app\/MyApp", "bundleInfo" : {"CFBundleShortVersionString":"989898","CFBundleVersion":"1","CFBundleIdentifier":"com.id.iphone"}, "storeInfo" : {"deviceIdentifierForVendor":"B8806C7A-2774-56E4-8E50-41D4A8C204B1","thirdParty":true}, "parentProc" : "launchd_sim", "parentPid" : 83891, "coalitionName" : "com.apple.CoreSimulator.SimDevice.1BD3D129-CA10-43C9-AEFF-F0432D47365A", "crashReporterKey" : "D55AE94A-30DB-57BB-6735-CCA816367BE0", "responsiblePid" : 735, "responsibleProc" : "SimulatorTrampoline", "wakeTime" : 11496, "sleepWakeUUID" : "B6C14C1A-FE43-4E98-AF85-5D6C7BD6F889", "sip" : "enabled", "isCorpse" : 1, "exception" : {"codes":"0x0000000000000001, 0x00007ff7ffd34af8","rawCodes":[1,140703125687032],"type":"EXC_BREAKPOINT","signal":"SIGTRAP"}, "termination" : {"flags":0,"code":5,"namespace":"SIGNAL","indicator":"Trace\/BPT trap: 5","byProc":"exc handler","byPid":93801}, "extMods" : {"caller":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"system":{"thread_create":1,"thread_set_state":0,"task_for_pid":64},"targeted":{"thread_create":0,"thread_set_state":0,"task_for_pid":2},"warnings":0}, "legacyInfo" : { "threadHighlighted" : 0 }, "trialInfo" : { "rollouts" : [ { "rolloutId" : "601d9415f79519000ccd4b69", "factorPackIds" : { "SIRI_TEXT_TO_SPEECH" : "61ef3bd729647d394933a0a6" }, "deploymentId" : 240000416 }, { "rolloutId" : "60356660bbe37970735c5624", "factorPackIds" : { }, "deploymentId" : 240000027 }, { "rolloutId" : "602ad4dac86151000cf27e46", "factorPackIds" : { "SIRI_DICTATION_ASSETS" : "61ae8d06da72d16a4beb762e" }, "deploymentId" : 240000305 }, { "rolloutId" : "60da5e84ab0ca017dace9abf", "factorPackIds" : { }, "deploymentId" : 240000008 }, { "rolloutId" : "607844aa04477260f58a8077", "factorPackIds" : { "SIRI_MORPHUN_ASSETS" : "6103050cbfe6dc472e1c982a" }, "deploymentId" : 240000066 }, { "rolloutId" : "5fb4245a1bbfe8005e33a1e1", "factorPackIds" : { }, "deploymentId" : 240000015 }, { "rolloutId" : "5ffde50ce2aacd000d47a95f", "factorPackIds" : { }, "deploymentId" : 240000136 }, { "rolloutId" : "5fc94383418129005b4e9ae0", "factorPackIds" : { }, "deploymentId" : 240000349 } ], "experiments" : [ ] }, "reportNotes" : [ "_dyld_process_info_create failed with 6", "dyld_process_snapshot_get_shared_cache failed", "Failed to create CSSymbolicatorRef - corpse still valid ¯\\_(ツ)_\/¯" ] } Model: MacBookPro18,1, BootROM 7429.41.5, proc 10:8:2 processors, 16 GB, SMC Graphics: Apple M1 Pro, Apple M1 Pro, Built-In Display: Color LCD, 3456 x 2234 Retina, Main, MirrorOff, Online Memory Module: LPDDR5 AirPort: Wi-Fi, wl0: Sep 24 2021 15:49:44 version 20.10.853.23.8.7.106 FWID 01-78e271b2 Bluetooth: Version (null), 0 services, 0 devices, 0 incoming serial ports Network Service: Wi-Fi, AirPort, en0 USB Device: USB31Bus USB Device: USB3.0 Hub USB Device: USB2.0 Hub USB Device: USB-C Digital AV Multiport Adapter USB Device: USB31Bus USB Device: USB31Bus Thunderbolt Bus: MacBook Pro, Apple Inc. Thunderbolt Bus: MacBook Pro, Apple Inc. Thunderbolt Bus: MacBook Pro, Apple Inc. This is happening on a M1 Pro machine for me and all my coworkers with M1 Macs. Anyone have an idea what it could be?
Posted
by
Post marked as solved
1 Replies
156 Views
spindump We recently moved to Xcode 13 (13.3.1) and now when we run our tests the take enormous time and then fail with this error encountered an error (Test runner never began executing tests after launching As per suggestion else where we ran our test on iOS 14.5 simulator. They were successfully but it took 54 minutes (usually they take 6 mins). So iOS 14 as simulator destination is not workaround for us. I took a spindump while test were running on simulator 15.4 attaching them. Need help!
Posted
by
Post not yet marked as solved
4 Replies
522 Views
I want to connect a physical device (iPhone) and a simulator for CarPlay to simulate an app (ex: PlugShare App) installed on a physical device, but I would like to know if that is feasible. ★ Thing I want to do: I want take a screenshot for PlugShare App (CarPlay side). Screenshot like below... https://user-images.githubusercontent.com/16476224/163707909-95fa0b68-8eca-408a-b123-86ce39062984.png ★ References: https://developer.apple.com/carplay/documentation/CarPlay-App-Programming-Guide.pdf -> P13 https://developer.apple.com/documentation/carplay/using_the_carplay_simulator See [Open the CarPlay Simulator] ★ environment: Xcode: 13.3.1 physical device (iPhone): iPhone 13 Pro OS 15.4 macOS: 12.3.1 (Monterey)
Posted
by
Post marked as solved
1 Replies
274 Views
My Xcode version is 13.3.1. I have already checked the 15.4 version in DeviceSupport file [https://i.stack.imgur.com/K9S9L.png] But the warning still appears and there is still no 15.4 version in Components [https://i.stack.imgur.com/izHaH.png] Here is the full warning: Domain: IDEInstallLocalMacService Code: 16 Failure Reason: Ứng dụng này yêu cầu phiên bản macOS mới hơn. Recovery Suggestion: The system version is lower than the minimum OS version specified for bundle at /var/db/appinstalld/Library/Caches/com.apple.mobile.installd.staging/temp.rbQJiN/extracted/Coursera.app. Have 15.2; need 15.4
Posted
by
Post not yet marked as solved
0 Replies
120 Views
Hi Team, We are using our client simulator app for pulling the screenshots of our ad campaign and it is a mock screenshot. We were procured a new MacBook recently with an M1 chip in that we have installed the simulator app and it is working fine but when we try to paste some code or id in the simulator to pull the screenshot, we are not able to paste the code or id in the simulator app and the paste option is hidden in the app. Please let me know how to resolve this issue. We are using Macbook with an intel chip where we can able to perform this operation. We are facing an issue only with the MacBook with an M1 chip. Please suggest how we can resolve this.
Posted
by
Post not yet marked as solved
1 Replies
557 Views
I'm looking to replace my current MacBook Pro (2015) with 16GB RAM and an i7 processor. I talked to a specialist at the Genius Bar who told me that the M1 is hands down faster than the processor I have, however to replace a MacBook is expensive and I'm looking to go cheap. Will an M1 in an Air with 8GB RAM work for development of iOS (Xcode) and Android apps (Android Studio) with and without Flutter? This includes running Simulator and Android Emulators. In addition I tend to leave lots of programs open, specifically Slack, Microsoft Teams (and Microsoft Office programs), Discord, Evernote, VSCode, Xcode, and a lot of the preinstalled apps (Mail, Messages, Calendar, Music, Safari, etc) and don't want to sacrifice that ability.
Posted
by