missing package product

42,928 results found

Post

Replies

Boosts

Views

Activity

PreviewApplication open Spatial Video issue
Hi, I have a Spatial Video that I am trying to load in a visionOS app with PreviewApplication API let url = URL(string: https://mauiman.azureedge.net/videos/SpatialJourney/watermelon_cat.MOV) let item = PreviewItem(url: url!) _ = PreviewApplication.open(items: [item]) When I run the application, I am getting the following error. Did I miss anything? QLUbiquitousItemFetcher: could not create sandbox wrapper. Error: Error Domain=NSPOSIXErrorDomain Code=2 couldn't issue sandbox extension com.apple.quicklook.readonly for '/videos/SpatialJourney/watermelon_cat.MOV': No such file or directory UserInfo={NSDescription=couldn't issue sandbox extension com.apple.quicklook.readonly for '/videos/SpatialJourney/watermelon_cat.MOV': No such file or directory} #PreviewItem The screen shows up as: Putting the spatial video locally, I get the following error: let url = URL(fileURLWithPath: watermelon_cat.MOV) let item = PreviewItem(url: url) _ = PreviewApplication.open(items: [item]) Error getting the size of file(w
3
0
179
1w
Contents of Swift dictionaries and arrays being lost
Just when I think I am finally starting to understand Swift I come across a gotcha like the following: I have two object, a swiftui display and one of data to be displayed. Ok, sounds easy. The data is read out of a JSON file so I have a set of arrays and dictionaries. The data is valid when read, it is definitely there, but when I go to display it, its gone. Just vanished. Wasted about a day on this so far, and I’ve seen it before, the inability to pass out of an object an array or dictionary with contents intact. If I create an array var, and not let the system do it, contents are preserved. So, in the data object I’ll have something like this: struct DataObject{ var item: [String:Any] item=JSONData serialized out of memory, and may have say, 12 fields } In my SwiftUI module I have: var item=dataObject.item dataObject.item now has 0 fields. I can allocate and initialize a dictionary in DataObject and those elements come through fine. So it seems like the stuff being serialized from JSON is being deleted out
3
0
196
1w
Reply to 3DS - Apple Pay
Hi @DominikJ, You wrote: We're adding this payment method to our app and noticed that during the initiation of a transaction, i.e., when invoking Apple Pay to reserve a product in our app, the 3DS verification doesn't occur. Our assumption was that 3DS happens when a card is added to the Apple Pay wallet, which is before the user purchases a product. But is that correct? Shouldn't 3DS be processed each time a transaction is initiated? The timing of the 3DS auth depends on the implementation of your payment service provider (PSP) or your payment network operator (PNO). Please contact your PSP and/or PNO directly to understand the expectations for your specific implementation. Then, you wrote: If the case where a transaction happened for a card where the 3DS authentication is completed when it was added, will the liability shift for this transaction from us as merchant to the bank as well, like regular 3DS auth on a transaction basis would do? For 3DS2 liability shift guidance, you should agai
1w
Reply to Testing presence of Purchased App in XCode
Hey - thanks for your reply. Yes, I followed that guide and the code seems to work. That guide does not answer the question of how to go about testing the functionality. Specifically: How do I create a mock/test purchased product that I can use to test if the product as been purchased. You see, I don't have a purchased product on my watch that I can validate as being purchased. XCode loads the app onto the watch for debugging. So the AppTransaction reports a originalPurchaseDate of 1970-01-01. As in, never purchased. In order to validate that a product has been purchased, I need to test originalPurchaseDate against Data.now in a test environment. How do I accomplish that?
1w
Reply to SwiftData History Tombstone Data is Unusable
The docs state that it would be possible to get the data from the tombstone by using a keyPath, there is no API for this however. The only thing I can do is iterate over the values (of type any) without any key information, so I do not know which data is what. Am I missing something or did we get a half finished implementation? This is a known bug. If you have not filed a bug report for this issue, I encourage you to do so via Feedback Assistant. By filing a bug report, you’ll be able to track the issue and get notified of problem resolution.
1w
Rosetta 2 in MacOS VM
I'm running a MacOS15 beta 3 VM on a MacOS15 beta 3 Host (M2 Pro Mac Mini) using the Apple Virtualization Framework (via https://github.com/s-u/macosvm). For building my app inside the VM I need Rosetta 2, since flutter still uses some Intel binaries. But when I want to install Rosetta 2 I'm always getting the message, that installing Rosetta 2 is not allowed on this system. Digging in the log files I found a message from the installer, that the system is not supported. Searching online I just find a method for using Rosetta 2 inside Linux VM's using the Virtualization Framework. Am I missing something or is it not possible to use Rosetta 2 with MacOS guests?
2
0
172
1w
Transactions with the same webOrderLineItemId value but different transactionId
Hello I called the 'Get Transaction Info' API with Auto-Renewable Subscription product type transactionId. I received a success response and called the 'Get Transaction History' API with the value 'originalTransactionId'. The response 'transaction' of the 'Get Transaction History' API that matches the 'webOrderLineItemId' value received through the 'Get Transaction Info' API was found, but the 'transactionId' value was different. Why is this happening? Which of the two transactions is normal? https://developer.apple.com/documentation/appstoreserverapi/get_transaction_info https://developer.apple.com/documentation/appstoreserverapi/get_transaction_history
0
0
105
1w
Fragment large size data sent and received using NSKeyedArchiver.archivedData in GameCenter
Trying to send and receive data in the GameCenter environment using the following methods: func sendData(dictionaryWithData dictionary: Dictionary<String, Any>,toPeer targetPeers: [GKPlayer]) { guard let match = self.match else { return } do { let dataToSend = try NSKeyedArchiver.archivedData(withRootObject: dictionary, requiringSecureCoding: false) try match.send(dataToSend, to: targetPeers, dataMode: .reliable) } catch { #if DEBUG print(CONNECTION MANAGER SEND DATA ERROR) #endif } } public func match(_ theMatch: GKMatch,didReceive data: Data,forRecipient recipient: GKPlayer,fromRemotePlayer player: GKPlayer) { if match != theMatch { return } DispatchQueue.main.async { do { guard let message = NSDictionary.unsecureUnarchived(from: data) as? Dictionary<String, Any> else {return} ... <CODE> ... } ///Source: https://stackoverflow.com/questions/51487622/unarchive-array-with-nskeyedunarchiver-unarchivedobjectofclassfrom static func unsecureUnarchived(from data: Data) -> Self? { do { let unarc
5
0
152
1w
Reply to How to use libssh2 in a SwiftUI app?
Swift can, in general, call C APIs directly. However, there are numerous challenges: If the C library doesn’t already have a module map, you have to create one. You have to build the C code into some sort of library. This is especially tricky if you’re targeting, say, iOS, where you have to convince the C code’s build system, running on the Mac, to output a library for a different platform. Indeed, if you’re targeting a non-Mac platform you have to build the C code multiple times, once for the target platform and once for the simulator. You then have to package everything up so that Xcode can use that library. There are lots of different ways to achieve this. And, as the best approach very much depends on the library you’re trying to use, there are lots of different discussions about this from lots of different folks. For example, I was having a similar conversation to this with someone last week. If all this sounds like too much, I recommend that you search for an existing Swift package tha
1w
Reply to Issues with LaunchAgent and LaunchDaemon
[quote='759833021, gamakaze, /thread/759833, /profile/gamakaze'] All three processes must not restart if the user quits them [/quote] It’s impossible to achieve this goal for a launchd agent. That’s because: A launchd agent must necessarily be running on the user associated with its session, otherwise it won’t be able to do agent-y things. If it is, the user can kill it. The only solution here is to structure your product so that: The core functionality lives in the daemon, which the user can’t kill [1]. The user doesn’t gain anything by killing your agent. [quote='759833021, gamakaze, /thread/759833, /profile/gamakaze'] I end up with two Agents, one owned by the user (the one I expect) and one owned by root. [/quote] It’s not clear how that comes about. One obvious way this can happen is if your agent loads into the pre-login session. However, you haven’t listed LoginWindow in your LimitLoadToSessionType. However^2, you earlier said that “They need to run during the login window”, which suggests tha
1w
Reply to Issue with UserDefaults Data Loss after App Transfer and TestFlight Installation
You keep writing “this issue”, which suggests that you think that this is a well-known limitation or bug. That’s not the case. I’m not aware of any systematic problems that would cause an app to lose all user defaults after an app transfer. Now, it’s possible that there is such a problem and I’ve just missed the memo. However, that seems unlikely given that I’ve not seen other reports like this here on DevForums, or as part of a DTS case. My best guess is that this is a bug in your code, and I’ve suggested ways that you might investigate that possibility. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
1w
Reply to Unarchiving an object with custom classes
Silly me... I would have been more productive if I have taken a closer look at the topic that I have accepted as an answer here. Nonetheless, I still don't get it. I have done many variations like the following. if let dict = try? NSKeyedUnarchiver.unarchivedObject(ofClasses: [NSDictionary.self, NSArray.self, NSString.self, CodeReadModel.self, CodeDataModel.self, NSString.self], from: data) { print(**** (dict)) } else { print(What!?) } They all go to the second print.
1w