• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

tecnickcom / gogen / 28756379100
100%

Build:
DEFAULT BRANCH: main
Ran 05 Jul 2026 10:07PM UTC
Jobs 1
Files 166
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

05 Jul 2026 10:02PM UTC coverage: 99.969%. Remained the same
28756379100

push

github

nicolaasuni
feat(logging)!: fix logsrv/logutil output defects, keep trace-id at root, and extend the config/trace/source API

Rework the logsrv and logutil packages for correctness, cross-package consistency, robustness, and performance. The shape of emitted logs changes (single timestamp, syslog-style level names, trace-id placement and deduplication), hence the breaking-change marker; every exported-signature change is additive.

Correctness:
- logsrv: emit a single "time" field per record (previously every record carried a duplicate "time" key from both the zerolog context and the slog-zerolog handler).
- Both: never emit a duplicate "trace_id" key — a caller-supplied root trace_id wins and the configured TraceIDFn is skipped when redundant.
- Both: resolve the trace id per record and keep it at the root even for loggers derived with WithGroup (logutil via a group-aware handler, logsrv via a slog-zerolog converter).
- Both: hooks now fire under FormatNone so log-driven side effects (e.g. metrics) are no longer silently dropped.
- logutil: render syslog-style level names (emergency, alert, critical, notice, ...) instead of slog's "ERROR+8"/"INFO+2" fallbacks; unrecognized levels keep slog's banded name.
- logutil: ParseLevel and ParseFormat return safe defaults (LevelInfo, FormatJSON) on invalid input instead of the most-verbose level and the discard format.

Robustness:
- Reject a nil output writer at construction and fall back to os.Stderr defensively instead of panicking on the first write; tolerate nil hook, writer, and config values.
- Honor the slog.Handler contract for empty WithAttrs and WithGroup.

Performance:
- FormatNone without a hook short-circuits to a zero-cost discard handler (~6 ns/op) instead of encoding every record into io.Discard.
- Keep the ungrouped JSON fast path allocation-free and resolve TraceIDFn lazily; console output is colorized only when writing to a terminal.
- Add benchmark suites covering the hot paths.

API additions (backwa... (continued)

178 of 178 new or added lines in 7 files covered. (100.0%)

13098 of 13102 relevant lines covered (99.97%)

90168.81 hits per line

Jobs
ID Job ID Ran Files Coverage
1 28756379100.1 05 Jul 2026 10:07PM UTC 166
99.97
GitHub Action Run
Source Files on build 28756379100
  • Tree
  • List 166
  • Changed 7
  • Source Changed 7
  • Coverage Changed 7
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #28756379100
  • 583d984d on github
  • Prev Build on main (#28753903637)
  • Next Build on main (#28759717689)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc