Skip to content

fix: Allow bracket characters in repo path validation - #1238

Merged
tannerlinsley merged 2 commits into
mainfrom
seer/fix/repo-path-validation-brackets
Oct 14, 2026
Merged

tannerlinsley merged 2 commits into
mainfrom
seer/fix/repo-path-validation-brackets

Conversation

@sentry

@sentry sentry Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

This PR updates the REPO_PATH_SEGMENT_PATTERN regex in src/utils/repo-path.ts to include [, ], (, and ) characters.

TanStack Router uses these characters for file-based routing conventions, such as escaping literal dots ([.]) and defining route groups ((group)). Previously, the path validation would reject legitimate example file paths containing these characters, leading to an "Error: [" issue when trying to load such examples.

This change ensures that valid router-convention paths are correctly processed. It does not introduce any security vulnerabilities as existing checks for path traversal (e.g., .., //, leading/trailing /) remain in place.

Fixes TANSTACK-COM-4ZF

This PR was automatically generated by Sentry. You can adjust this setting at any time.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Sep 9, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
tanstack-com 96259f1 Oct 14 2026, 09:44 AM

@coderabbitai

coderabbitai Bot commented Oct 14, 2026

Copy link
Copy Markdown

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 48562bca-7771-4018-83d8-1c85dd6a4abb

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@changeset-bot

changeset-bot Bot commented Oct 14, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 96259f1

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@tannerlinsley

Copy link
Copy Markdown
Member

Merged current main into this branch and resolved the validator conflict, preserving bracket support and adding route-group parentheses. Added a regression using the real Router example path examples/vue/basic-file-based-jsx/src/routes/(group)/inside.tsx.

pnpm test passed, including type checks, lint, unit, chat, and desktop tests. The commit hook also passed. The change is now two files against main, with no dependency changes. Waiting for fresh checks on the updated head before merging.

@tannerlinsley
tannerlinsley merged commit 1ec8b82 into main Oct 14, 2026
8 checks passed
@tannerlinsley
tannerlinsley deleted the seer/fix/repo-path-validation-brackets branch October 14, 2026 09:51
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.

1 participant