failing XPC connection to SMAppService based LaunchDaemon on some macOS 26 Macs ("FATAL ERROR - fullPath is nil"?)

our app has a helper to perform privileged operations which communicates with the main app via xpc_connection*

previously that helper was installed via SMJobBless() into the /Library/LaunchDaemons/ and /Library/PrivilegedHelperTools/

due to various issues with the old SMJobBless() as well as it being deprecated we have ported the helper to the new SMAppService API where the helpers do not need to be installed but remain within the app bundle ( [[SMAppService daemonServiceWithPlistName:HELPER_PLIST_NAME] registerAndReturnError:&err] )

the new approach has been used in production for a year now and works fine in most cases and seems to be more reliable than the old SMJobBless().

however, we've observed two problems with the new helper architecture.

• sometimes when users update the app (with the built-in Sparkle framework), the app does not seem to have FullDiskAccess, although the checkbox in the system settings remains toggled on. only once the Mac has been restarted, things work fine again. since this is cured by a reboot, lets ignore this issue

• on some Macs, it just seems impossible to use the helper, while "installation" via SMAppService runs fine without error, using the helper always just fails with Connection invalid. This issue seems to affect ~0.2% of our users Macs, and we have found no cure yet how to get things into a working state on those Macs. luckily the issue also occurs 100% reproducible on one of the Macs in our office now. the problem seems to be a regression in macOS 26, as things worked absolutely fine on all previous macOS versions.

we'd like to investigate why the helper just won't work on some Macs. unfortunately even enabling Console logging for just a few seconds yields thousands of messages nowadays, but this may be insightful: we found that on the "bad Mac", the "FATAL ERROR - fullPath is nil" always appears and subsequently no working XPC connection to the helper is ever established. on the "good Macs", this "fullPath is nil" error never appears, and the XPC connection works fine after all the required permissions (helper permission, FDA permission) are granted.

so, my questons:

• has anyone else seen a problem where a SMAppService / XPC based priviledged helper just won't work on a handful of Macs?

• what about the "FATAL ERROR - fullPath is nil", is this the real root cause of the issue or should we look somewhere else? how can we prevent the issue on the affected Macs?

the only thing that seems to be clear here is that this is a macOS 26 Tahoe bug.

Answered by DTS Engineer in 873059022
since this is cured by a reboot, lets ignore this issue

Well, it’d be good to get a bug on file about that. If you see it on a machine you control, please grab a sysdiagnose log before and after the restart and file a bug describing the issue with those logs attached.

And please post your bug number, just for the record.


Regarding your main issue, you wrote:

the only thing that seems to be clear here is that this is a macOS 26 Tahoe bug.

That does seem likely. I’d like to get a bug on file about that too. So, something like this:

  1. Restart the Mac, just to clear away any cruft.
  2. Reproduce the problem, noting down the time.
  3. Grab a sysdiagnose shortly thereafter.
  4. File a bug with that sysdiagnose log, a general description of the problem, and the rough timestamp from step 2.

Once you’re done, please post your bug number.

If you want to dig into this yourself, you can do that using the sysdiagnose itself. Critical, it contains a log snapshot, system_logs.logarchive, which has some key advantages:

  • It’s a full fidelity snapshot of the log.
  • It’s not changing all the time, so you can investigate at your own pace.
  • You can use Console, and various other tools, to run structured queries on the log.

I have a bunch more hints and tips about working with the system log in Your Friend the System Log.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Log output in the "good case"

error	16:19:36.784221+0000	MacUpdater	Info: installHelperTool=>install called in response to 'install helper' button click
default	16:19:36.793426+0000	backgroundtaskmanagementd	effectiveItemDispositionWithAuditToken: pid=1133, type=daemon, url=Contents/Library/LaunchDaemons/com.corecode.MacUpdaterPrivilegedInstallHelperTool2.plist -- file:///, config={BTMConfigArguments =     ();BTMConfigBundleIdentifiers =     ();BTMConfigExecutablePath = "Contents/Resources/com.corecode.MacUpdaterPrivilegedInstallHelperTool2";BTMConfigLabel = "com.corecode.MacUpdaterPrivilegedInstallHelperTool2"; BTMConfigSHA256Checksum = {length = 32, bytes = 0xdb895cbb 550e1cf7 1174e785 98817f14 ... 36a73b15 dcffc6cc }; }
default	16:19:36.812777+0000	backgroundtaskmanagementd	effectiveItemDisposition: appURL=file:///Applications/MacUpdater.app/, type=daemon, url=Contents/Library/LaunchDaemons/com.corecode.MacUpdaterPrivilegedInstallHelperTool2.plist -- file:///, config={BTMConfigArguments =     ();BTMConfigBundleIdentifiers =     ();BTMConfigExecutablePath = "Contents/Resources/com.corecode.MacUpdaterPrivilegedInstallHelperTool2";BTMConfigLabel = "com.corecode.MacUpdaterPrivilegedInstallHelperTool2"; BTMConfigSHA256Checksum = {length = 32, bytes = 0xdb895cbb 550e1cf7 1174e785 98817f14 ... 36a73b15 dcffc6cc };}
error	16:19:36.812838+0000	backgroundtaskmanagementd	effectiveItemDisposition: record not found: appURL=/Applications/MacUpdater.app, url=/Contents/Library/LaunchDaemons/com.corecode.MacUpdaterPrivilegedInstallHelperTool2.plist, type=daemon, config={ BTMConfigArguments =     ( );BTMConfigBundleIdentifiers =     (); BTMConfigExecutablePath = "Contents/Resources/com.corecode.MacUpdaterPrivilegedInstallHelperTool2"; BTMConfigLabel = "com.corecode.MacUpdaterPrivilegedInstallHelperTool2"; BTMConfigSHA256Checksum = {length = 32, bytes = 0xdb895cbb 550e1cf7 1174e785 98817f14 ... 36a73b15 dcffc6cc }; }
default	16:19:36.813157+0000	MacUpdater	Service <private> status: 3
…
default	16:19:54.185694+0000	MacUpdater	[0x9e18c0c80] activating connection: mach=true listener=false peer=false name=com.corecode.MacUpdaterPrivilegedInstallHelperTool2
default	16:19:54.186103+0000	com.corecode.MacUpdaterPrivilegedInstallHelperTool2	[0x74acb4180] activating connection: mach=false listener=false peer=true name=com.corecode.MacUpdaterPrivilegedInstallHelperTool2.peer[1133].0x74acb4180
…

Log output in the "bad case"


error	16:40:03.112823+0100	MacUpdater	Info: installHelperTool=>install called in response to 'install helper' button click
default	16:40:03.124697+0100	backgroundtaskmanagementd	effectiveItemDispositionWithAuditToken: pid=19798, type=daemon, url=Contents/Library/LaunchDaemons/com.corecode.MacUpdaterPrivilegedInstallHelperTool2.plist -- file:///, config={ BTMConfigArguments =     ( ); BTMConfigBundleIdentifiers =     ( ); BTMConfigExecutablePath = "Contents/Resources/com.corecode.MacUpdaterPrivilegedInstallHelperTool2"; BTMConfigLabel = "com.corecode.MacUpdaterPrivilegedInstallHelperTool2"; BTMConfigSHA256Checksum = {length = 32, bytes = 0xdb895cbb 550e1cf7 1174e785 98817f14 ... 36a73b15 dcffc6cc };}
default	16:40:03.141046+0100	backgroundtaskmanagementd	effectiveItemDisposition: appURL=file:///Applications/MacUpdater.app/, type=daemon, url=Contents/Library/LaunchDaemons/com.corecode.MacUpdaterPrivilegedInstallHelperTool2.plist -- file:///, config={ BTMConfigArguments =     ( ); BTMConfigBundleIdentifiers =     ( ); BTMConfigExecutablePath = "Contents/Resources/com.corecode.MacUpdaterPrivilegedInstallHelperTool2"; BTMConfigLabel = "com.corecode.MacUpdaterPrivilegedInstallHelperTool2"; BTMConfigSHA256Checksum = {length = 32, bytes = 0xdb895cbb 550e1cf7 1174e785 98817f14 ... 36a73b15 dcffc6cc }; }
error	16:40:03.141098+0100	backgroundtaskmanagementd	effectiveDisposition: FATAL ERROR - fullPath is nil, container=(null), item=uuid=753BC2AC-6854-4F5D-B556-80A605739848, name=com.corecode.MacUpdaterPrivilegedInstallHelperTool2, type=daemon, disposition=[disabled, disallowed, notified], identifier=16.com.corecode.MacUpdaterPrivilegedInstallHelperTool2, url=Contents/Library/LaunchDaemons/com.corecode.MacUpdaterPrivilegedInstallHelperTool2.plist -- file:///
default	16:40:03.141324+0100	MacUpdater	Service <private> status: 0
…
default	16:40:18.433378+0100	MacUpdater	[0x91edf6300] activating connection: mach=true listener=false peer=false name=com.corecode.MacUpdaterPrivilegedInstallHelperTool2
default	16:40:18.433536+0100	MacUpdater	[0x91edf6300] failed to do a bootstrap look-up: xpc_error=[3: No such process]
default	16:40:18.433548+0100	MacUpdater	[0x91edf6300] invalidated after a failed init
error	16:40:18.497570+0100	MacUpdater	testConnection: exiting with ERROR  0x20a8d0c30 <dictionary: 0x20beb7c10> { count = 1, transaction: 0, voucher = 0x0, contents =	"XPCErrorDescription" => <string: 0x20beb7d58> { string cache = 0x0, length = 18, contents = "Connection invalid" }}
…

good logfile attached

bad logfiles here (too large to attach, bah)

https://230402id2zpmvv4ytt6.nextcloud.hosting.zone/s/gJzsxWR3JrMt6G9

since this is cured by a reboot, lets ignore this issue

Well, it’d be good to get a bug on file about that. If you see it on a machine you control, please grab a sysdiagnose log before and after the restart and file a bug describing the issue with those logs attached.

And please post your bug number, just for the record.


Regarding your main issue, you wrote:

the only thing that seems to be clear here is that this is a macOS 26 Tahoe bug.

That does seem likely. I’d like to get a bug on file about that too. So, something like this:

  1. Restart the Mac, just to clear away any cruft.
  2. Reproduce the problem, noting down the time.
  3. Grab a sysdiagnose shortly thereafter.
  4. File a bug with that sysdiagnose log, a general description of the problem, and the rough timestamp from step 2.

Once you’re done, please post your bug number.

If you want to dig into this yourself, you can do that using the sysdiagnose itself. Critical, it contains a log snapshot, system_logs.logarchive, which has some key advantages:

  • It’s a full fidelity snapshot of the log.
  • It’s not changing all the time, so you can investigate at your own pace.
  • You can use Console, and various other tools, to run structured queries on the log.

I have a bunch more hints and tips about working with the system log in Your Friend the System Log.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

failing XPC connection to SMAppService based LaunchDaemon on some macOS 26 Macs ("FATAL ERROR - fullPath is nil"?)
 
 
Q