Search results for

DTiPhoneSimulatorErrorDomain Code 2

158,494 results found

Post

Replies

Boosts

Views

Activity

Reply to How does one get the locale-specific character set encoding on a Cocoa App
A character encoding reflects the way the coded character set is mapped to bytes in memory. When using Terminal on macOS, you interact with the system via inputting characters, and the system needs to know how the characters are laid out in memory, which is the character encoding. Terminal by default uses UTF-8, which is described in the LANG environment, as you have noticed. In a Cocoa app, you handle text, which is a series of characters, via the Cocoa framework. Typically, you create a piece of text using String in Swift, or NSString in Objective C, and pass it to the system for text rendering. When creating a string type, you need to specify the encoding of your content – You can see that the init methods of Swift.String and NSString typically have an encoding parameter. If you don't, you are assumed to use the default encoding, which is UTF-8 for Swift.String and UTF-16 for NSString. Other than that, you most likely don't need to care the character encoding. Having said that, I am curious why yo
4d
Reply to HealthKit backgroundDelivery is only triggering in the background while charging
What you described doesn't seem to happen to me when I try with my iPhone + iOS 26.1 (23B85). Would you mind to share the device configuration, relevant code snippets, and detailed steps you used to observe the behavior? To observe the baseline behavior, I'd suggest that you start with an iPhone that has a high battery level (over 80%, for example), because the system may decide to not deliver an update if the battery level is low, even the device isn't in the low battery mode. This is especially true on watchOS. Best, —— Ziqiao Chen  Worldwide Developer Relations.
4d
HealthKit backgroundDelivery is only triggering in the background while charging
HealthKit background delivery only triggers when charging. I have set step monitoring to hourly frequency. Despite step changes, callbacks fail to arrive after 3-4 hours on battery, but trigger immediately upon connecting power. Observed for 2 days: background updates are only received when charging. The device is not in Low Power Mode, and Background App Refresh is enabled for the app in Settings.
1
0
61
4d
Switch from Individual to Organization Membership
Hi there, How long does it take to make a switch from Apple individual to organization membership? I initiated the process a 2 weeks ago, and I am get to receive another notification from Apple. Keeps showing We’re processing your membership migration from an individual to an organization. And I am unable to submit an application that requires Organization account.
9
0
7k
4d
Is it safe to manually edit Package.swift (iOS Version & Orientation) for SSC 2026?
Hi everyone, I am working on my submission for the Swift Student Challenge 2026 using a Swift App Playground (.swiftpm). The default project was set to iOS 16, but I manually edited the Package.swift file to change the minimum version to iOS 18.0 so I can use the latest APIs. I also modified the supportedInterfaceOrientations to lock the app to Portrait mode only. I know the file contains a warning saying Do not edit it by hand, so I am worried about two things: Disqualification: Will manually changing the iOS version from the default 16.0 to 18.0 cause any issues with the submission validator or the judging environment? Orientation: Is it acceptable to strictly force .portrait mode for the challenge, or are we required to support landscape/responsive layouts for the judges' iPads? I want to make sure these manual changes won't technically invalidate my playground. Thanks for your help!
1
0
99
4d
iOS18 Control Widget custom symbol preview failed
i export apple SF as custom sf for test. code is simple: var body: some ControlWidgetConfiguration { StaticControlConfiguration( kind:ControlWidgetConfiguration ) { ControlWidgetButton(action: DynamicWidgetIntent()) { Text(test) Image(custom_like) } }.displayName(test) } as we can see, it can't show image in the preview. but it can show image in the Control widget center. am i do some thing wrong?
5
0
1k
4d
Reply to Provisioning profile missing entitlement
[quote='871501022, roanutil, /thread/811382?answerId=871501022#871501022, /profile/roanutil'] It's just preferences stored in the key-value store. [/quote] Cool. [quote='871501022, roanutil, /thread/811382?answerId=871501022#871501022, /profile/roanutil'] I have updated the entitlement value with the correct Team ID. [/quote] OK. But you shouldn’t need to do that because Xcode should pick up the correct Team ID via the $(TeamIdentifierPrefix) syntax. As to your main issue, I suspect that Xcode has cached something that’s causing this. In situations like this I generally approach the problem in two ways: First, I create a new dummy test app, with a new bundle ID and thence a new App ID, to check whether this is working in general. Once I’ve confirmed that, I then start trying to resolve the issue with my real project. With regards that second step: In Signing & Capabilities, make sure that “Automatically manage signing” is enabled, the new team is selected in the Team popup, and that Signing Certi
4d
Reoccurring data access prompt issue with Swift Playgrounds 4.6.4 on macOS 26.1
Hello, I am having a recurring issue using Swift Playgrounds version 4.6.4 on macOS 26.1. Upon opening a file and every other time I start typing in the code section I get a prompt, the image below, two or three times. It doesn't matter if I accept or decline all or some of the prompts, as soon as I start typing on another line I get prompted another two or three times for permission. It appears to me that prompt generates every time the preview pane tries to update. Declining the prompt breaks the preview but accepting the prompt only gets you through a single line of code before it appears again. I believe this issue started after I updated to macOS26.1 as I had not encountered it before. I've also opened other files with Swift Playgrounds and encounter the same problem. It could also be unrelated to the update and could be an issue with some permission setting somewhere, however, I have been unable to find what or where it could be. Is anyone else experiencing this? Than
19
0
1.4k
4d
Reply to Sporadic "no route to host" over ssh
It’s better to reply as a reply, rather than in the comments; see Quinn’s Top Ten DevForums Tips for this and other titbits. Regarding this: it doesn't seem to be an issue with DenyMulticast I don’t think multicast is a factor here, either for good or for ill. iOS has additional restrictions around multicast, but those do not apply on macOS. this command always works for any user When run how? From Terminal? If so, that’s not the evidence that you think it is. Quoting TN3179: macOS automatically allows local network access by: Any daemon started by launchd Any program running as root Command-line tools run from Terminal or over SSH, including any child processes they spawn Based on the info you’ve provided so far, it really does sound you’re bumping into local network privacy issues. This is complicated by the fact that Unix-y programs tend to do things that confuse local network privacy, for example: Common Unix-y techniques, like calling daemon man page, can break responsible code inference. Such p
4d
Sporadic "no route to host" over ssh
When connecting to my M1 mac mini over ssh, certain programs are often unable to reach network destinations in the corporate LAN, although they can usually reach external addresses like www.apple.com. For example, a java program attempting to download from teamcity.dev.corp.com:8111 often fails like: java.net.NoRouteToHostException: No route to host Running the exact same command from the Apple Terminal program works like normal, simply connecting over ethernet on en0 to a TeamCity server inside the same building. Basic diagnostics from the ssh session do not show anything unusual: > traceroute teamcity.dev.corp.com traceroute to teamcity.dev.corp.com (10.21.4.1), 64 hops max, 40 byte packets 1 teamcity.dev.corp.com (10.21.4.1) 1.702 ms 0.409 ms 0.336 ms > route -n get teamcity.dev.corp.com route to: 10.21.4.1 destination: 10.21.4.1 interface: en0 flags: recvpipe sendpipe ssthresh rtt,msec rttvar hopcount mtu expire 0 0 0 0 0 0 1500 1194 > uname -a Darwin mac 25.1.0 Darwin Kernel Version 25.1.0: Mon
3
0
80
4d
Swift student challenge- help
To whoever is bothered enough to help (trust me, I get the feeling if you're not), I want to enter the swift student challenge either this year or next year, depending on how things play out. Anyway, I just wanted to know two things: 1) how long on average it takes to build a project which won distinguished winner and 2) whether any distinguished winners could send me the playgrounds they built. To be clear, I do not want the code, I just want to know what you did, what you called the playground, a list of some features it had, how long it took, just to help me prepare, because YouTube doesn't have much of that. Thanks :)
4
0
332
4d
issue with iconv() on macOS using "WCHAR_T//TRANSLIT"
Hello, I am working on a cross‑platform application that uses libiconv to convert strings to/from Unicode. I need to modify the existing code for compatibility with macOS. However, the call to iconv() fails with an unclear errno value (92) when using WCHAR_T: std::wstring ConvertToWchar(const std::string& iconvCodeSet, const std::string_view str) { iconv_t conv = iconv_open(WCHAR_T//TRANSLIT, iconvCodeSet.c_str()); if (conv == (iconv_t)-1) { std::cerr << iconv_open() failed << std::endl; return {}; } std::wstring out(str.size(), L'0'); auto inPtr = (char*)str.data(); size_t inSize = str.size(); auto outPtr = (char*)out.data(); size_t outSize = out.size() * sizeof(wchar_t); if (iconv(conv, &inPtr, &inSize, &outPtr, &outSize) == (size_t)-1) { std::cerr << iconv() failed. errno = << errno << std::endl; return {}; } if (iconv(conv, nullptr, &inSize, &outPtr, &outSize) == (size_t)-1) { std::cerr << iconv() failed. errno = << errno
2
0
132
5d