Skip to content

feat(audit): expose journey_id filter in Traces.search() - #111

Merged
ngjunsiang merged 1 commit into
mainfrom
feat/110-traces-search-journey-id
Oct 20, 2026
Merged

ngjunsiang merged 1 commit into
mainfrom
feat/110-traces-search-journey-id

Conversation

@ngjunsiang

Copy link
Copy Markdown
Contributor

Closes #110.

What

Traces.search() gains a keyword-only journey_id: str | None = None filter, passed through as the journey_id query value exactly like the other optional filters (omitted from the query when None), and documented in the docstring.

Why

The audit server's search route honours journey_id — the login-journey tag from campus#803, shipped in campus#812 (merged to weekly) — but the Python client did not carry it, so library consumers could not filter by journey. This also unblocks the --journey flag for campus audit traces search (campus-cli#54), which was deliberately omitted until the library supported it.

Verification

  • New contract test test_search_sends_journey_id_when_given asserts the query param reaches the client; the pre-existing exact-dict assertion in test_search_gets_leaf_route_with_filters covers omission when not given.
  • Full suite: 292 passed locally (venv, Python 3.11); CI matrix runs 3.11–3.14.

Acceptance checklist (#110)

  • Traces.search(journey_id=...) sends journey_id as a query parameter; omitted when not given.
  • Docstring documents the filter (login-journey tag, campus#803).
  • Downstream: campus-cli --journey flag — separate repo, follow-up there.

The audit server's /traces/search honours a journey_id query param
(login-journey tag, campus#803, shipped in campus#812), but the
Python client did not carry it, so library consumers could not
filter by journey.

Add the keyword-only journey_id filter to Traces.search(), passed
through as a query value exactly like the other optional filters
(omitted when None), documented in the docstring.
@ngjunsiang
ngjunsiang merged commit dad0442 into main Oct 20, 2026
5 checks passed
@ngjunsiang
ngjunsiang deleted the feat/110-traces-search-journey-id branch October 20, 2026 13:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(audit): expose the server's journey_id filter in Traces.search()

1 participant