Skip to content

Replace static parameters in route pattern for telemetry - #2

Open
tomerqodo wants to merge 8 commits into
codex_only-issues-20260113-augment-codex-sentry_base_replace_static_parameters_in_route_pattern_for_telemetry_pr20from
codex_only-issues-20260113-augment-codex-sentry_head_replace_static_parameters_in_route_pattern_for_telemetry_pr20
Open

tomerqodo wants to merge 8 commits into
codex_only-issues-20260113-augment-codex-sentry_base_replace_static_parameters_in_route_pattern_for_telemetry_pr20from
codex_only-issues-20260113-augment-codex-sentry_head_replace_static_parameters_in_route_pattern_for_telemetry_pr20

Conversation

@tomerqodo

Copy link
Copy Markdown

Benchmark PR from qodo-benchmark#20

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4404a33d5d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +30 to +34
var result = string.Join(SeparatorString, segments);

// Preserve leading slash from raw text
if (pattern.RawText is { Length: > 0 } rt && rt[0] == Separator)
{

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve trailing slash when rebuilding debug string

When a template has required values, Format rebuilds the route string from PathSegments and only re-adds a leading slash. This drops a trailing slash that was present in RawText (e.g., a template like "/{controller}/" with required values will become "/Home" instead of "/Home/"). Trailing slashes are significant in routing and are preserved in RawText, so losing them changes IRouteDiagnosticsMetadata/display names and can conflate /foo with /foo/ in telemetry and diagnostics. Consider appending a trailing separator when RawText ends with /.

Useful? React with 👍 / 👎.

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.

2 participants