Build, test, and submit your app using Xcode, Apple's integrated development environment.

Xcode Documentation

Pinned Posts

Posts under Xcode tag

3,068 Posts
Sort by:
Post marked as solved
4 Replies
117 Views
In a feat of unmitigated disk cleaning, I removed who-knows-what, likely from ~/Library/Developer. Now I can't build apps that rely on watchOS (or likely tvOS/visionOS from the look of things). Run a try to build, Xcode tells me I should download watchOS, immediately shows me that it has, then does nothing. My Platforms window looks like this. If I tap Get next to watchOS 10.2 it looks like it succeeds immediately, but doesn't work (notice that 10.2 is already in the list). If I try to delete 10.2 from this list, it gives me an error that it can't find it on disk to delete it. I'm guessing there's a mismatch between some preference file and reality. Totally my fault I'm certain. Best way to recover?
Posted
by
Post not yet marked as solved
0 Replies
86 Views
I am using XCode on my Mac Book Pro M1 and trying to run the iOS app being developed on my iPad (5th generation, 12.9 inch) The devices are connected through USB-C cable. I have enabled developer mode on my iPad, trusted the M1 device, the developer, and the app. However the following appears on the iPad when trying to launch the app: Unable to Verify App An internet connection is required to verify trust of developer "Apple Development: ...". This app will not be available until verified This seems to be an issue with M1 specifically, as other people seem to have this problem, and the application successfully runs on other iOS devices
Posted
by
Post marked as Apple Recommended
714 Views
Hi all. I have a problem related to Xcode. Xcode says "iOS 17.2 simulator" is not installed, but I have been using this simulator for a long time and have installed the necessary SDKs. The problem has also been occurring for my colleagues since May 1, 2024. Restarting the Mac helps (there is no problem in Xcode after restarting Mac), but after reopening Xcode this problem repeats again. macOS 14.3.1 (23D60) Xcode 15.2 (15C500b)
Posted
by
Post marked as Apple Recommended
732 Views
During last night, Apple allegedly pushed new XProtect antivirus signatures. After that, I think XProtect found the malware Pirrit in my Xcode Simulator files from Apple. I'm not kidding. This is an excerpt from the XProtect log (notice the NSFilePath!): 2024-05-01 07:54:12.951 Pirrit 👉 no status_message report time 0.0000000 {"action":"report","path":{"modificationDate":732892166.8634809,"path":"\/Library\/Developer\/CoreSimulator\/Images\/1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg","creationDate":732892166.8634809},"status":{"description":"Error deleting path: \/Library\/Developer\/CoreSimulator\/Images\/1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg: Error Domain=NSCocoaErrorDomain Code=513 \"“1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg” couldn’t be removed because you don’t have permission to access it.\" UserInfo={NSUserStringVariant=(\n Remove\n), NSFilePath=\/Library\/Developer\/CoreSimulator\/Images\/1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg, NSUnderlyingError=0x1247612a0 {Error Domain=NSPOSIXErrorDomain Code=1 \"Operation not permitted\"}}.","causedBy":[],"code":24}} 2024-05-01 07:54:13.197 Pirrit message not in JSON format 2024-05-01 07:54:41.125 Pirrit ⚠️ FailedToRemediate time 0.0000280 {"caused_by":[],"execution_duration":2.8014183044433594e-05,"status_code":24,"status_message":"FailedToRemediate"} XProtect also detects another threat on my machine: 2024-05-01 10:09:58.530 BadGacha ⚠️ ThreatDetected time 0.0000120 {"caused_by":[],"execution_duration":1.2040138244628906e-05,"status_message":"ThreatDetected","status_code":21} Please check your XProtect logs. There is an app that can display these logs out there. Or you can use the system logging facility. I have deleted the whole Developer folders (both at / and ~) and reinstalled Xcode (not Beta). But a new XProtect scan finds Pirrit in the Core Simulator file again! I have also attempted to install an anti virus solution (Malwarebytes), but it does not detect anything. I am wondering if we should get someone from Apple involved. I am also wondering if I should reset my whole machine… Is anyone else seeing these issues in the XProtect log? It is unclear at this time whether there really is a Pirrit malware in Apple's Xcode simulator files or if there is some issue with XProtect like a faulty signature. Don't panic.
Posted
by
Post not yet marked as solved
1 Replies
138 Views
Hi everyone, I'm encountering an issue with my iOS device not connecting to Xcode after updating to iOS 17.4. Even after trying various troubleshooting steps, including downloading Xcode 15.4 Beta, the problem persists. Troubleshooting Steps Taken: Restarted my Mac. Untrusted and re-trusted the iOS device. Restarted the iOS device. Ran the command defaults write com.apple.dt.Xcode DVTEnableCoreDevice enabled in Terminal and restarted Xcode. Additional Information: I've checked for any available updates for both Xcode and my iOS device, but none are available. There haven't been any recent changes or updates to my development environment prior to encountering this issue. My iOS device version is 17.4, and my MacOS version is Sonoma 14.4.1. Error Messages: There are no specific error messages displayed. The devices simply do not recognize each other when attempting to connect via Xcode. I would greatly appreciate any assistance or suggestions on how to resolve this issue. Thank you in advance for your help!
Posted
by
Post not yet marked as solved
2 Replies
120 Views
So like the title says, when I start up Xcode the preview won;t work till I run a debug session using the simulator. Sometimes the debug session is unable to start the simulator, which I can start manually then run a debug session. Once all the above is done, preview works. Any idea what is causing this behavior?
Posted
by
Post not yet marked as solved
1 Replies
210 Views
Simulators will not install. Run destinations all empty. Can't even run on device. XCode 15.4 beta Sonoma 14.4.1 Intel Mac 16" MBP Attached screenshot of error. iOS 17.5 beta 2 (21F5058d) "Not compatible with XCode 15.4 beta" No run destinations appear. Not even 17.4 device that is plugged in. This all worked yesterday after initial XCode upgrade to 15.4 beta. Now all destinations are missing, even though they appear as installed in the 'Platforms' window. (yes I have rebooted and restarted XCode).
Posted
by
Post not yet marked as solved
0 Replies
77 Views
The std::sort function, which was not problematic until version 15.2, causes a crash, perhaps because of a modified [The performance of std::sort and std::ranges::sort was improved by up to 50% for arithmetic types (120908845)] entry in xcode 15.3. For your information, std::vector contained instances of the class I had written, and I was comparing them through a custom Comp function. However, items that should not be null are recognized as null and crash as a null reference. Please check it and return it.
Posted
by
Post marked as solved
1 Replies
133 Views
I have a Swift project with some C code in it. The C code creates a byte array with about 600K elements. Compiling under Xcode, the compilation takes a really long time. When I try to run the code, it fails immediately upon startup. When I cut this large array out of the build, everything else works fine. Does anyone know what's going on here, and what I might do about it?
Posted
by
Post marked as solved
1 Replies
118 Views
error: unable to read property list from file: /Users/jayengineer/Workspace/react_projects/Breached/ios/Breached/Info.plist: The operation couldn’t be completed. (XCBUtil.PropertyListConversionError error 2.) (in target 'Breached' from project 'Breached') <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>CADisableMinimumFrameDurationOnPhone</key> <true/> <key>CFBundleDevelopmentRegion</key> <string>$(DEVELOPMENT_LANGUAGE)</string> <key>CFBundleDisplayName</key> <string>Breached</string> <key>CFBundleExecutable</key> <string>$(EXECUTABLE_NAME)</string> <key>CFBundleIdentifier</key> <string>$(PRODUCT_BUNDLE_IDENTIFIER)</string> <key>CFBundleInfoDictionaryVersion</key> <string>6.0</string> <key>CFBundleName</key> <string>$(PRODUCT_NAME)</string> <key>CFBundlePackageType</key> <string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string> <key>CFBundleShortVersionString</key> <string>1.0.4/string> <key>CFBundleSignature</key> <string>????</string> <key>CFBundleURLTypes</key> <array> <dict> <key>CFBundleURLSchemes</key> <array> <string>com.jay754.Breached</string> </array> </dict> </array> <key>CFBundleVersion</key> <string>1</string> <key>LSApplicationCategoryType</key> <string></string> <key>LSRequiresIPhoneOS</key> <true/> <key>NSAppTransportSecurity</key> <dict> <key>NSAllowsArbitraryLoads</key> <false/> <key>NSAllowsLocalNetworking</key> <true/> </dict> <key>UILaunchStoryboardName</key> <string>SplashScreen</string> <key>UIRequiredDeviceCapabilities</key> <array> <string>armv7</string> </array> <key>UIRequiresFullScreen</key> <false/> <key>UIStatusBarStyle</key> <string>UIStatusBarStyleDefault</string> <key>UISupportedInterfaceOrientations</key> <array> <string>UIInterfaceOrientationPortrait</string> <string>UIInterfaceOrientationPortraitUpsideDown</string> </array> <key>UISupportedInterfaceOrientations~ipad</key> <array> <string>UIInterfaceOrientationPortrait</string> <string>UIInterfaceOrientationPortraitUpsideDown</string> <string>UIInterfaceOrientationLandscapeLeft</string> <string>UIInterfaceOrientationLandscapeRight</string> </array> <key>UIUserInterfaceStyle</key> <string>Light</string> <key>UIViewControllerBasedStatusBarAppearance</key> <false/> </dict> </plist>
Posted
by
Post not yet marked as solved
2 Replies
92 Views
Dears, I need XCode13 for my iMac (Monterey OS 12.7.4). Where can I find it. Thx and best regards Roman
Posted
by
Post not yet marked as solved
2 Replies
639 Views
Hi, I am running into an error on XCode 15 (iOS 17+). When I am trying to play an iframe on the app. I see this error popup. Warning: -[BETextInput attributedMarkedText] is unimplemented Failed to request allowed query parameters from WebPrivacy. How do I fix this issue? I never saw this before so I am sure it is new. The app use to run fine as well.
Posted
by
Post not yet marked as solved
1 Replies
124 Views
I have an iPhone app that was created in Xcode that downloads some data from Google Firebase (Firestore). Today I got a scary email from Google Firebase (as seen on the screenshot below). I'm not an expert on Google Firebase and honestly don't understand what this means. Two questions: Does this mean our database is publicly available on the surface web (so for example search engines can crawl/index it)? What do I do about this? Extremely thankful for any help!
Posted
by
Post not yet marked as solved
0 Replies
97 Views
My build is successful but exited with status code 1. The error is: Print: Entry, "CFBundleVersion", Does Not Exist /var/folders/yh/f54dxg054vn342yg8yz3blvm0000gn/T/SchemeScriptAction-qfIJYo.sh: line 5: File Doesn't Exist, Will Create: + 1: syntax error: invalid arithmetic operator (error token is "'t Exist, Will Create: + 1") My Info.plist file contains all the required parameters. How to resolve?
Posted
by
Post not yet marked as solved
0 Replies
107 Views
I am including the glm library in my Xcode project and want to suppress this warning: /opt/extlibs/macosx/include/glm/./ext/../gtc/bitfield.inl:343:15: warning: Although the value stored to 'x' is used in the enclosing expression, the value is never actually read from 'x' [deadcode.DeadStores] uint16 REG2(x >>= 1); ^ ~ Is there a way to do that via a #pragma or a #define or something else in the Build Settings?
Posted
by
Post marked as solved
2 Replies
167 Views
https://developer.apple.com/documentation/xcodekit/creating_a_source_editor_extension I created new MacOS project and added a Xcode Source Editor Extension target to the project. I run the extension in debug mode with extension target, but the extension is not show up in Editor menu debug mode Xcode. Xcode version is 15.3(released) MacOS version is 14.4.1 Sonoma
Posted
by