Posts

Sort by:
Post not yet marked as solved
0 Replies
2 Views
I'm trying to bind a NSProgressIndicator to Progress, but with the following code I only get an indeterminate progress indicator with a blue bar forever bouncing left and right, even after the two timers fire. According to the documentation: Progress is indeterminate when the value of the totalUnitCount or completedUnitCount is less than zero or if both values are zero. What am I doing wrong? class ViewController: NSViewController { let progress = Progress() override func loadView() { view = NSView(frame: CGRect(x: 0, y: 0, width: 500, height: 500)) let progressIndicator = NSProgressIndicator(frame: CGRect(x: 100, y: 100, width: 100, height: 100)) progressIndicator.bind(.isIndeterminate, to: progress, withKeyPath: "isIndeterminate") progressIndicator.bind(.value, to: progress, withKeyPath: "completedUnitCount") progressIndicator.bind(.maxValue, to: progress, withKeyPath: "totalUnitCount") progressIndicator.startAnimation(nil) view.addSubview(progressIndicator) progress.completedUnitCount = 3 progress.totalUnitCount = 10 Timer.scheduledTimer(withTimeInterval: 1, repeats: false) { _ in print(1) self.progress.completedUnitCount = 6 } Timer.scheduledTimer(withTimeInterval: 6, repeats: false) { _ in print(2) self.progress.completedUnitCount = 0 self.progress.totalUnitCount = 0 } } }
Posted
by
Post not yet marked as solved
0 Replies
5 Views
I call transaction information for several apps. And I don't have environment information. So I'm calling the sandbox environment as an official guide. However, unlike the official guide, certain apps sometimes succeed by calling an endpoint using a production URL to receive an error code 401 and calling an endpoint using a sandbox environment. Why does this difference occur unlike the official guide? Because of this difference, sometimes it's a production environment and JWT hasn't expired, but I get a 401 error and call the sandbox environment. 2. Please let me know the solution.
Posted
by
Post not yet marked as solved
0 Replies
11 Views
Today I have tried to add a second archive action for visionOS. I had added a visionOS destination to my app target a while back and can build and archive my app for visionOS in Xcode 15.3 locally, and also run it on the device. Xcode Cloud is giving me the following errors in the Archive - visionOS action (Archive - iOS works): Invalid Info.plist value. The value for the key 'DTPlatformName' in bundle MyApp.app is invalid. Invalid sdk value. The value provided for the sdk portion of LC_BUILD_VERSION in MyApp.app/MyApp is 17.4 which is greater than the maximum allowed value of 1.2. This bundle is invalid. The value provided for the key MinimumOSVersion '17.0' is not acceptable. Type Mismatch. The value for the Info.plist key CFBundleIcons.CFBundlePrimaryIcon is not of the required type for that key. See the Information Property List Key Reference at https://developer.apple.com/library/ios/documentation/general/Reference/InfoPlistKeyReference/Introduction/Introduction.html#//apple_ref/doc/uid/TP40009248-SW1 All four errors are annotated with "Prepare Build for App Store Connect". I have tried to remove the visionOS destination and add it back, but this is not changing the project at all. Any ideas what I am missing?
Posted
by
Post not yet marked as solved
0 Replies
8 Views
How do I download a folder from opensource.apple.com without going inside recursively and downloading individual files? e.g. one from here: "https://opensource.apple.com/source/Libm/" PS. no idea what's the proper tag for this post, and as forum insists on having a non-empty tag field I'm using "Foundation" arbitrarily.
Posted
by
Post not yet marked as solved
0 Replies
9 Views
I have been seeing some crash reports for my app on some devices (not all of them). The crash occurs while converting a CVPixelBuffer captured from Video to a JPG using VTCreateCGImageFromCVPixelBuffer from VideoToolBox. I have not been able to reproduce the crash on local devices, even under adverse memory conditions (many apps running in the background). The field crash reports show that VTCreateCGImageFromCVPixelBuffer does the conversion in another thread and that thread crashed at call to vConvert_420Yp8_CbCr8ToARGB8888_vec. Any suggestions on how to debug this further would be helpful.
Posted
by
Post not yet marked as solved
0 Replies
4 Views
I have built a camera application which uses a AVCaptureSession with the AVCaptureDevice set to .builtInDualWideCamera and isVirtualDeviceConstituentPhotoDeliveryEnabled=true to enable delivery of "simultaneous" photos (AVCapturePhoto) for a single capture request. I am using the hd1920x1080 preset, but both the wide and ultra-wide photos are being delivered in the highest possible resolution (4224x2376). I've tried to disable any setting that suggests that it should be using that 4k resolution rather than 1080p on the AVCapturePhotoOutput, AVCapturePhotoSettings and AVCaptureDevice, but nothing has worked. Some debugging that I've done: When I turn off constituent photo delivery by commenting out the line of code below, I end up getting a single photo delivered with the 1080p resolution, as you'd expect. // photoSettings.virtualDeviceConstituentPhotoDeliveryEnabledDevices = captureDevice.constituentDevices I tried the constituent photo delivery with the .builtInDualCamera and got only 4k results (same as described above) I tried using a AVCaptureMultiCamSession with .builtInDualWideCamera and also only got 4k imagery I inspected the resolved settings on photo.resolvedSettings.photoDimensions, and the dimensions suggest the imagery should be 1080p, but then when I inspect the UIImage, it is always 4k. guard let imageData = photo.fileDataRepresentation() else { return } guard let capturedImage = UIImage(data: imageData ) else { return } print("photo.resolvedSettings.photoDimensions", photo.resolvedSettings.photoDimensions) // 1920x1080 print("capturedImage.size", capturedImage.size) // 4224x2376 -- Any help here would be greatly appreciated, because I've run out of things to try and documentation to follow 🙏
Posted
by
Post not yet marked as solved
0 Replies
2 Views
I encountered a problem while using ScrollView in SwiftUI. When I perform a refresh, the app crashes. I access the array using an index in a ForEach loop. This is done to create new data from the array in a commonly used view. The function to create data is adopted from a protocol in the view model. I access it by index because the type of the array is not specified; each view using it may have a different data type. Below is an example code. Is it possible to access data from the array using an index? Every time I refresh, I get an "index out of range" error. import SwiftUI struct ContentView: View { @StateObject var viewModel = ViewModel() var body: some View { ScrollView { if !viewModel.testValues.isEmpty { LazyVStack(spacing: 20) { ForEach(Array(zip(viewModel.testValues.indices, viewModel.testValues)), id:\.1) { index, data in test(index: index, data: data, viewModel: viewModel) .onAppear { if !viewModel.isLoading, viewModel.testValues.count - 2 == index { viewModel.fetch() } } } } } else { Text("tesetsetsetsettse") } } .onAppear { viewModel.fetch() } .refreshable { viewModel.refresh() } } } struct test: View { let index: Int let data: String @ObservedObject var viewModel: ViewModel var body: some View { VStack(spacing: 8) { test1(index: index, data: data, viewModel: viewModel) Text("------------------------") } } } struct test1: View { let index: Int let data: String @ObservedObject var viewModel: ViewModel var body: some View { VStack { Text(viewModel.testValues[index]) .font(.system(size: 12)) .foregroundStyle(Color.red) .padding(.horizontal, 40) .padding(.vertical, 50) .background { RoundedRectangle(cornerRadius: 20) .fill(Color.blue) } } } } class ViewModel: ObservableObject { @Published var isLoading = false @Published var testValues: [String] = [] func fetch() { DispatchQueue.main.asyncAfter(deadline: .now() + 0.5) { self.testValues += [ UUID().uuidString, UUID().uuidString, UUID().uuidString, UUID().uuidString, UUID().uuidString, UUID().uuidString, UUID().uuidString, UUID().uuidString, UUID().uuidString, UUID().uuidString, ] } } func refresh() { testValues = [] fetch() } }
Posted
by
Post not yet marked as solved
0 Replies
4 Views
Hello Apple Developer Community, I am encountering an issue with my iOS app submission on the App Store Connect platform. After testing the app extensively on various devices, including iPhones and iPads using Xcode, the app appeared to be functioning correctly with all screens visible. However, upon submission, Apple rejected the app, citing that it launched a blank page specifically on the iPad Air (5th generation) running iOS version 17.4.1. I have thoroughly reviewed the app's code and conducted additional testing, but have been unable to replicate the issue on my end. I am reaching out to the community for assistance in troubleshooting and resolving this issue. Has anyone encountered a similar problem before, or does anyone have suggestions on how to address this issue effectively? Any insights or advice would be greatly appreciated. Thank you in advance for your help.
Posted
by
Post not yet marked as solved
0 Replies
3 Views
I am using Screen Capture Kit to capture the windows and record it. But from macOS Sanoma onwards I see a wired behaviour when I try to capture the window which is in Full screen mode. The CMSampleBuffer returned by Screen capture kit has empty space at the top of the full screen window content. The ContentRect attachment in CMSampleBuffer includes this empty space. So there is no way to know what is the actual window content in the CMSampleBuffer. In the CaptureCample sample code provided by Apple it does not enumerate the Full screen windows. I made a change in that to enumerate full screen windows. The issue is reproduced in that also. Attaching the Image of showing the empty space. Has anybody encountered this issue?
Posted
by
Post not yet marked as solved
0 Replies
8 Views
I'm trying to implement the playback of an HLS content with FairPlay, and I want to insert it into a RealityView using a VideoMaterial of a sphere. When I use unencrypted HLS content everything works correctly, but when I use FairPlay it doesn't. To initialize FairPlay I am using the following in the view: let contentKeyDelegate = ContentKeySessionDelegate(licenseURL: licenseURL, certificateURL: certificateURL) // Create the Content Key Session using the FairPlay Streaming key system. let contentKeySession = AVContentKeySession(keySystem: .fairPlayStreaming) contentKeySession.setDelegate(contentKeyDelegate, queue: DispatchQueue.main) contentKeySession.addContentKeyRecipient(asset) Has anyone else encountered this problem? Note: I'm testing in Vision Pro directly because the simulator hasn't support for FairPlay.
Posted
by
Post not yet marked as solved
0 Replies
26 Views
When accessing the REST API, If you apply "include=albums" to a 'catalog//songs' endpoint requests with a filter on ISRC, the API will, without fail, return a 504 error status. If you remove the 'include=albums' and/or replace it with something like 'include=artists' it works fine. This has been like this for months and we need to get album details back with these requests. Could the Apple team please respond and verify the issue as it's blocking production for us. Thanks.
Posted
by
Post not yet marked as solved
0 Replies
4 Views
Am using Beta Software 14.5 Beta (23F5064f) and I cant see m to update the recovery contact details,, cant remove it the icon sits in the cormer of my screen and wont go when clicking x as it opens up the recover page and view also doe the same but cant update or remove contacts, HELP its driving me insane. Come up as cant communicate with helper application. I have reported it, done another update and itrs still there
Posted
by
Post not yet marked as solved
1 Replies
29 Views
Hello, It is possible to restrict Documents folder access with TCC. But when an applications shows a standard "file open" dialog, it is possible to access this directory to open a file. macOS allows file access in this case because it is an intentional action from user. So i suppose there is a kind of whitelist for all files path opened through "file open" dialog. I would like to know how i can access this whitelist and how i can remove entries. Thanks
Posted
by
Post not yet marked as solved
0 Replies
8 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 not yet marked as solved
0 Replies
22 Views
For important background information, read Extra-ordinary Networking before reading this. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = "eskimo" + "1" + "@" + "apple.com" Network Interface Statistics One FAQ when it comes to network interfaces is “How do I get network interface statistics?” There are numerous variants of this: Some folks ask about specific network interfaces: “How do I get cellular data usage?” Some folks are interested in per-app statistics: “How do I get cellular data usage statistics for each app?” or “How do I get cellular data usage statistics for my app?” Some folks only care about recent statistics: “How can I tell how much network data this operation generated?” Some folks care about usage across restarts: “How do I get the cellular data usage shown in the Settings app on iOS?” Most of these questions have no supported answers. However, there are a some supported techniques available. This post explains those techniques, and their limitations. MetricKit To get network usage for your app, use MetricKit. Specifically, look at the MXNetworkTransferMetric payload. MetricKit has a number of design points: You only get metrics for your app. You get metrics periodically; you can’t monitor these statistics in real time. Legacy Techniques The getifaddrs routine returns rudimentary network interface statistics. See the getifaddrs man page and the struct if_data definition in <net/if_var.h>. Here’s an example of how you might use this: func legacyNetworkInterfaceStatisticsForInterfaceNamed(_ name: String) -> LegacyNetworkInterfaceStatistics? { var addrList: UnsafeMutablePointer<ifaddrs>? = nil let err = getifaddrs(&addrList) // In theory we could check `errno` here but, honestly, what are gonna // do with that info? guard err >= 0, let first = addrList else { return nil } defer { freeifaddrs(addrList) } return sequence(first: first, next: { $0.pointee.ifa_next }) .compactMap { addr in guard let nameC = addr.pointee.ifa_name, name == String(cString: nameC), let sa = addr.pointee.ifa_addr, sa.pointee.sa_family == AF_LINK, let data = addr.pointee.ifa_data else { return nil } return LegacyNetworkInterfaceStatistics(if_data: data.assumingMemoryBound(to: if_data.self).pointee) } .first } struct LegacyNetworkInterfaceStatistics { var packetsIn: UInt32 // ifi_ipackets var packetsOut: UInt32 // ifi_opackets var bytesIn: UInt32 // ifi_ibytes var bytesOut: UInt32 // ifi_obytes } extension LegacyNetworkInterfaceStatistics { init(if_data ifData: if_data) { self.packetsIn = ifData.ifi_ipackets self.packetsOut = ifData.ifi_opackets self.bytesIn = ifData.ifi_ibytes self.bytesOut = ifData.ifi_obytes } } This is a legacy interface. macOS inherited this API from its ancestor platforms, and iOS inherited it from macOS. That history means that the API has significant limitations: The counters reset each time the device restarts. The counters are represented as a UInt32, and so wrap at 4 GiB [1]. Due to its legacy nature, there’s little point filing an enhancement request against this API. [1] The <net/if_var.h> header defines an if_data64 structure, but there’s no supported way to get that value on Apple platforms. Limitations When it comes to network interface statistics, certain tasks have no supported solutions: Getting per-app statistics Getting whole device statistics that persist across a restart Getting real-time statistics for your app that persist across a restart If you need one of these features, feel free to file an enhancement request for it. In your ER: Be specific about the platforms you need this on [1]. Make sure that your request is aligned with that platforms privacy constraints. For example, iOS isolates your app from other apps, so you’re unlikely to get an API that returns per-app statistics for all apps on the system. Supply a clear justification for why this is important to your product. [1] If it’s macOS, be clear about: Whether your app is sandboxed or not. Whether it’s a Mac Catalyst. Or running via iOS Apps on Mac.
Posted
by
Post not yet marked as solved
0 Replies
9 Views
To authenticate Apple Pay payment through Mobile Test Automation via Face ID and a side button click if there is a way to automate a process involving Apple Pay where authentication could be performed using a software-based solution accessible through automation. Is there any way to access the side click button programmatically, using XCTest?
Posted
by
Post not yet marked as solved
0 Replies
26 Views
■Confirmation (2 points) ① Question about setting Constraints for UIScrollView. Is it correct to align the display position of the top edge of ContentsView, which contains the actual displayed content, with "ContentLayoutGuide" instead of "FrameLayoutGuide"? ② Is there a difference in screen display control between Xcode 14.1 and earlier and Xcode 15.0 when multiple Constraints are set for the same screen component? ■Background of the question On the screen that implements UIScrollView, the following two constraints regarding the display position of the top edge of ContentsView were set. Match the top of "FrameLayoutGuide". Match the top of "ContentLayoutGuide". Also, the priorities of the above two Constraints were the same. In Xcode 14.1, I was able to scroll the screen without any problems. When I upgraded to Xcode 15.0, the following error message appeared and I was unable to scroll. Unable to simultaneously satisfy constraints.
Posted
by
Post not yet marked as solved
0 Replies
17 Views
Team, When I try using Apple pay for Japan, we are getting Payment Not Completed error for a merchant with Japanese character as the displayName at completeMerchantValidation. The same works well if the merchant has name in English. log from com.apple.passkit as explained in Apple Pay on the Web Debugging Guide 2024-04-30 12:12:21.441231+0530 0xb6bd16 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitCore) [com.apple.passkit:Payment] Received <private> status: PKPaymentAuthorizationStatusSuccess 2024-04-30 12:12:21.441336+0530 0xb6bd16 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitCore) [com.apple.passkit:Payment] Evaluating merchant session using PROD trust policy. 2024-04-30 12:12:21.448371+0530 0xb6bd16 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitCore) [com.apple.passkit:Payment] State machine change state from PKPaymentAuthorizationStateClientCallback to PKPaymentAuthorizationStatePrepareTransactionDetails with param: <private> 2024-04-30 12:12:21.448393+0530 0xb6bd16 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitMacHelper) [com.apple.passkit:PaymentUI] State change: PKPaymentAuthorizationStatePrepareTransactionDetails 2024-04-30 12:12:21.448444+0530 0xb6bd16 Error 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitMacHelper) [com.apple.passkit:PaymentUI] State change not implemented: PKPaymentAuthorizationStatePrepareTransactionDetails 2024-04-30 12:12:21.450878+0530 0xb6bd16 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitCore) [com.apple.passkit:Payment] Performing request: POST <private> { 7 <private> fields } 500 bytes 2024-04-30 12:12:22.642216+0530 0xbaa237 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitCore) [com.apple.passkit:Payment] Task Completed: <private> 2024-04-30 12:12:22.642348+0530 0xbaa237 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitCore) [com.apple.passkit:Payment] Response: <private> 400 Time profile: 1.19145 seconds { 6 <private> fields } 232 bytes 2024-04-30 12:12:22.642571+0530 0xb6bd16 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitCore) [com.apple.passkit:Payment] State machine change state from PKPaymentAuthorizationStatePrepareTransactionDetails to PKPaymentAuthorizationStateFatalError with param: <private> 2024-04-30 12:12:22.642617+0530 0xb6bd16 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitMacHelper) [com.apple.passkit:PaymentUI] State change: PKPaymentAuthorizationStateFatalError 2024-04-30 12:12:22.642757+0530 0xb6bd16 Error 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitMacHelper) [com.apple.passkit:PaymentUI] Payment failed with fatal error <private> 2024-04-30 12:12:22.643288+0530 0xb6bd16 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitCore) [com.apple.passkit:Analytics] subject: inApp event: <private> 2024-04-30 12:12:22.659154+0530 0xb6bd16 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitMacHelper) [com.apple.passkit:PaymentUI] glyphView - revealedErrorAction() 2024-04-30 12:12:24.633308+0530 0xb6bad7 Default 0x0 55529 0 Safari: (PassKitMacHelperTemp) [com.apple.passkit:Payment] Invalidate extension <private> identifier <private> 2024-04-30 12:12:24.653014+0530 0xb6bd16 Info 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitCore) [com.apple.passkit:Connections] PKInAppPaymentService:0x12bf1b660 (0x1290e2a80): Tearing down existing connection 2024-04-30 12:12:24.653173+0530 0xbaaa12 Info 0x0 68603 0 passd: [com.apple.passkit:Connections] PDXPCServiceListener 2 (0x127705150:55547): connection invalidated 2024-04-30 12:12:24.654891+0530 0xb6bd16 Default 0x0 55547 0 com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitCore) [com.apple.passkit:Analytics] subject: inApp event: <private> As we can see, com.apple.PassKit.PaymentAuthorizationUIExtension: (PassKitMacHelper) [com.apple.passkit:PaymentUI] Payment failed with fatal error <private>, how do we debug this further?
Posted
by
Post not yet marked as solved
0 Replies
9 Views
Hi everyone ! This post is a following of this one. I'm trying to make a .pkg out of two bundles that lands in two different folders, namely : ~/Library/Audio/Plug-Ins/VST3 ~/Library/Audio/Plug-Ins/Components I am still using the script described in the previous post. The installer works fine on the computer that builds the package, on another computer in installs successfully but the aforementioned folders remains empty. My main computer is a MPB M1 (Ventura), I also have a 2015 MBA (Monterey). I tried to make the package on the air and the problem is the same : works on the machine that makes it, not on the receiver. When I try to install to Desktop for test purposes : The MPB correctly ask me for password / touch ID to install permission to use desktop permission to access file in the downloads (which are the extracted file of the .pkg I guess). But nothings happens. The package correctly indicate an installation of ~30Mo so it is not empty. I also tried using the mid process package for one of the two files with the same problem. I tried to use the CLI installer in verbose mode but it doesn't gave much information on what it is actually doing. My two main guess would be : already existing package ID permissions stuff But I don't really know how i could test for this... I would be grateful for any insights, Have a nice day ! -Thomas PS : I haven't found a "package" or "distribution" tag so I used the debugging one, feel free to modify if something seems more appropriate
Posted
by
Post not yet marked as solved
0 Replies
11 Views
I have a glb model that is loading absolutely fine, repeatedly, in safari or chrome. There is only one texture that is 8192x8192 it never has a problem when loading in browser. when we embed the url into an app, the model loads the first few times (exiting the model and going back to the main menu and then reloading the model) but, after a few attempts, the texture fails to load. The model and all data is visible but the texture, itself, is black. why could this be happening? Is there something in the iOS code that is breaking it? Is the iOS code trying to automatically cache the texture and it’s running out of memory? anyone who can provide the help and support that we require will be much appreciated. thank you advance.
Posted
by

TestFlight Public Links

Get Started

Pinned Posts

Categories

See all