Posts

Post not yet marked as solved
1 Replies
475 Views
While reviewing our app to prepare for macOS Monterey, I noticed an error when restoring purchased subscriptions. The error is issued via the following log method: - (void)paymentQueue:(SKPaymentQueue*)queue restoreCompletedTransactionsFailedWithError:(NSError*)error The error is the following: Error Domain=SKErrorDomain Code=0 "UNKNOWN_ERROR" UserInfo={NSLocalizedDescription=UNKNOWN_ERROR, NSUnderlyingError=0x600003c9b690 {Error Domain=ASDErrorDomain Code=950 "Unhandled exception" UserInfo={NSLocalizedDescription=Unhandled exception, NSLocalizedFailureReason=An unknown error occurred}}} Is this error known? Has the API for macOS Monterey changed? How can we solve that issue?
Posted Last updated
.
Post not yet marked as solved
0 Replies
565 Views
I have noticed that our app on macOS Monterey cannot find email files with .emlx or .eml extension stored in directories shared with the app. I am aware that email indexing on macOS Big Sur has migrated to Core Spotlight and thus can no longer be found via Spotlights. However, a metadata importer for the file formats is available under macOS Big Sur. So if files are in either file format and have been placed in a shared directory, they can be found via Spotlight. Under macOS Monterey I find that the full text of such files is not indexed. You can reproduce this behaviour with the following examples. Precondition: In one of the accessible directories, for example for documents, there is at least one file with the extension .emlx or .eml. The following query shows a list of emails in the user directory: mdfind -onlyin ~ "kMDItemContentTypeTree == 'public.message'" The following query returns the corresponding email with the filename 20.emlx: mdfind -onlyin ~ "* == '20.emlx' && kMDItemContentTypeTree == 'public.message'" The following query already returns no results. A tokenizing of the titles does not take place: mdfind -onlyin ~ "* == '20' && kMDItemContentTypeTree == 'public.message'" The following question does not return any results, although the word is contained in the text of an e-mail: mdfind -onlyin ~ "kMDItemTextContent == 'apple' && kMDItemContentTypeTree == 'public.message'" Does anyone know if the reason is that this is an early beta version or do we need to prepare for a helper solution, for example with SKSearch Kit?
Posted Last updated
.
Post not yet marked as solved
19 Replies
6.6k Views
Our app was rejected because of an outdated entitlement key. We have to use this key, because othervise our app won't. work.Our app makes use of the scripting bridge. I we follow the documentation, we should use the com.apple.security.automation.apple-events key. The app would prompt a dialogue to ask the user to grant access to apple events.In practice, I doeasn't work. We need to add com.apple.security.temporary-exception.apple-events for the particular app, we use scripting bridge for. If we do that, the system promts the dialogue as expected and the spcipting bridge wordls. I seems to be a bug of macOS. However we need to resolve the issue, because the app is rejected and the reviewer doesn't respond to our explanation. I don't understand the problem. The seucrity mechanism of macOS is working and the user experience is aligned with Apple's requirements. We just need to use the old entitlement as a workaround until Apple will fix this bug. We also want to be compatible with Sierra and High Sierra, which don't know the new entitlement, that is introduced with Mojave.Some ideas?
Posted Last updated
.
Post not yet marked as solved
1 Replies
330 Views
We need to parse emails in our app, that are sometimes encoded in NSISOLatin1StringEncoding instead of NSUTF8StringEncoding. Unfortunately the convenient method stringByReplacingPercentEscapesUsingEncoding for NSString objects is deprecated. The recommended method stringByRemovingPercentEncoding is not sufficient for our use case. How to transform NSString objects with iso-8859-1 encoding?
Posted Last updated
.
Post not yet marked as solved
0 Replies
383 Views
I have trained a text classification model with CreateML. I excited about the convenient tool and the precision of the model. However, there are some false positives. I realized, that the classification of the model has no probability parmater to decide, wether the app should take or drop the classification ot avoid false positives. Is there a way to get the probability value? Maybe I have to train the model in a different way? The model description in Xcode is quite clear: Text as input, classification string as output. Nothing more.
Posted Last updated
.
Post not yet marked as solved
0 Replies
359 Views
Our app accepts a dropped email, that was dragged from a list entry in the defa8lt Mail.app. This is not possible in Catalina Beta any more. While the app get the full email with sender, recipient, subject, data dn body in High Sierra, it's only the subject in Catalina Beta.We are using the following properties in the app's plist file:<key>CFBundleDocumentTypes</key> <array> <dict> <key>CFBundleTypeName</key> <string>Plain text</string> <key>LSHandlerRank</key> <string>Alternate</string> <key>CFBundleTypeRole</key> <string>Viewer</string> <key>LSItemContentTypes</key> <array> <string>public.text</string> </array> </dict> <dict> <key>CFBundleTypeName</key> <string>HTML</string> <key>LSHandlerRank</key> <string>Alternate</string> <key>CFBundleTypeRole</key> <string>Viewer</string> <key>LSItemContentTypes</key> <array> <string>public.html</string> </array> </dict> <dict> <key>CFBundleTypeName</key> <string>Contact</string> <key>LSHandlerRank</key> <string>Alternate</string> <key>CFBundleTypeRole</key> <string>Viewer</string> <key>LSItemContentTypes</key> <array> <string>public.contact</string> </array> </dict> <dict> <key>CFBundleTypeName</key> <string>General files and folders</string> <key>LSHandlerRank</key> <string>Alternate</string> <key>CFBundleTypeRole</key> <string>Viewer</string> <key>LSItemContentTypes</key> <array> <string>public.data</string> <string>public.directory</string> </array> </dict></array>Further more we use send types for a service provider. In a test app I tried all known pasteboard types. <array> <string>NSPasteboardTypeURL</string> <string>NSPasteboardTypeColor</string> <string>NSFileContentsPboardType</string> <string>NSFilesPromisePboardType</string> <string>NSPasteboardTypeFileURL</string> <string>NSFindPanelSearchOptionsPboardType</string> <string>NSPasteboardTypeFont</string> <string>NSPasteboardTypeHTML</string> <string>NSInkTextPboardType</string> <string>NSPasteboardTypeMultipleTextSelection</string> <string>NSPasteboardTypePDF</string> <string>NSPasteboardTypePNG</string> <string>NSPostScriptPboardType</string> <string>NSPasteboardTypeRTF</string> <string>NSPasteboardTypeRTFD</string> <string>NSPasteboardTypeRuler</string> <string>NSPasteboardTypeSound</string> <string>NSPasteboardTypeString</string> <string>NSPasteboardTypeTabularText</string> <string>NSPasteboardTypeTextFinderOptions</string> <string>NSPasteboardTypeTIFF</string> <string>NSVCardPboardType</string></array>Hopefully it's a bug and not another feature, tha tlimits the options for developers. Doeas someone knoe a workaround? Maybe we have to use another document type, that our acc could receive the raw mail data and parse it.
Posted Last updated
.
Post not yet marked as solved
0 Replies
267 Views
Our app uses a service provider to get a seleted email in default Mail.app. This works perfect in High Sierra but not with Catalina any more. The pasteboard in Catalina is empty. Here is a code snipped of our plist file, that defines the service provider:<dict> <key>NSKeyEquivalent</key> <dict> ... </dict> <key>NSMenuItem</key> <dict> ... </dict> <key>NSMessage</key> <string>...</string> <key>NSPortName</key> <string>...</string> <key>NSRequiredContext</key> <dict> <key>New item</key> <string></string> </dict> <key>NSSendTypes</key> <array> <string>public.plain-text</string> <string>public.rtf</string> <string>public.contact</string> <string>NSURLPboardType</string> <string>NSFilenamesPboardType</string> <string>NSFilesPromisePboardType</string> <string>NSPasteboardTypeURL</string> <string>NSPasteboardTypeFileURL</string> <string>NSRTFDPboardType</string> <string>NSPasteboardTypeMultipleTextSelection</string> <string>NSPasteboardTypePDF</string> </array></dict>Maybe we have to add another pasteboard type? Or is this behaviour another bug or even feature of Catalina? Has someone an idea?
Posted Last updated
.
Post not yet marked as solved
2 Replies
1.1k Views
I would lime to read the content of a selected note with AppleScript. Here is the simplified script:using terms fromapplication "Notes" tell application "Notes" log selection log (count of selection) log item 1 of selection set theNote to item 1 of selection log name of theNote end tell endusing terms fromUnfortunately I get the error message. Here is the log output:(*selection*) (*1*) (*item 1 of selection*) Result: error "Notes got an error: Can’t make item 1 of selection into type specifier." number - 1700 from item 1 of selection to specifierHas someone an idea?
Posted Last updated
.
Post not yet marked as solved
16 Replies
5.4k Views
Spotlight search for emails neither works with MDQueryRef nor with mdfind in the Terminal.app even if the user has granted full disc access for the app in the security settings. The application logic of our app works for High Sierra bot not for Catalina any more. Is this a bug or a feature? Hopefully it's not a feature. Other content like documents, calendar events and contacts can be retrieved by MDQueryRef. If I search with the default Spotlight interface (command-space), I can find emails. But even if I select "Show in Finder" in the result list, the Finder window is empty. Even with sudo mdfind, I can't find any email. I also can't add an email to the index with mdimport to the index, neither with the logged in user nor with sudo. Does someone has a solution? Hopefully we needn't index emails With Search Kit on our own in the future.
Posted Last updated
.
Post not yet marked as solved
2 Replies
424 Views
Our app uses a NSUserAppleScriptTask to capture the users context and provide contextual content. While our approach works fine for macOS High Sierra, the app thriws an error with macOS Catalina:Script execution failed: The operation couldn’t be completed. /Users/.../Default.scpt: script error: Unknown AppleEvent address type. (-1716)If we call the script with the Script Editor everything is fine. I assume we have to use different parameters for the NSAppleEventDescriptor for macOS Cataline. Here is the relevant code snipped:NSAppleEventDescriptor *paramter = [NSAppleEventDescriptor listDescriptor]; [paramter insertDescriptor:[NSAppleEventDescriptor descriptorWithString:bundleId] atIndex:0]; NSAppleEventDescriptor *event = [NSAppleEventDescriptor appleEventWithEventClass:kASAppleScriptSuite eventID:kASSubroutineEvent targetDescriptor:nil returnID:kAutoGenerateReturnID transactionID:kAnyTransactionID]; [event setDescriptor:[NSAppleEventDescriptor descriptorWithString:@"getContext"] forKeyword:keyASSubroutineName]; [event setDescriptor:paramter forKeyword:keyDirectObject]; NSUserAppleScriptTask *script = [[NSUserAppleScriptTask alloc] initWithURL:scriptURL error:&fileError]; ... [script executeWithAppleEvent:event completionHandler:^(NSAppleEventDescriptor * _Nullable result, NSError * _Nullable error) { ... }Apples error documentation says:-1716The target address type of an Apple event is unknownI think, Cataline doesn't accept, that the targetDescriptor parameter is nil. However the developer documentation says:A pointer to a descriptor that identifies the target application for the Apple event. Passing nil results in an Apple event descriptor that has no keyAddressAttr attribute (it is valid for an Apple event to have no target address attribute).Has someone any idea for a solution?
Posted Last updated
.
Post not yet marked as solved
1 Replies
762 Views
Our app uses Apple Script to communicate with other installed apps. If a user hasen't installed one of these apps, that are part of the script, the system shows a dialogie to select the missing app. The script never troes to script an app, if the app is not installed. However, the dialog is triggered, when the Apple Script is loaded. How can we suppress this dialogue?
Posted Last updated
.
Post not yet marked as solved
4 Replies
3.0k Views
Because of a missing replacement of deprecated temporary exceptions for the scripting bridge, we need a technical solution for the professional requirements, that is accepted for publication in the app store. See also this thread: https://forums.developer.apple.com/thread/111287A suggested solution in the linked thread is to split up the app. We could provide core features in our app for the store and in addition a helper app, that the users can download form outside the store. The idea is, that the store app would be scriptable. Instead of the store app a helper helper app would respond to a shortcut in a service provider, capture the user's context with scripting bridge and forward the result to the scriptable main store app.I could find a good tutorial with an example project in Github to make an app scriptable. I'm also familiar with service provider implementation, but not familar with helper apps. It should be an app, that has no user interface and would be startet by the store app after the helper app has been downloaded an installed. I think the correct approach is an XPCServer. Does someone know a good tutorial or example project?Edit: I just reviewed the code template of Xcode. A scriptable app seems not necessary with XPCService and the process flow would be different. The main app would be triggered by a shortcut like today. This main app would ask the XPCService to capture the user's context with the scripting bridge and would receive the artifact to proceed with the data analysis process for retrieving contextual content. I couldn't find instruction how to install a helper tool and start the XPC service from the main app.
Posted Last updated
.
Post not yet marked as solved
3 Replies
1.4k Views
It becomes crazy. Our macOS app was again rejected, after we have removed the link to our payed cloud service. It's not possible to migrate the order, payment and account management of a cloud service to an in-app purchase. There are many apps in the macOS app store, which depend on externally payed services like OneDrive, Xing, LinkedIn. However we have removed the link to our homepage in the account setting for integrating data of our cloud service. Our app is a utility to find content from several sources, which can be configured in a list of account settings.Now the reviewer rejected our app, becuase of a link to our forum with a user guide.Here is the explnation of the reviewer:Guideline 3.1.1 - BusinessYour app or its metadata includes a link to external mechanisms to purchase or subscribe to content outside of the app.There is no call to action to buy something. And the forum is free. It's even not necessary to register to the forum to read the article. It's just a customer friendly to reference a forum with a guide and the option to ask questions.What's up with Apple? We want to make business with them and have already in-app purchases for additional features in our app. I'm afraid that our management will stop the macOS development with this problems. We need to publish a Mojave compatibility update and this link was not new. How can the resolve the problem? Has someone an idea?
Posted Last updated
.
Post not yet marked as solved
0 Replies
515 Views
We are migrating our app to Mojave. Currently I'm working on the dark mode. Almost everything is automartically adopted. I have just problems with the QLPreviewView and NSTextView. Do the have to set a specific property of the QLPreviewView?Do we have to set the background and text color in the NSAttributedString manually?
Posted Last updated
.
Post not yet marked as solved
6 Replies
1k Views
Today we received a rejerction of a minor update of our app. We have a kind of sticky note at the bottom of a list of content, that tells the user, that he or sche can integrate more sources with our payed cloud sercice. A button links to our homepage. It's just an option and the ad disappears, if the user clicks on the button to get more information.We also use in-app-purchases for some additional features of the app, but we can't migrate our booking and paymend process of our cloud source to an in-app-purche, not only for technical but also for economic reasons. I think, it should be possible to link external payed services, because other apps with payed service like LinkedIn don't use in-app-purchase either. It is very frustrating. Microsoft's review process is also accurate on the App Store, but it does not limit software vendors to that extent. Since the market for macOS apps is relatively small compared to Windows apps, it is not easy to convince shareholders or management to continue product development under these circumstances.Has someone an idea, how to link information about an external service, that increases the user experience of an app? Do we have to use a special wording like "optional" or "learn more" instead of something like "get our cloud service"? We will also offer free accounts in addition to payed accounts for our cloud service soon. Would this make a difference?
Posted Last updated
.