Search results for

apple pencil charging

147,902 results found

Post

Replies

Boosts

Views

Activity

Basic question - dice demo project - get all values / roll all
I'm sure this is a basic question, but I'm new to this style of development, so thought Id ask... I've worked through Apple's dice roller demo, so far so good - I'm using the code below to render and roll a single die; struct DieView: View { init(dieType: DieType) { self.dieValue = Int.random(in: 1...dieType.rawValue) self.dieType = dieType } @State private var dieValue: Int @State private var dieType: DieType var body: some View { VStack { if self.dieType == DieType.D6 { Image(systemName: die.face.(dieValue)) .resizable() .frame(width: 100, height: 100) .padding() } else { Text((self.dieValue)) .font(.largeTitle) } } Button(Roll){ withAnimation{ dieValue = Int.random(in: 1...dieType.rawValue) } } .buttonStyle(.bordered) Spacer() } } Again, so far so good - works as I'd expect. I can now also add multiple DieViews to a DiceSetView and they display as I'd expect. Where I'm stuck is in the DiceSetView, I want to both determine the total score across the dice, and also offer the ability to Roll All the
Topic: UI Frameworks SubTopic: SwiftUI
0
0
23
1w
Reply to Connection drops while using Content Filter & App Proxy Provider
[quote='875835022, ameydalvi_sophos, /thread/815274?answerId=875835022#875835022, /profile/ameydalvi_sophos'] Is this logline faulty or not to be taken at its face value ?? [/quote] Well, neither. I think you’re misinterpreting what this is saying. It’s simply reporting the result of its call to your handle-new-flow method. So, the code looks something like this: let provider: NEAppProxyProvider = … let flow: NEAppProxyFlow = … let log: Logger = … let didAccept = provider.handleNewFlow(flow) log.log(…: provider ( didAccept ? accepted : rejected ) new flow (flow)) Note This isn’t the exact code, but rather my re-creation of it in Swift with some irrelevant details elided. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
1w
Reply to UserDefaults not Sendable
There’s not enough context here for me to evaluate this. Can you post a snippet that’s complete enough to feed into the compiler? We have a post that describes what we like to see in general, but in this case I don’t think you need anything that complex. I often test stuff like this in a small macOS command-line tool project, and in that case I can post the entire source code as a code block. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Topic: App & System Services SubTopic: General Tags:
1w
Reply to OnDemand VPN connection stuck in NO INTERNET
[quote='875862022, disinghal, /thread/811887?answerId=875862022#875862022, /profile/disinghal'] Packet tunnel provider is caliing some another app which is using URLSession [/quote] Huh? Apps can’t ‘call’ other apps on iOS, and similarly for app extensions. So what do you mean by this? Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
1w
Reply to iOS mTLS Client Certificate Authentication Fails in TestFlight with Error -25303
The error here, -25303, or errSecNoSuchAttr, suggests a problem with your attributes. And the only non-required attribute you’re supplying is kSecAttrApplicationTag. Which is, in fact, the cause of your issue. kSecAttrApplicationTag is only supported on keys. I recommend that you have a read of SecItem: Fundamentals [1], and specifically the The Four Freedoms^H^H^H^H^H^H^H^H Functions section, which explains how you can use SQL to model the expected behaviour of the SecItem API. In this case, the SQL table for certificate items has no kSecAttrApplicationTag, and thus this error. It also has links to the doc that explains which keychain item class supports which attributes. [quote='815390021, ellinj, /thread/815390, /profile/ellinj'] Is there an alternative to create SecIdentity without keychain access? [/quote] We finally (finally finally!) have this. See the docs for the SecIdentityCreate function. IMPORTANT This was added in Xcode 26 but backdeploys to much older systems. Or at least that’s the plan (-: Thi
1w
Reply to Can NWConnection.receive(minimumIncompleteLength:maximumLength:) return nil data for UDP while connection remains .ready?
That’s not the right API to use for receiving datagrams. Rather, use the receiveMessage(completion:) method or one of its variants. That ensures that you get the entire datagram in one hit. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
1w
Reply to Collecting OSLog logs from network extensions
[quote='815354021, JacobHearst, /thread/815354, /profile/JacobHearst'] OSLogStore … it only collects logs for the current process [/quote] Correct, at least on everything except the Mac. I cover this and many other logging topics in Your Friend the System Log. There isn’t truly a happy path here. When it comes to NE debugging, you need to see the full system log and there are no APIs on iOS that’ll let you get that. Oh, one last thing. If you’re goal is to work with Apple to help debug a problem, you can ask your user to file a bug in Feedback Assistant. That’ll attach a sysdiagnose log to the bug report. You won’t be able to see the sysdiagnose log, but if you pass the Apple folks that bug number they should be able to get it. I talk more about this idea in Using a Sysdiagnose Log to Debug a Hard-to-Reproduce Problem. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Topic: App & System Services SubTopic: Core OS Tags:
1w
Reply to 3 days almost now stuck in progress no logs generated
You can expect that most uploads will be notarised quickly. Occasionally, some uploads are held for in-depth analysis and may take longer to complete. As you notarise your apps, the system will learn how to recognise them, and you should see fewer delays. For lots of additional info about notarisation, see Notarisation Resources. Specifically, it links to a Q&A with the notary service team that’s quite instructive. [quote='815402021, AbubakrLatif, /thread/815402, /profile/AbubakrLatif'] have created new certificate [/quote] Yikes! That won’t help with this issue and, as these are Developer ID certificates, it can have negative consequences. Developer ID as precious, as I explain in The Care and Feeding of Developer ID. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
1w
Reply to System Extension Termination Fails
knytko wrote: Yes, reported today with ID FB13636366. Thanks for that. Annoyingly, that bug got lost in our system and there’s been no progress on it. I’ve taken steps to get it on the right track. Lanmac, Are you developing an app that contains a system extension? Because reading through your post it doesn’t look like you’re hitting the issue being discussed here. If you’re having a problem with the Finder that’s unrelated to app development, I recommend that you bounce over to the Apple Support Community, run by Apple Support. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Topic: App & System Services SubTopic: Core OS Tags:
1w
Reply to Mac App signing
At the top of the Signing & Capabilities editor there’s a Team popup. What does that show in your case? For context, it looks like Xcode thinks that you’re working in a Personal Team. However, the App ID in your screenshot is registered to an Individual team (Team ID 9________S). Individual teams should be able to use NE capabilities, so I’m not sure why Xcode isn’t letting you. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
1w
Reply to Title: Developer ID + DNS Proxy system extension: profile mismatch for `com.apple.developer.networking.networkextension`
[quote='815340021, Leo_Nagano, /thread/815340, /profile/Leo_Nagano'] If this is a known limitation or bug in how Xcode validates NE entitlements for Developer ID [/quote] Indeed, this is a known bug in Xcode’s code-signing support )-: [quote='815340021, Leo_Nagano, /thread/815340, /profile/Leo_Nagano'] is there a recommended workaround? [/quote] You have to sign your product manually, outside of Xcode. Exporting a Developer ID Network Extension has all the details here. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
1w
Reply to NEFilterManager fails with NEFilterErrorDomain Code=1 (“Configuration invalid or read/write failed”) on iOS — is NEFilter supported on non-supervised devices?
[quote='815372021, MattStewart, /thread/815372, /profile/MattStewart'] is NEFilterDataProvider supported on non-supervised devices for consumer App Store apps …? [/quote] No. TN3134 accurately reflects the allowed deployment paths for NE content filters. [quote='815372021, MattStewart, /thread/815372, /profile/MattStewart'] is this a platform restriction that cannot be worked around? [/quote] You shouldn’t think about this as something to be “worked around”. Rather, this is a platform privacy policy. If there were a way around it, that’d be a major security bug. Notably, macOS, being a different platform, has a different policy. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
1w
Reply to NETransparentProxyProvider – Support for Port Ranges in NENetworkRule
[quote='815439021, faisalIkwal, /thread/815439, /profile/faisalIkwal'] Is there any officially supported way to specify a port range in NENetworkRule? [/quote] I think you’ve answered this yourself (-: If you’d like to see this change in the future, I encourage you to file an enhancement request describing your requirements. And please post your bug number, just for the record. Oh, one more thing. The port range in your example coveres ephemeral ports, which I presume is not a coincidence. If so, consider focusing on that in your ER. The ephemeral port range has changed in the past and it wouldn’t surprise me if it changed again in the future. OTOH, a general port range feature would be more flexible. (One of the nice things about your filing your own ERs is that you get to explain your own requirements in your own words.) [quote='815439021, faisalIkwal, /thread/815439, /profile/faisalIkwal'] Is creating thousands of rules (one per port) considered acceptable or supported? [/quote] Again, I think you’ve answe
1w
Reply to Privacy issues related to uploading user health data to servers
DevForums is primarily focus on technical issues. For legal advice, I recommend that you consult an actual lawyer. If you have questions about App Review policy, my advice is: Read App Review Guidelines. If you have further questions, feel free to put them in a new thread in the App Store Distribution & Marketing > App Review topic. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
1w