Skip to content

fix: upddate @msw/url to 0.1.3 - #2840

Merged
kettanaito merged 2 commits into
mainfrom
fix/update-msw-url
Nov 17, 2026
Merged

kettanaito merged 2 commits into
mainfrom
fix/update-msw-url

Conversation

@kettanaito

Copy link
Copy Markdown
Member

Fixes #2836

@coderabbitai

coderabbitai Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

Explain Change β†’

No actionable comments were generated in the recent review.

Walkthrough

The @msw/url dependency range in package.json changed from ^0.1.2 to ^0.1.3.

Changes: URL Dependency Update

Layer / File(s) Summary
Update URL dependency range
package.json
The @msw/url dependency range changed from ^0.1.2 to ^0.1.3.

Estimated code review effort: 2 (Simple) | ~8 minutes

Change: Bug fix Β· Severity of issue fixed: Medium

Merge Risk: Minimal Β· up to 40f9a

This updates a URL-matching dependency to a patch release that addresses optional and zero-or-more path parameters not matching without a trailing slash. No merge-blocking risk remains.

Pre-merge checks: Passed 3 Β· Inconclusive 1

Failed Failed checks: 1 inconclusive

Check name Status Explanation Resolution
Linked Issues check Inconclusive Issue #2836 requires that omitted optional (?) and zero-or-more (*) parameters after another parameter match. Examples: /users/:id/:tab? matches /users/1 with { id: "1" }, and `/users/:id/fi… Provide evidence that @msw/url 0.1.3 changes the trailing-optional and zero-or-more matching behavior described in #2836. Acceptable evidence includes the mswjs/url release notes or diff for 0.1.3, or a test run showing the four `matchP…
Passed Passed checks: 3 passed

Check name Status Explanation
Title check Passed The title names the change: it updates the @msw/url dependency to 0.1.3 as a fix. The raw summary confirms the package.json range change from ^0.1.2 to ^0.1.3. The title has a typo ("upddate"), which …
Description check Passed The description references issue #2836, which the linked objectives describe as a request about optional and zero-or-more path parameter matching. The change bumps @msw/url to 0.1.3, which relates to …
Out of Scope Changes check Passed The only reviewed change is the @msw/url dependency range in package.json, raised from ^0.1.2 to ^0.1.3 (+1/-1). This change directly supports the #2836 objective, because the issue attributes…
Full details: Title check

Explanation

The title names the change: it updates the @msw/url dependency to 0.1.3 as a fix. The raw summary confirms the package.json range change from ^0.1.2 to ^0.1.3. The title has a typo ("upddate"), which does not change its meaning.

Full details: Description check

Explanation

The description references issue #2836, which the linked objectives describe as a request about optional and zero-or-more path parameter matching. The change bumps @msw/url to 0.1.3, which relates to that fix. The description is brief but relevant.

Full details: Out of Scope Changes check

Explanation

The only reviewed change is the @msw/url dependency range in package.json, raised from ^0.1.2 to ^0.1.3 (+1/-1). This change directly supports the #2836 objective, because the issue attributes the defect to @msw/url. No unrelated source, test, or documentation changes appear in the summary. The issue's side note about get-clean-url-string.ts (| inside the character class) is described as "worth noting" and is not a stated objective. Its absence from this PR is not an out-of-scope change.

Full details: Linked Issues check

Explanation

Issue #2836 requires that omitted optional (?) and zero-or-more (*) parameters after another parameter match. Examples: /users/:id/:tab? matches /users/1 with { id: "1" }, and /users/:id/files/:path* matches /users/1/files. The root cause, per the issue, is in @msw/url (matchLiteral and matchTokensLinear). This PR changes only package.json, raising the @msw/url range from ^0.1.2 to ^0.1.3. The reviewed diff contains no matching logic or tests. The fix therefore depends entirely on the content of @msw/url 0.1.3, which this repository does not contain. The lockfile (pnpm-lock.yaml) is excluded from review, so the resolved version cannot be confirmed here. Whether 0.1.3 contains the fix is not established by the evidence available. The PR description ("Fixes #2836") and the linked PR #2840 title are claims, not proof of the fix.

Resolution

Provide evidence that @msw/url 0.1.3 changes the trailing-optional and zero-or-more matching behavior described in #2836. Acceptable evidence includes the mswjs/url release notes or diff for 0.1.3, or a test run showing the four matchPattern cases from the issue (/users/:id/:tab? vs /users/1, /:a/:b? vs /x, /users/:id/files/:path* vs /users/1/files, and the /users/:id/:tab?/settings case) and the getResponse cases pass with the bumped version. Adding a regression test in this repository that covers the issue's examples would also establish the behavior.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • 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

A rabbit checks the version line
The URL package moves one sign
From point two to point three
A quiet change in the tree
Then hops away, content and fine

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: bf71c5d6-326b-421e-b0ad-49d4c728b050
Commits

Reviewing files that changed from the base of the PR and between 13fe000 and 40f9a52.

Files ignored due to path filters: 1

  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
Files selected for processing: 1

  • package.json

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

@socket-security

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updated@​msw/​url@​0.1.2 ⏡ 0.1.3100 +1100100 +189 +6100

View full report

@pkg-pr-new

pkg-pr-new Bot commented Nov 17, 2026

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/msw@2840

commit: 40f9a52

@kettanaito
kettanaito merged commit ae1e5b4 into main Nov 17, 2026
12 checks passed
@kettanaito
kettanaito deleted the fix/update-msw-url branch November 17, 2026 16:51
@kettanaito

Copy link
Copy Markdown
Member Author

Released: v3.0.7 πŸŽ‰

This has been released in v3.0.7.

Get these changes by running the following command:

npm i msw@latest

Predictable release automation by Release.

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.

3.0: optional (?) and zero-or-more (*) params after another param don't match when omitted

1 participant