I restored to a snapshot now and tried again.
This time, I think I did everything right:
Queried the status of my daemon, got notRegistered (0).
Installed my daemon using SMAppService. Didn't throw, entry appeared in Login Items.
Queried the status again, got requiresApproval (2).
Turned on the daemon in System Settings. Saw it start up and run, producing the expected periodic log messages.
Queried the status again, got enabled (1).
Unregistered the daemon. Saw it terminated and stop logging its periodic messages.
Queried the status again, got notRegistered (0).
However, the entry in System Settings > General > Login Items is not gone. It's still there and enabled.
It also persists across reboots & after removing all copies of my app.
So I guess there's still something I missed, or this is simply a bug in the current beta...
Topic:
App & System Services
SubTopic:
Core OS
Tags: