mirror of
https://github.com/abhigyanpatwari/GitNexus.git
synced 2026-11-04 07:27:20 +00:00
|
Some checks are pending
CodeQL / Analyze (javascript-typescript) (push) Waiting to run
CodeQL / Analyze (python) (push) Waiting to run
Gitleaks / gitleaks (push) Waiting to run
Publish / Classify release event (push) Waiting to run
Publish / RC guard (marker + release-PR skip) (push) Blocked by required conditions
Publish / ci (push) Blocked by required conditions
Publish / Publish to npm (push) Blocked by required conditions
Publish / Build & Push RC Docker images (push) Blocked by required conditions
Scorecard / Scorecard analysis (push) Waiting to run
Trivy Image Scan / Trivy (gitnexus-cli) (push) Waiting to run
Trivy Image Scan / Trivy (gitnexus-web) (push) Waiting to run
* feat(logger): let a host route GitNexus records into its own sink A process that embeds GitNexus had no supported way to send the logger's records into its own logging: the singleton and every named child write to stderr, and the only redirect was the test-only capture (#3620). configureLoggerSink({ destination, level, mixin }) routes the default logger and every later createLogger() child to the host's destination, with the mixin's fields on each record, and returns a function that puts the previous state back. flushLoggerSync() flushes a sink destination that has flushSync. Without a call nothing changes: the default path gains one branch at logger construction and none per record, no pretty transport or exit hook is installed for a host sink, and a test capture keeps precedence while it is active. * fix(logger): retire a sink on restore so an out-of-order restore cannot revive it A restore that found its sink displaced by a later one returned without a trace, and the later sink's restore then handed the state back to the sink whose owner had already restored it (review on #3729). A restore now retires its sink for good: when active, the nearest earlier sink that is still live becomes active again, else stderr; when displaced, the active state is left alone but the sink can no longer come back. * test(logger): cover a warn-level host sink and a restore across two retired owners A sink that already enables debug cannot tell whether a child honoured debugEnvVar or only inherited the sink level: dropping debugRequested from the host-sink branch left all 32 tests green. The warn-level case drops an ordinary child's debug record and keeps the debugEnvVar child's. The three-sink case walked past a single retired owner, so a one-hop lookup in nearestLiveSink also passed. Four sinks, with both middle owners retired before the newest restores, reach the oldest live sink only through the loop. --------- Co-authored-by: Gergő Magyar <gergomagyar@icloud.com> |
||
|---|---|---|
| .. | ||
| fixtures | ||
| helpers | ||
| integration | ||
| unit | ||
| utils | ||