Repository navigation
Configure LogTape so Fedify federation logs surface - #182
Merged
Merged
Conversation
Fedify emits all of its logs through LogTape, which drops everything when no sink is configured, so inbox/outbox traffic and signature failures were invisible. Wire a console sink with FEDIFY_LOG_LEVEL (default info), attach an AsyncLocalStorage so Fedify's per-request context is carried, and silence the per-page-view 404 warnings from fedify.federation.http outside debug/trace. Co-authored-by: Claude Code <noreply@anthropic.com> Assisted-By: Claude Code(claude-fable-5-1)
|
Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configuration
⛔ Files ignored due to path filters (1)
📒 Files selected for processing (6)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fedify routes all of its logging through LogTape, and LogTape discards every record until a sink is configured. Moim never configured one, so inbox/outbox traffic, HTTP Signature failures, and unhandled activity types were invisible. This wires a console sink controlled by
FEDIFY_LOG_LEVEL(defaultinfo) and attaches anAsyncLocalStorageso Fedify's per-request log context is carried through.Why
Missing actor) only became visible after this change.withContext()per request; withoutcontextLocalStorageLogTape logsContext-local storage is not configuredtwice per request and drops the context.404warning underfedify.federation.httpfor every non-federation path it hands back to TanStack, i.e. every page view. That category is held toerrorunless the level isdebug/trace, where seeing every request path is the point.Commit History
src/server/logging.ts,FEDIFY_LOG_LEVELenv + docs, imports the config first inserver-entry.tsTest Plan
tsc --noEmitandoxlintpassFEDIFY_LOG_LEVEL=debug, an inbox POST showsfedify.federation.inbox/fedify.sig.*lines and nologtape.metawarningsinfolevel, page views produce nofedify.federation.http404 warningsinfoAssisted-By: Claude Code(claude-fable-5-1)