Conversation
Add `pup profiling explore callgraph`, calling the new prof-gateway /api/unstable/profiling/pup/explore/callgraph endpoint (PROF-16038). - explore_callgraph in src/commands/profiling.rs, mirroring explore_flamegraph (query/trace/profile scoping, profile-id+event-id pairing validation) - ProfilingExploreActions::Callgraph clap variant and dispatch in src/main.rs - Tests for happy path, scoping/pairing validation, null optional fields, validation errors, and missing auth - Call graph examples in docs/EXAMPLES.md and command listing in docs/COMMANDS.md Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The backend's traceContext requires traceId, spanId and timeHint (epoch seconds) together and rejects requests with a null timeHint, so `--trace-id` scoping could never succeed. - Add a shared trace_context_json helper that validates the three flags together and converts --time-hint (any pup time format) to epoch seconds - Add --time-hint to `pup profiling explore callgraph` - Tests for the helper and for the callgraph traceContext request body Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…trace scoping The backend's traceContext requires traceId, spanId and timeHint (epoch seconds) together and rejects a null timeHint, so `--trace-id` scoping on `explore flamegraph` and `profile-types list` always failed validation. - Build traceContext via the shared trace_context_json helper, which validates the three flags together and converts --time-hint to epoch seconds - Add --time-hint to `profiling explore flamegraph` and `profiling profile-types list` - Assert timeHint in the profile-types trace test; add a flamegraph trace-context request body test Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
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.
What does this PR do?
Fixes
--trace-idscoping forpup profiling explore flamegraphandpup profiling profile-types list.The backend's
traceContextrequirestraceId,spanIdandtimeHint(epoch seconds) together, and rejects a nulltimeHintwith a 400. Since #819, pup senttimeHint: nulland didn't require--span-id, so both commands failed whenever they were scoped by trace.traceContextvia the sharedtrace_context_jsonhelper from feat(profiling): add continuous profiler callgraph exploration #876. The helper requires--trace-id,--span-idand--time-hinttogether and converts--time-hint(Unix timestamp, RFC3339, relative time, etc.) to epoch seconds.--time-hintflag on both commands (src/main.rs).timeHint, and there's a new flamegraph trace-context request-body test. The helper's own tests are in feat(profiling): add continuous profiler callgraph exploration #876.docs/EXAMPLES.md: the profile-types trace example passes--time-hint.Motivation
Found while adding call graph (#876) and timeline (#877) exploration. Both have the same
traceContextcontract, and #876 applies this fix for call graph.Additional Notes
trace_context_jsonhelper, so the diff includes feat(profiling): add continuous profiler callgraph exploration #876's commits until it merges. Only the last commit (fix(profiling): require --time-hint ...) is new here.--trace-idwithout--span-id/--time-hintis now rejected client-side instead of with a backend 400. Trace scoping never worked before, so this breaks no working usage.Checklist
Related Issues
Fixes trace scoping from #819. Depends on #876.
Plan
Prompts
🤖 Generated with Claude Code