_configure_logging opened InodeAwareRotatingFileHandler against DECNET_SYSTEM_LOGS (default: relative decnet.system.log) without guarding OSError. Under systemd with ProtectSystem=full + ProtectHome=read-only and no writable path baked into the unit, the first import of decnet.config raised OSError and the daemon died before it could even print a useful error — the root-cause log line showed up in journalctl as a stack trace rather than a warning. Wrap the handler attachment in try/except OSError and log a single WARNING via the already-installed stream handler. stderr is always attached, so losing the file handler means operators tail journalctl / docker logs instead — the daemon keeps running.
5.4 KiB
5.4 KiB