{"record":{"id":"5b23a23916af96e3","repo":"jdx/mise","slug":"managed-path-notifies-user-scope-bootstrap-se","errorCode":null,"errorMessage":"managed path '{}' notifies user-scope bootstrap service '{}'; notifications apply to system services only","messagePattern":"managed path '(.+?)' notifies user-scope bootstrap service '(.+?)'; notifications apply to system services only","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/system/services_common.rs","lineNumber":310,"sourceCode":"        .iter()\n        .map(|service| service.name.as_str())\n        .collect::<IndexSet<_>>();\n    for (resource, notification) in files\n        .iter()\n        .flat_map(|file| {\n            file.notify\n                .iter()\n                .map(move |notification| (file.path.as_path(), notification))\n        })\n        .chain(directories.iter().flat_map(|directory| {\n            directory\n                .notify\n                .iter()\n                .map(move |notification| (directory.path.as_path(), notification))\n        }))\n    {\n        if user_services.iter().any(|name| name == notification) {\n            bail!(\n                \"managed path '{}' notifies user-scope bootstrap service '{}'; notifications apply to system services only\",\n                resource.display(),\n                notification\n            );\n        }\n        if !configured.contains(notification.as_str()) {\n            bail!(\n                \"managed path '{}' notifies unconfigured bootstrap service '{}'\",\n                resource.display(),\n                notification\n            );\n        }\n    }\n    Ok(())\n}\n\nfn default_true() -> bool {\n    true","sourceCodeStart":292,"sourceCodeEnd":328,"githubUrl":"https://github.com/jdx/mise/blob/533346cc374382b41ec5ff70536252b2e96e725c/src/system/services_common.rs#L292-L328","documentation":"Managed-path `notify` entries can only trigger systemd notifications for system-scope services. mise validates that no managed path notifies a user-scope bootstrap service, since user services are not reachable through the system notification mechanism.","triggerScenarios":"`validate_notifications` walks managed resources with `notify` entries and finds a notification naming a service present in `user_services` — e.g. `[services.myapp] scope = \"user\"` while a managed file declares `notify = [\"myapp\"]`.","commonSituations":"Adding a notify reference to a service without checking its scope; converting a service from system to user scope while notifications remain; shared config where the service scope differs between machines.","solutions":["Remove the notification from the managed path's `notify` list","Or change the service to `scope = \"system\"` if a system service is intended","Point the notification at a system-scope service instead"],"exampleFix":"# before\n[[tasks]]\nnotify = [\"myapp\"]  # myapp is scope = \"user\"\n# after: change scope\n[services.myapp]\nscope = \"system\"","handlingStrategy":"validation","validationCode":"grep -rn 'notify' mise.toml | while read -r n; do check the referenced service's scope is \"system\"; done","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Only add notify entries for services declared with scope = \"system\"","Re-audit notify lists after changing a service's scope","Keep notify targets and service declarations in the same config file"],"tags":["config","systemd","validation"],"backgroundTag":"conflicting-config-options","analyzedSha":"533346cc374382b41ec5ff70536252b2e96e725c","analyzedAt":"2026-09-17T13:35:38.149Z","contentChangedAt":"2026-09-17T13:35:38.149Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}