Skip to content

[node][remix][routing-utils] log diff between current and updated versions of path-to-regexp#12926

Merged
EndangeredMassa merged 13 commits intomainfrom
smassa/log-diff-path-to-regexp
Jan 29, 2025
Merged

[node][remix][routing-utils] log diff between current and updated versions of path-to-regexp#12926
EndangeredMassa merged 13 commits intomainfrom
smassa/log-diff-path-to-regexp

Conversation

@EndangeredMassa
Copy link
Copy Markdown
Contributor

@EndangeredMassa EndangeredMassa commented Jan 27, 2025

Using pnpm aliases, this PR installs two different versions of path-to-regexp. Both are run and the resulting regex is compared. If they are different, an innocuous log message is sent to the build logs.

This allows us to test out the new version and be notified of any breaking changes it would have for our users.


Testing: This will be manually tested in the build container before release.

@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Jan 27, 2025

🦋 Changeset detected

Latest commit: d22392b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 10 packages
Name Type
@vercel/node Patch
@vercel/remix-builder Patch
@vercel/routing-utils Patch
vercel Patch
@vercel/client Patch
@vercel/fs-detectors Patch
@vercel/gatsby-plugin-vercel-builder Patch
@vercel/redwood Patch
@vercel/static-build Patch
@vercel-internals/types Patch

Not sure what this means? Click here to learn what changesets are.

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

@EndangeredMassa EndangeredMassa changed the title Smassa/log diff path to regexp [node][remix][routing-utils] log diff between current and updated versions of path-to-regexp Jan 27, 2025
// each of these path-to-regexp comparisons logs an innocuous message
// so we (1) can easily grab it by querying the build logs
// and (2) it doesn't spook the user
console.log(`SYSTEM TEST #${callerId} A: ${path}`);
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Prefix the log with [vc] and it'll be omitted from the user-facing logs entirely (but still be queryable on the backend).

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Also, should we log the before and after regexps?

erikareads
erikareads previously approved these changes Jan 27, 2025
trek
trek previously approved these changes Jan 27, 2025
Copy link
Copy Markdown
Contributor

@trek trek left a comment

Choose a reason for hiding this comment

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

No comments beyond Nate's damn good point.

@EndangeredMassa EndangeredMassa dismissed stale reviews from trek and erikareads via 07983b7 January 27, 2025 21:31
TooTallNate
TooTallNate previously approved these changes Jan 27, 2025
erikareads
erikareads previously approved these changes Jan 27, 2025
@EndangeredMassa
Copy link
Copy Markdown
Contributor Author

That test failure is unrelated and being addressed outside of this PR. I'm going to merge.

@EndangeredMassa EndangeredMassa merged commit 16b38a9 into main Jan 29, 2025
@EndangeredMassa EndangeredMassa deleted the smassa/log-diff-path-to-regexp branch January 29, 2025 16:16
EndangeredMassa pushed a commit that referenced this pull request Jan 29, 2025
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and the packages will
be published to npm automatically. If you're not ready to do a release
yet, that's fine, whenever you add more changesets to main, this PR will
be updated.


# Releases
## [email protected]

### Patch Changes

- Updated dependencies
\[[`16b38a92574695f9961c7cc00cf631fe434c26c8`](16b38a9)]:
    -   @vercel/[email protected]
    -   @vercel/[email protected]
    -   @vercel/[email protected]
    -   @vercel/[email protected]

## @vercel/[email protected]

### Patch Changes

- Updated dependencies
\[[`16b38a92574695f9961c7cc00cf631fe434c26c8`](16b38a9)]:
    -   @vercel/[email protected]

## @vercel/[email protected]

### Patch Changes

- Updated dependencies
\[[`16b38a92574695f9961c7cc00cf631fe434c26c8`](16b38a9)]:
    -   @vercel/[email protected]

## @vercel/[email protected]

### Patch Changes

- Updated dependencies
\[[`16b38a92574695f9961c7cc00cf631fe434c26c8`](16b38a9)]:
    -   @vercel/[email protected]

## @vercel/[email protected]

### Patch Changes

- log diff between current and updated versions of path-to-regexp
([#12926](#12926))

## @vercel/[email protected]

### Patch Changes

- Updated dependencies
\[[`16b38a92574695f9961c7cc00cf631fe434c26c8`](16b38a9)]:
    -   @vercel/[email protected]

## @vercel/[email protected]

### Patch Changes

- log diff between current and updated versions of path-to-regexp
([#12926](#12926))

## @vercel/[email protected]

### Patch Changes

- log diff between current and updated versions of path-to-regexp
([#12926](#12926))

## @vercel/[email protected]

### Patch Changes

-   Updated dependencies \[]:
    -   @vercel/[email protected]

## @vercel-internals/[email protected]

### Patch Changes

- Updated dependencies
\[[`16b38a92574695f9961c7cc00cf631fe434c26c8`](16b38a9)]:
    -   @vercel/[email protected]

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
EndangeredMassa added a commit that referenced this pull request Feb 5, 2025
Updated the `path-to-regexp` comparison:
- centralized logic because it was getting coplicated
- compared `keys` more carefully
- use `keys` in updated `path-to-regexp` function as a clone of the
original to avoid duplicate values

---

Follow-up to: #12926

---------

Co-authored-by: Nathan Rajlich <[email protected]>
QuietCraftsmanship pushed a commit to QuietCraftsmanship/Vercel that referenced this pull request Jul 6, 2025
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and the packages will
be published to npm automatically. If you're not ready to do a release
yet, that's fine, whenever you add more changesets to main, this PR will
be updated.


# Releases
## [email protected]

### Patch Changes

- Updated dependencies
\[[`b13c164e8a62b37d8542a0af3e6c288a1b0c60c6`](vercel/vercel@b13c164)]:
    -   @vercel/[email protected]
    -   @vercel/[email protected]
    -   @vercel/[email protected]
    -   @vercel/[email protected]

## @vercel/[email protected]

### Patch Changes

- Updated dependencies
\[[`b13c164e8a62b37d8542a0af3e6c288a1b0c60c6`](vercel/vercel@b13c164)]:
    -   @vercel/[email protected]

## @vercel/[email protected]

### Patch Changes

- Updated dependencies
\[[`b13c164e8a62b37d8542a0af3e6c288a1b0c60c6`](vercel/vercel@b13c164)]:
    -   @vercel/[email protected]

## @vercel/[email protected]

### Patch Changes

- Updated dependencies
\[[`b13c164e8a62b37d8542a0af3e6c288a1b0c60c6`](vercel/vercel@b13c164)]:
    -   @vercel/[email protected]

## @vercel/[email protected]

### Patch Changes

- log diff between current and updated versions of path-to-regexp
([#12926](vercel/vercel#12926))

## @vercel/[email protected]

### Patch Changes

- Updated dependencies
\[[`b13c164e8a62b37d8542a0af3e6c288a1b0c60c6`](vercel/vercel@b13c164)]:
    -   @vercel/[email protected]

## @vercel/[email protected]

### Patch Changes

- log diff between current and updated versions of path-to-regexp
([#12926](vercel/vercel#12926))

## @vercel/[email protected]

### Patch Changes

- log diff between current and updated versions of path-to-regexp
([#12926](vercel/vercel#12926))

## @vercel/[email protected]

### Patch Changes

-   Updated dependencies \[]:
    -   @vercel/[email protected]

## @vercel-internals/[email protected]

### Patch Changes

- Updated dependencies
\[[`b13c164e8a62b37d8542a0af3e6c288a1b0c60c6`](vercel/vercel@b13c164)]:
    -   @vercel/[email protected]

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
QuietCraftsmanship pushed a commit to QuietCraftsmanship/Vercel that referenced this pull request Jul 6, 2025
Updated the `path-to-regexp` comparison:
- centralized logic because it was getting coplicated
- compared `keys` more carefully
- use `keys` in updated `path-to-regexp` function as a clone of the
original to avoid duplicate values

---

Follow-up to: vercel/vercel#12926

---------

Co-authored-by: Nathan Rajlich <[email protected]>
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.

4 participants