Post

Replies

Boosts

Views

Activity

Managing two helpbooks depending on MacOS user's version doesn't work
My application provides a unique feature for MacOS 26+ users, while keeping legacy for other versions (12.4+). So I aim to provide two help books localized package, depending on MacOS' version of the running computer. I designed two help bundles, with their own Info.plist files (identifiers, default filename…) and I've made multiple checks to verify that all their settings are correct and different when needed. As an app's info.plist can deal only with one Help Book, my application delegate registers both in applicationDidFinishLaunching: using: [[NSHelpManager sharedHelpManager] registerBooksInBundle:[NSBundle mainBundle]]; In Interface Builder, the help menu item is connected to the application delegate's "showHelp:" method to set the correct help package. The code in this method is: if (@available(macOS 26.0,*)){ helpbook = @"fr.myapp.updated.help"; } else { helpbook = @"fr.myapp.legacy.help"; } [[NSHelpManager sharedHelpManager] openHelpAnchor:@"index" inBook:helpbook]; The problem is that despite the MacOS version of the user's Mac, (either 15.1 or 26.2) , the «legacy» helpbook is always used. All default index.html (for each lproj) have a tag immediately after the I spent dozen of hours to understand the problem, forum parsing, including hours long dialogs with ChatGPT and Claude AIs (not mentioning MacOS' help system cache problems I could solve) I noticed also, to be complete, that when parsing the application package, opening the legacy .help with "Tips.app" always works, but with the "updated" one the help system opens with an "unavailable content" message. Both help bundles are fully included in the built application. Tested whether the app is installed in the debug directory, moved to in the Applications one, reboot, emptying/deleting cache files. So Houston, I have a problem… Any idea?
Topic: UI Frameworks SubTopic: AppKit
1
0
63
4w
Metal toolchain compilation error after migration to MacOS 26 and XCode 26.1
Hello. I migrated yesterday two machines from OS15 to OS26 (same Ram; M1Max chip). On the first one, a MBP, everything is allright, and my old Metal projects can compile and run, even with MacOS12 as a destination. On the second computer (MacStudio) I got a compile "error: cannot execute tool 'metal' due to missing Metal Toolchain; use: xcodebuild -downloadComponent MetalToolchain". I spent hours on many forums and tried all proposed solutions and still get the same error. Any idea? Thanks
2
0
159
Dec ’25
Mac Appstore upload: error, as Help bundle info.plist features an unexpected CFBundleExecutable key
Hello. My MacOS application has been regularly notarized for 12 weeks to allow people test the beta version, without any problem. Now the application is ready for Appstore submission. Unfortunately, the uploading process ends with an error: "Bad CFBundleExecutable. Cannot find executable file that matches the value of CFBundleExecutable in the nested bundle ApplicationHelp [fr.application.pkg/Payload/Application.app/Contents/Resources/ApplicationHelp.help] property list file." In the ApplicationHelp target, no CFBundleExecutable key is set. But if I read the Info.plist of the built help bundle, I can see that such key has been added during the build process. What can explain the presence of this key that seems to create the error when trying to upload the application package to the Appstore? The only keys set in the help bundle info.plist are: HPDBookAccessPath HPDBookIndexPath HPDBookTitle HPDBookType CFBundleDevelopmentRegion CFBundleIdentifier CFBundleSignature CFBundleVersion CFBundlePackageType CFBundleInfoDictionaryVersion Using Xcode 15.2 on Sonoma, application built for MacOS ≥ 12 (Apple Silicon only) Thanks
3
0
942
Apr ’24
After upgrading target to MacOS 12, cannot open or import any files
I recently updated my sandboxed application to the MacOS 12 target. Among deprecation, there is the allowedFileTypes method for NSOpenPanel/NSSavePanel, replaced with allowedContentTypes. I updated my document opening and importing methods to reflect this change. For example, to import a CSV or JSON file, I coded: myPanel.allowedContentTypes = [NSArray arrayWithObjects:UTTypeJSON, UTTypeCommaSeparatedText, UTTypeTabSeparatedText, [UTType typeWithIdentifier: @"org.openxmlformats.spreadsheetml.sheet"], nil] ; All these UTTypes are described in the "Imported Type UTIs" section of the app's Info.plist. Unfortunately, it is impossible to select any of Json, Csv or Xlsx file in the NSOpenPanel since I made these changes to be in line with MacOS12 requirements. Worse, I cannot open my own file format with its own UTI (described in Info.plist too)! The only way to open/import is to set myPanel.allowOtherFileTypes to TRUE, and to remove any code referring to allowedContentTypes. What is quite strange is that exporting works correctly after updating. My spotlight plugin works also (for my file format)… Something I missed? Help welcome as my app became useless since I made these changes, and I use it every day for my work (and improving it before launching it on the Appstore)
2
0
930
Jun ’22
MacOS: InApp discrepancy between price tier amount and price displayed to the user
Hello, I am testing an inApp purchase for a MacOS application I develop (sandboxed). I noticed that the price displayed to the user when he/she tries to test the inApp purchase is more expensive then the price tier set with Apple Connect for this inApp. The "purchase" (or restore) process is working perfectly but it always asks 2 euros more than the tier amount, whatever the latter is (tested on french store)? Thanks
1
0
888
Jun ’22
Spotlight importer: which key/value to make a file UTI seen as a "Spreadsheet" and not as "Other"
On my spreadsheet application, with its own UTI, I wrote a Spotlight importer plugin. It works well, except that Spotlight group the found files as "Other" and not as "Spreadsheet". My UTI conforms to public.spreadsheet. Any idea? Is there a special kMDxxx key/value to set for that in the importer?(see: https://developer.apple.com/library/archive/documentation/CoreServices/Reference/MetadataAttributesRef/Reference/CommonAttrs.html ) Thanks!
0
0
1.1k
Jun ’22
Sandbox allows or denies user-selected files to be saved
Two classes in my sandboxed application need to export a NSDictionary as a plist file. On the Capabilities, the Permission/Access setting is read/Write for User selected files. I use XCode 10.11.1 on Mojave, and build for ≥10.12. From several classes that need to export files, two are very similar and manage NSDictionary. For those two, when the user prompts for save, I open a NSSavePanel to choose the destination filename and directory. I use exactly the same code for my two classes: NSSavePanel *panel = [NSSavePanel savePanel]; [panel setNameFieldStringValue:newFilename]; panel.extensionHidden = TRUE; [panel beginWithCompletionHandler:^(NSInteger result) { if (result == NSFileHandlingPanelOKButton) { NSURL *saveURL = [panel URL]; NSString *savePath = [saveURL path]; if (![[savePath pathExtension] isEqual:@"plist"]){ savePath = [savePath stringByDeletingPathExtension]; savePath = [savePath stringByAppendingString:@".plist"]; } [exportDic writeToFile:savePath atomically:YES]; } }]; What is strange is that saving this ways always works for one class that use this code, whereas it doesn't succeed for the second class, except one non-reproductible time! I got no message on the debugger console, but I can see one in the Console application: Sandbox: MyApp (xxxx) deny(1) file-write-create my_file_path.plist I verified everything, reset the sandbox setting, clean build folder, quit/relaunched Xcode, and even rebooted the computer several times. Any idea? Thanks
3
0
2k
Apr ’21
Managing two helpbooks depending on MacOS user's version doesn't work
My application provides a unique feature for MacOS 26+ users, while keeping legacy for other versions (12.4+). So I aim to provide two help books localized package, depending on MacOS' version of the running computer. I designed two help bundles, with their own Info.plist files (identifiers, default filename…) and I've made multiple checks to verify that all their settings are correct and different when needed. As an app's info.plist can deal only with one Help Book, my application delegate registers both in applicationDidFinishLaunching: using: [[NSHelpManager sharedHelpManager] registerBooksInBundle:[NSBundle mainBundle]]; In Interface Builder, the help menu item is connected to the application delegate's "showHelp:" method to set the correct help package. The code in this method is: if (@available(macOS 26.0,*)){ helpbook = @"fr.myapp.updated.help"; } else { helpbook = @"fr.myapp.legacy.help"; } [[NSHelpManager sharedHelpManager] openHelpAnchor:@"index" inBook:helpbook]; The problem is that despite the MacOS version of the user's Mac, (either 15.1 or 26.2) , the «legacy» helpbook is always used. All default index.html (for each lproj) have a tag immediately after the I spent dozen of hours to understand the problem, forum parsing, including hours long dialogs with ChatGPT and Claude AIs (not mentioning MacOS' help system cache problems I could solve) I noticed also, to be complete, that when parsing the application package, opening the legacy .help with "Tips.app" always works, but with the "updated" one the help system opens with an "unavailable content" message. Both help bundles are fully included in the built application. Tested whether the app is installed in the debug directory, moved to in the Applications one, reboot, emptying/deleting cache files. So Houston, I have a problem… Any idea?
Topic: UI Frameworks SubTopic: AppKit
Replies
1
Boosts
0
Views
63
Activity
4w
Metal toolchain compilation error after migration to MacOS 26 and XCode 26.1
Hello. I migrated yesterday two machines from OS15 to OS26 (same Ram; M1Max chip). On the first one, a MBP, everything is allright, and my old Metal projects can compile and run, even with MacOS12 as a destination. On the second computer (MacStudio) I got a compile "error: cannot execute tool 'metal' due to missing Metal Toolchain; use: xcodebuild -downloadComponent MetalToolchain". I spent hours on many forums and tried all proposed solutions and still get the same error. Any idea? Thanks
Replies
2
Boosts
0
Views
159
Activity
Dec ’25
Mac Appstore upload: error, as Help bundle info.plist features an unexpected CFBundleExecutable key
Hello. My MacOS application has been regularly notarized for 12 weeks to allow people test the beta version, without any problem. Now the application is ready for Appstore submission. Unfortunately, the uploading process ends with an error: "Bad CFBundleExecutable. Cannot find executable file that matches the value of CFBundleExecutable in the nested bundle ApplicationHelp [fr.application.pkg/Payload/Application.app/Contents/Resources/ApplicationHelp.help] property list file." In the ApplicationHelp target, no CFBundleExecutable key is set. But if I read the Info.plist of the built help bundle, I can see that such key has been added during the build process. What can explain the presence of this key that seems to create the error when trying to upload the application package to the Appstore? The only keys set in the help bundle info.plist are: HPDBookAccessPath HPDBookIndexPath HPDBookTitle HPDBookType CFBundleDevelopmentRegion CFBundleIdentifier CFBundleSignature CFBundleVersion CFBundlePackageType CFBundleInfoDictionaryVersion Using Xcode 15.2 on Sonoma, application built for MacOS ≥ 12 (Apple Silicon only) Thanks
Replies
3
Boosts
0
Views
942
Activity
Apr ’24
After upgrading target to MacOS 12, cannot open or import any files
I recently updated my sandboxed application to the MacOS 12 target. Among deprecation, there is the allowedFileTypes method for NSOpenPanel/NSSavePanel, replaced with allowedContentTypes. I updated my document opening and importing methods to reflect this change. For example, to import a CSV or JSON file, I coded: myPanel.allowedContentTypes = [NSArray arrayWithObjects:UTTypeJSON, UTTypeCommaSeparatedText, UTTypeTabSeparatedText, [UTType typeWithIdentifier: @"org.openxmlformats.spreadsheetml.sheet"], nil] ; All these UTTypes are described in the "Imported Type UTIs" section of the app's Info.plist. Unfortunately, it is impossible to select any of Json, Csv or Xlsx file in the NSOpenPanel since I made these changes to be in line with MacOS12 requirements. Worse, I cannot open my own file format with its own UTI (described in Info.plist too)! The only way to open/import is to set myPanel.allowOtherFileTypes to TRUE, and to remove any code referring to allowedContentTypes. What is quite strange is that exporting works correctly after updating. My spotlight plugin works also (for my file format)… Something I missed? Help welcome as my app became useless since I made these changes, and I use it every day for my work (and improving it before launching it on the Appstore)
Replies
2
Boosts
0
Views
930
Activity
Jun ’22
MacOS: InApp discrepancy between price tier amount and price displayed to the user
Hello, I am testing an inApp purchase for a MacOS application I develop (sandboxed). I noticed that the price displayed to the user when he/she tries to test the inApp purchase is more expensive then the price tier set with Apple Connect for this inApp. The "purchase" (or restore) process is working perfectly but it always asks 2 euros more than the tier amount, whatever the latter is (tested on french store)? Thanks
Replies
1
Boosts
0
Views
888
Activity
Jun ’22
Spotlight importer: which key/value to make a file UTI seen as a "Spreadsheet" and not as "Other"
On my spreadsheet application, with its own UTI, I wrote a Spotlight importer plugin. It works well, except that Spotlight group the found files as "Other" and not as "Spreadsheet". My UTI conforms to public.spreadsheet. Any idea? Is there a special kMDxxx key/value to set for that in the importer?(see: https://developer.apple.com/library/archive/documentation/CoreServices/Reference/MetadataAttributesRef/Reference/CommonAttrs.html ) Thanks!
Replies
0
Boosts
0
Views
1.1k
Activity
Jun ’22
Sandbox allows or denies user-selected files to be saved
Two classes in my sandboxed application need to export a NSDictionary as a plist file. On the Capabilities, the Permission/Access setting is read/Write for User selected files. I use XCode 10.11.1 on Mojave, and build for ≥10.12. From several classes that need to export files, two are very similar and manage NSDictionary. For those two, when the user prompts for save, I open a NSSavePanel to choose the destination filename and directory. I use exactly the same code for my two classes: NSSavePanel *panel = [NSSavePanel savePanel]; [panel setNameFieldStringValue:newFilename]; panel.extensionHidden = TRUE; [panel beginWithCompletionHandler:^(NSInteger result) { if (result == NSFileHandlingPanelOKButton) { NSURL *saveURL = [panel URL]; NSString *savePath = [saveURL path]; if (![[savePath pathExtension] isEqual:@"plist"]){ savePath = [savePath stringByDeletingPathExtension]; savePath = [savePath stringByAppendingString:@".plist"]; } [exportDic writeToFile:savePath atomically:YES]; } }]; What is strange is that saving this ways always works for one class that use this code, whereas it doesn't succeed for the second class, except one non-reproductible time! I got no message on the debugger console, but I can see one in the Console application: Sandbox: MyApp (xxxx) deny(1) file-write-create my_file_path.plist I verified everything, reset the sandbox setting, clean build folder, quit/relaunched Xcode, and even rebooted the computer several times. Any idea? Thanks
Replies
3
Boosts
0
Views
2k
Activity
Apr ’21