Commit Graph

1171 Commits

Author SHA1 Message Date
Sean Massa
322c88536d add ruby3 to path during build (#11094)
Add ruby to the path plus some debug code. I'll remove the debug code
after we verify this works.
2024-01-25 14:16:53 -06:00
Nathan Rajlich
30ba68edf9 [cli] Emit "filePathMap" in vc-config.json for FileFsRef instances (#11060)
This is a performance / bandwidth / storage space optimization for the **Build Output API**.

When a Builder returns function which contains a file that is a `FileFsRef` instance, it _won't_ be copied into the corresponding `.func` directory, but instead will be added to a `"files"` mapping in the `.vc-config.json` file. This mapping represents keys which are destination file paths within the function filesystem, and values which are relative paths from the root of the project codebase. This allows for common files (i.e. `node_modules`) to be referenced (instead of physically copied on the disk).

This introduces an additional complexity to `vc deploy --prebuilt`, in such that now it needs to build up the list of `"files"` referenced from the `.vc-config.json` files, and _also_ upload those file paths along with the `.vercel/output` directory.

Depends on:

* https://github.com/vercel/vercel/pull/11077
* https://github.com/vercel/vercel/pull/11080
2024-01-23 20:54:34 +00:00
Nathan Rajlich
62ca2efa73 [python][ruby][cli] Remove deprecated createLambda() usage (#11080)
* Use `Lambda` constructor instead of `createLambda()`
* Return `FileBlob` instance for the entrypoint files, so that they do not get written to cwd
* In `vc dev`, support `Lambda` instances which do not have `zipBuffer` property
2024-01-23 19:53:36 +00:00
Vercel Release Bot
acb2acf953 Version Packages (#11034)
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
## vercel@33.2.0

### Minor Changes

-   chore: deprecate next/nuxt/gastby Speed Insights injection in favor of @vercel/speed-insights ([#11048](https://github.com/vercel/vercel/pull/11048))

### Patch Changes

-   fix error when @vercel/analytics is a transitive dependency of the deployed application ([#10892](https://github.com/vercel/vercel/pull/10892))

-   [cli] Add documentation string for `skip-domain` option ([#11051](https://github.com/vercel/vercel/pull/11051))

-   Updated dependencies \[[`260125784`](2601257846), [`cdddb33ad`](cdddb33ad4), [`72d8604c9`](72d8604c9d), [`90d0455e1`](90d0455e1f), [`0716130e5`](0716130e58), [`b6b151f39`](b6b151f391), [`b185a7e20`](b185a7e207)]:
    -   @vercel/static-build@2.1.0
    -   @vercel/build-utils@7.5.1
    -   @vercel/next@4.1.0
    -   @vercel/remix-builder@2.0.18
    -   @vercel/node@3.0.17

## @vercel/next@4.1.0

### Minor Changes

-   fix error when @vercel/analytics is a transitive dependency of the deployed application ([#10892](https://github.com/vercel/vercel/pull/10892))

### Patch Changes

-   Use `worker.name` instead of edge function name to fix type error in `@vercel/next` ([#11050](https://github.com/vercel/vercel/pull/11050))

## @vercel/static-build@2.1.0

### Minor Changes

-   chore: deprecate next/nuxt/gastby Speed Insights injection in favor of @vercel/speed-insights ([#11048](https://github.com/vercel/vercel/pull/11048))

### Patch Changes

-   Updated dependencies \[]:
    -   @vercel/gatsby-plugin-vercel-builder@2.0.16

## @vercel/build-utils@7.5.1

### Patch Changes

-   Add experimental field to Lambda and size to FileFsRef output ([#11059](https://github.com/vercel/vercel/pull/11059))

## @vercel/client@13.0.14

### Patch Changes

-   Updated dependencies \[[`cdddb33ad`](cdddb33ad4)]:
    -   @vercel/build-utils@7.5.1

## @vercel/gatsby-plugin-vercel-builder@2.0.16

### Patch Changes

-   Updated dependencies \[[`cdddb33ad`](cdddb33ad4)]:
    -   @vercel/build-utils@7.5.1

## @vercel/node@3.0.17

### Patch Changes

-   Updated dependencies \[[`cdddb33ad`](cdddb33ad4)]:
    -   @vercel/build-utils@7.5.1

## @vercel/remix-builder@2.0.18

### Patch Changes

-   Fix functions without a output path edge case ([#11038](https://github.com/vercel/vercel/pull/11038))

-   Update `@remix-run/dev` fork to v2.5.0 ([#11054](https://github.com/vercel/vercel/pull/11054))

-   Update `@remix-run/dev` fork to v2.5.1 ([#11065](https://github.com/vercel/vercel/pull/11065))

## @vercel-internals/types@1.0.21

### Patch Changes

-   Updated dependencies \[[`cdddb33ad`](cdddb33ad4)]:
    -   @vercel/build-utils@7.5.1
2024-01-19 22:07:42 +00:00
Damien Simonin Feugas
2601257846 [cli, static-builds] deprecation notice for speed insights injection (#11048)
### 🧐 What's in there?

With the recent release of [`@vercel/speed-insights`](https://vercel.com/docs/speed-insights/package) own package (like [`@vercel/analytics`](https://vercel.com/docs/analytics/package)), it's time to encourage users to migrate.

With the availability of `@vercel/speed-insights`, users will have to opt-in explicitly by installing the package. Their benefit is a better and fine-grained control of the reporting (in particular, per-application sample rate).

###  Note to reviewers

I used `console.warn` and hope it will stands out in the build logs. I'm happy to use anything else if you have better suggestions.

There's also a deprecation warning in Next.js, which covers a related but slightly different case, when users explicitly pass analyticsId in their configuration. https://github.com/vercel/next.js/pull/60677
2024-01-19 19:10:31 +00:00
Trek Glowacki
7de754398e [cli] Add documentation string for skip-domain option (#11051)
Text taken directly from https://vercel.com/docs/cli/deploy#skip-domain
2024-01-18 18:10:22 +00:00
Damien Simonin Feugas
72d8604c9d [cli] fix error when @vercel/analytics is a transitive dependency of the deployed application (#10892) 2024-01-11 15:48:20 +01:00
Vercel Release Bot
5fe7b57b8d Version Packages (#11015)
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
## @vercel/build-utils@7.5.0

### Minor Changes

- Deprecate `EdgeFunction#name` property
([#11010](https://github.com/vercel/vercel/pull/11010))

## vercel@33.1.0

### Minor Changes

- Serialize duplicate `EdgeFunction` references as symlinks in `vc
build` ([#11027](https://github.com/vercel/vercel/pull/11027))

### Patch Changes

- Handle rate limit response when fetching /teams
([#11013](https://github.com/vercel/vercel/pull/11013))

- Display actual deployment's 'target'
([#11025](https://github.com/vercel/vercel/pull/11025))

- Updated dependencies
\[[`98040ec24`](98040ec24e)]:
    -   @vercel/build-utils@7.5.0
    -   @vercel/static-build@2.0.17
    -   @vercel/hydrogen@1.0.2
    -   @vercel/remix-builder@2.0.17
    -   @vercel/node@3.0.16

## @vercel/client@13.0.13

### Patch Changes

- Updated dependencies
\[[`98040ec24`](98040ec24e)]:
    -   @vercel/build-utils@7.5.0

## @vercel/gatsby-plugin-vercel-builder@2.0.15

### Patch Changes

- Updated dependencies
\[[`98040ec24`](98040ec24e)]:
    -   @vercel/build-utils@7.5.0

## @vercel/hydrogen@1.0.2

### Patch Changes

- Deprecate `EdgeFunction#name` property
([#11010](https://github.com/vercel/vercel/pull/11010))

## @vercel/node@3.0.16

### Patch Changes

- Deprecate `EdgeFunction#name` property
([#11010](https://github.com/vercel/vercel/pull/11010))

- Updated dependencies
\[[`98040ec24`](98040ec24e)]:
    -   @vercel/build-utils@7.5.0

## @vercel/remix-builder@2.0.17

### Patch Changes

- Deprecate `EdgeFunction#name` property
([#11010](https://github.com/vercel/vercel/pull/11010))

## @vercel/static-build@2.0.17

### Patch Changes

- Deprecate `EdgeFunction#name` property
([#11010](https://github.com/vercel/vercel/pull/11010))

-   Updated dependencies \[]:
    -   @vercel/gatsby-plugin-vercel-builder@2.0.15

## @vercel-internals/types@1.0.20

### Patch Changes

- Updated dependencies
\[[`98040ec24`](98040ec24e)]:
    -   @vercel/build-utils@7.5.0

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-10 15:51:08 -06:00
Nathan Rajlich
ab826eb83d [cli] Serialize duplicate EdgeFunction references as symlinks in vc build (#11027)
Enables the symlink optimization that currently exists for `Lambda`
instances, but now for `EdgeFunction` instances as well. This will be
particularly beneficial for Remix applications which use edge functions
for many routes, since they will now all be represented by the same
underling function in production.

---------

Co-authored-by: Sean Massa <EndangeredMassa@gmail.com>
2024-01-10 13:17:59 -08:00
Chris Barber
21c700aa93 [cli] Display actual deployment's 'target' (#11025)
The CLI renders the deploy URL with the "Preview" label on first deploy because the CLI treats deploys as previews unless `--prod` is set. However the first deploy for a new project is always production, so the CLI needs to render the deploy URL based on the actual deployment's `target`.
2024-01-10 14:05:52 +00:00
Trek Glowacki
597508ffa6 [cli] handle rate limit respones when fetching /teams endpoint (#11013)
Not the biggest fan of handling this here but of all the various location we do response handling, this seems to be the appropriate location.
2024-01-04 15:04:54 +00:00
Vercel Release Bot
83952e45c2 Version Packages (#10982)
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
## vercel@33.0.2

### Patch Changes

-   Log extension execution failures ([#10937](https://github.com/vercel/vercel/pull/10937))

-   Updated dependencies \[[`fbe08fe57`](fbe08fe57e), [`77585013d`](77585013de), [`c536a74bc`](c536a74bc9), [`91f8763ed`](91f8763edc), [`7f8f5f865`](7f8f5f8651)]:
    -   @vercel/next@4.0.17
    -   @vercel/go@3.0.5
    -   @vercel/node@3.0.15
    -   @vercel/redwood@2.0.6
    -   @vercel/remix-builder@2.0.16

## @vercel/go@3.0.5

### Patch Changes

-   Remove `VERCEL_USE_GO_PROVIDED_RUNTIME` env var check ([#10968](https://github.com/vercel/vercel/pull/10968))

## @vercel/next@4.0.17

### Patch Changes

-   Ensure rewrites handle RSC requests ([#11005](https://github.com/vercel/vercel/pull/11005))

-   [next][node][redwood][remix] Bump `@vercel/nft@0.26.1` ([#11009](https://github.com/vercel/vercel/pull/11009))

## @vercel/node@3.0.15

### Patch Changes

-   Await waitUntil promises to resolve before exiting ([#10915](https://github.com/vercel/vercel/pull/10915))

-   [next][node][redwood][remix] Bump `@vercel/nft@0.26.1` ([#11009](https://github.com/vercel/vercel/pull/11009))

## @vercel/redwood@2.0.6

### Patch Changes

-   [next][node][redwood][remix] Bump `@vercel/nft@0.26.1` ([#11009](https://github.com/vercel/vercel/pull/11009))

## @vercel/remix-builder@2.0.16

### Patch Changes

-   [next][node][redwood][remix] Bump `@vercel/nft@0.26.1` ([#11009](https://github.com/vercel/vercel/pull/11009))

-   Update `@remix-run/dev` fork to v2.4.1 ([#10992](https://github.com/vercel/vercel/pull/10992))
2024-01-03 22:20:58 +00:00
Brody McKee
b1e0523e71 [cli] log extension execution failures (#10937)
Co-authored-by: Nathan Rajlich <n@n8.io>
2024-01-03 16:05:18 +11:00
Seiya Nuta
c536a74bc9 [node] Await waitUntil promises to resolve before exiting (#10915)
Say you have a middleware (`middleware.js`) that looks like this:

```js
export async default function middleware(req, ctx) {
  ctx.waitUntil(tooLongFunction())
}

async function tooLongFunction() {
  console.log('tooLongFunction started')
  await new Promise((resolve) => setTimeout(resolve, 10000))
  console.log('tooLongFunction finished')
}
```

When you run this middleware locally with `vercel dev`, you won't see the `tooLongFunction finished` message because the server process is killed right after finishing the response. While Edge Runtime's `server.close()`, which awaits all `waitUntil` promises, is called, but `exit-hook`'s callback in CLI doesn't wait for the `close` promise to resolve.

This PR fixes this by allowing an optional graceful shutdown callback instead of killing the process immediately.
2023-12-21 10:11:34 +00:00
Vercel Release Bot
6194e8ca8d Version Packages (#10971)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-12-20 08:34:34 -06:00
Vercel Release Bot
b67b97023b Version Packages (#10944)
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
## vercel@33.0.0

### Major Changes

- [cli] replace `--deprecated` with `--update-required` in `vc project
ls` ([#10965](https://github.com/vercel/vercel/pull/10965))

### Patch Changes

- Fix `vercel bisect` selecting too many deployments
([#10956](https://github.com/vercel/vercel/pull/10956))

- Updated dependencies
\[[`6a9002f22`](6a9002f229),
[`4d63d9e95`](4d63d9e954)]:
    -   @vercel/remix-builder@2.0.15
    -   @vercel/build-utils@7.4.0
    -   @vercel/static-build@2.0.15
    -   @vercel/node@3.0.13

## @vercel/build-utils@7.4.0

### Minor Changes

- Adds new helper `getPathForPackageManager()`
([#10918](https://github.com/vercel/vercel/pull/10918))

## @vercel/client@13.0.11

### Patch Changes

- Updated dependencies
\[[`4d63d9e95`](4d63d9e954)]:
    -   @vercel/build-utils@7.4.0

## @vercel/gatsby-plugin-vercel-builder@2.0.13

### Patch Changes

- Add support for "rewrites"
([#10954](https://github.com/vercel/vercel/pull/10954))

- Updated dependencies
\[[`4d63d9e95`](4d63d9e954)]:
    -   @vercel/build-utils@7.4.0

## @vercel/node@3.0.13

### Patch Changes

- Updated dependencies
\[[`4d63d9e95`](4d63d9e954)]:
    -   @vercel/build-utils@7.4.0

## @vercel/remix-builder@2.0.15

### Patch Changes

- Update `@remix-run/dev` fork to v2.4.0
([#10943](https://github.com/vercel/vercel/pull/10943))

## @vercel/static-build@2.0.15

### Patch Changes

- Updated dependencies
\[[`652a31275`](652a312753)]:
    -   @vercel/gatsby-plugin-vercel-builder@2.0.13

## @vercel-internals/types@1.0.18

### Patch Changes

- Updated dependencies
\[[`4d63d9e95`](4d63d9e954)]:
    -   @vercel/build-utils@7.4.0

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-12-18 12:25:56 -07:00
Ethan Arrowood
9146885f80 [cli] replace --deprecated with --update-required in vc project ls (#10965)
Replaces the new `--deprecated` option with `--update-required` in the `vc project ls` command.
2023-12-18 19:10:07 +00:00
Mitch (a.k.a Voz)
98bc41d49a fix: Doc links in auth files (#10955)
Fixed the links in the auth files to reflect what the doc links currently are.
2023-12-18 16:59:19 +00:00
Nathan Rajlich
5d521af586 [cli] Fix vc bisect selecting too many deployments (#10956) 2023-12-15 00:17:29 -08:00
Vercel Release Bot
2829d541b8 Version Packages (#10939) 2023-12-13 07:46:11 -07:00
Ethan Arrowood
6880dcb3c3 [cli] Use new deprecated query param in projects api for vc project ls --deprecated (#10938)
Uses the new `deprecated` query param for the GET /projects API instead of client-side filtering.

This enables a better UX so that results are properly paginated. 

Here are some example runs:

Pagination works as expected:
<img width="831" alt="Screenshot 2023-12-12 at 20 59 57" src="https://github.com/vercel/vercel/assets/16144158/c592752d-bf49-41a0-8dae-8b8e233052f8">

Usage without the flag results in different output (as expected!)
<img width="830" alt="Screenshot 2023-12-12 at 21 04 52" src="https://github.com/vercel/vercel/assets/16144158/c65461e0-b4a0-4725-aaae-a63739e6c8e9">
2023-12-13 07:22:10 +00:00
Vercel Release Bot
9a250d528c Version Packages (#10935)
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
## vercel@32.7.1

### Patch Changes

- [cli] double page limit for vc project ls --deprecated
([#10932](https://github.com/vercel/vercel/pull/10932))

- Updated dependencies
\[[`d09dd1794`](d09dd1794b)]:
    -   @vercel/remix-builder@2.0.14

## @vercel/remix-builder@2.0.14

### Patch Changes

- Reinstall dependencies during `prepareCache()`
([#10922](https://github.com/vercel/vercel/pull/10922))

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-12-12 10:31:23 -07:00
Ethan Arrowood
f80a59c73f [cli] double page limit for vc project ls --deprecated (#10932)
As titled. Increases api page size for `vc project ls` when
`--deprecated` is used.

This is a temporary workaround since we do the filtering "client-side".
We will eventually update the API itself to support this and then we can
remove the client-based filter and reduce the page limit back to the
ideal `20`.

---------

Co-authored-by: Sean Massa <EndangeredMassa@gmail.com>
2023-12-12 08:27:25 -07:00
Vercel Release Bot
7582571d94 Version Packages (#10913)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-12-11 10:39:34 -06:00
Ethan Arrowood
a1df25a197 [cli] Clean up project ls --deprecate (#10926)
Follow up to #10919

Removes console.log statements and changes log into warning.
2023-12-08 17:55:24 +00:00
Ethan Arrowood
dfe47f6e6c [cli] add --deprecated option to vc project ls command (#10919)
Adds a `--deprecated` option to the `vc project ls` command that will only show projects currently running on a soon-to-be-deprecated Node.js version.

It also adds additional output providing more information to the user about what versions and a link to our documentation so they can learn more.

Example:

<img width="836" alt="Screenshot 2023-12-07 at 15 01 22" src="https://github.com/vercel/vercel/assets/16144158/3b7f7b13-802e-4af1-a76e-a158a477beb4">
2023-12-08 17:09:18 +00:00
Vercel Release Bot
371c7a08f2 Version Packages (#10896) 2023-12-01 11:43:49 -08:00
Nathan Rajlich
0fe8c07194 [cli] Revert "forbids globally installed @vercel/speed-insights and @vercel/analytics (#10848)" (#10895)
This reverts commit 6afdd7fb0b.
2023-12-01 19:35:04 +00:00
Vercel Release Bot
78d1d548d9 Version Packages (#10865) 2023-11-30 11:01:27 -08:00
Trek Glowacki
c41ff450c0 [cli] Fix behavior for combination of northstar user + team scope provided to cli as an argument. (#10884)
Fixes a neat little bug with the intersection of northstar users, teams, and the behavior of `Array#find_index`:

When selecting an org for various cli actions _non_ northstar users will see a select list with their user in the 0th position, and their teams in the 1..nth positions, like so:

```
// user: Logan
// teams: [Avengers, X-Men]
○ Logan
○ Avengers
○ X-Men
``` 

We'd like to preselect either a team referenced in `client.config.currentTeam` or if said team cannot be found in the collection of a user's teams, preselect the user. So if `X-Men` is `currentTeam`, we find that item (element `1` in the teams array) and increment that value by `1` to account for the user being element `0` in the list of choices:

```
// currentTeam: X-Men
// user: Logan
// teams: [Avengers, X-Men]
○ Logan
○ Avengers
● X-Men
``` 

If we _can't_ find the `currentTeam` in the list of teams (or one isn't provided), `Array#find_index` returns `-1`, which we increment to by `1` to get the 0th element in the list of choices:

```
// currentTeam: undefined
// user: Logan
// teams: [Avengers, X-Men]
● Logan
○ Avengers
○ X-Men
``` 

Neat trick!

However, Northstar users _don't_ use the user account as the 0th element in the list of choices. Northstar users will in fact have a team that represents a hidden default team with the same name as their `user.name` and this will be the 0th element in their teams:

```
// user: Logan
// teams: [Logan, Avengers, X-Men]
○ Logan
○ Avengers
○ X-Men
``` 

This of course means the trick of `+1` to index of the team selects the wrong item _and_ can result in `undefined` in cases where the `currentTeam` references the last team.

```
// currentTeam: X-Men
// user: Logan
// teams: [Logan, Avengers, X-Men]
○ Logan
○ Avengers
○ X-Men
``` 

● how'd we get out here?!?! 👀 

To address the issue this PR:
1. calls `findIndex` on the array of _choices_ checking for matches to `currentTeam`
2. wraps that in `Math.max` to set to `0` if `find_index` returns `-1` when a `currentTeam` can't be found.
2023-11-29 14:15:17 +00:00
Trek Glowacki
2d86a2d4ba [tests] tidy and make select-org tests more realistic (#10882)
Tracking down a bug with "northstar" users and have a little prefactor that 

a) isolates setup code so it's less repeated
b) makes the "northstar" tests more reflective of actual execution.

Northstar users will always have a `currentTeam` value on their `client.config`:

aa0f3d712b/packages/cli/src/util/get-scope.ts (L18-L20)

And finally c) add tests for the case of a non-northstar users where a team scope is supplied.

The final hypothetical matching group (northstart users with team scope provided) is the bug that I'll fix with a refactor.
2023-11-28 23:21:32 +00:00
Damien Simonin Feugas
6afdd7fb0b [cli] forbids globally installed @vercel/speed-insights and @vercel/analytics (#10848) 2023-11-22 09:29:40 +01:00
Vercel Release Bot
fdef0339f2 Version Packages (#10861) 2023-11-21 13:59:05 -08:00
Zack Tanner
611fbdd5ac Revert "[cli][tests] Work around Yarn + Corepack issue in tests" (#10860) 2023-11-21 10:21:56 -06:00
Nathan Rajlich
8feaa9c3b3 [cli][tests] Work around Yarn + Corepack issue in tests (#10858)
CI started failing on corepack related tests with error:

```
error This project's package.json defines "packageManager": "yarn@npm@8.1.0". However the current global version of Yarn is 1.22.21.
```

This appears to be a bug in the Yarn v1.22.21, which was released a week ago: https://github.com/yarnpkg/yarn/releases/tag/v1.22.21

Setting the `SKIP_YARN_COREPACK_CHECK` env var disables this new check which fixes the issue for us.

**NOTE:** Review with [whitespace changes disabled](https://github.com/vercel/vercel/pull/10858/files?w=1) for an easier view.
2023-11-20 21:47:39 +00:00
Vercel Release Bot
6f3ae1a0ed Version Packages (#10836)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-15 23:19:35 -06:00
Vercel Release Bot
7bc8b65d13 Version Packages (#10832)
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
## @vercel/build-utils@7.2.4

### Patch Changes

-   Select Node.js version based on what's available in build-container ([#10822](https://github.com/vercel/vercel/pull/10822))

## vercel@32.5.4

### Patch Changes

-   Updated dependencies \[[`65dec5b7e`](65dec5b7e7)]:
    -   @vercel/build-utils@7.2.4
    -   @vercel/node@3.0.10
    -   @vercel/static-build@2.0.11

## @vercel/client@13.0.8

### Patch Changes

-   Updated dependencies \[[`65dec5b7e`](65dec5b7e7)]:
    -   @vercel/build-utils@7.2.4

## @vercel/gatsby-plugin-vercel-builder@2.0.10

### Patch Changes

-   Updated dependencies \[[`65dec5b7e`](65dec5b7e7)]:
    -   @vercel/build-utils@7.2.4

## @vercel/node@3.0.10

### Patch Changes

-   Updated dependencies \[[`65dec5b7e`](65dec5b7e7)]:
    -   @vercel/build-utils@7.2.4

## @vercel/static-build@2.0.11

### Patch Changes

-   Updated dependencies \[]:
    -   @vercel/gatsby-plugin-vercel-builder@2.0.10

## @vercel-internals/types@1.0.15

### Patch Changes

-   Updated dependencies \[[`65dec5b7e`](65dec5b7e7)]:
    -   @vercel/build-utils@7.2.4
2023-11-15 00:45:19 +00:00
Vercel Release Bot
493185709a Version Packages (#10809)
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
## vercel@32.5.3

### Patch Changes

- Handle `TooManyProjects` error in places where projects are created
([#10807](https://github.com/vercel/vercel/pull/10807))

- Updated dependencies
\[[`89c1e0323`](89c1e03233),
[`fd29b966d`](fd29b966d3)]:
    -   @vercel/node@3.0.9
    -   @vercel/next@4.0.14

## @vercel/next@4.0.14

### Patch Changes

- Fixed headers for static routes when PPR is enabled
([#10808](https://github.com/vercel/vercel/pull/10808))

## @vercel/node@3.0.9

### Patch Changes

- Replace usage of `fetch` with `undici.request`
([#10767](https://github.com/vercel/vercel/pull/10767))

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-08 10:36:37 -07:00
Zach Ward
ebd7e3ac39 Project limits error handling (#10807)
This PR adds improved error handling for the 200 project limit error
that will start being returned for free tier teams/accounts. The
following changes have been made:
- improve error message format by using `client.output.prettyError` so
that the docs link
(https://vercel.com/docs/limits/overview#general-limits) returned with
the error response is included with the error message
- add explicit error handling of this error from any places where
`createProject` is called, which includes the following commands:
  - `vc project add`
  - `vc link` (indirectly called via `ensureLink`)
  - `vc list` (indirectly called via `ensureLink`)
  - `vc git connect` (indirectly called via `ensureLink`)

### Testing
- sign in to a vercel account that is associated with your work email
(ends in `@vercel.com`), this is necessary for creating a team with the
proper conditions to artificially trigger the error message
- create a Pro Trial team and make sure to prefix the name with:
`vtest314 too many projects `, for example `vtest314 too many projects
test 1`
- check out this branch and cd to `vercel/vercel/packages/cli`
- run: `pnpm dev add [project-name] --cwd=/path/to/some/project`
- the project should fail to be created and you should see the expected
error message (screenshot below) in the terminal output

**Screenshot of error message when attempting to add project from cli**
<img width="798" alt="image"
src="https://github.com/vercel/vercel/assets/14896430/43e6ac2c-ae1c-4367-8d57-0aeb7fbddf33">

---------

Co-authored-by: Nathan Rajlich <n@n8.io>
2023-11-08 11:48:12 -05:00
Vercel Release Bot
2bd9216403 Version Packages (#10805)
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
## vercel@32.5.2

### Patch Changes

- Updated dependencies
\[[`c94a082f6`](c94a082f6b)]:
    -   @vercel/next@4.0.13

## @vercel/next@4.0.13

### Patch Changes

- Added `getRequestHandlerWithMetadata` export
([#10753](https://github.com/vercel/vercel/pull/10753))

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-07 12:20:58 -07:00
Vercel Release Bot
66cd626d1c Version Packages (#10765)
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
## @vercel/build-utils@7.2.3

### Patch Changes

- Add experimental flag to allow Node.js v20
([#10802](https://github.com/vercel/vercel/pull/10802))

## vercel@32.5.1

### Patch Changes

- Debug log load user exceptions
([#10773](https://github.com/vercel/vercel/pull/10773))

- bump: edge-runtime
([#10712](https://github.com/vercel/vercel/pull/10712))

- Updated dependencies
\[[`fc90a3dc0`](fc90a3dc0b),
[`644b8a52c`](644b8a52cb),
[`0861dc8fb`](0861dc8fbc),
[`33cc8e0ac`](33cc8e0acf),
[`f5296c3c0`](f5296c3c06),
[`d9065c210`](d9065c2102)]:
    -   @vercel/next@4.0.12
    -   @vercel/node@3.0.8
    -   @vercel/build-utils@7.2.3
    -   @vercel/remix-builder@2.0.11
    -   @vercel/static-build@2.0.10

## @vercel/client@13.0.7

### Patch Changes

- Updated dependencies
\[[`0861dc8fb`](0861dc8fbc)]:
    -   @vercel/build-utils@7.2.3

## @vercel/edge@1.1.1

### Patch Changes

- bump: edge-runtime
([#10712](https://github.com/vercel/vercel/pull/10712))

## @vercel/error-utils@2.0.2

### Patch Changes

- use Node.js `util.types.isNativeError` for `isError` method
([#10764](https://github.com/vercel/vercel/pull/10764))

## @vercel/frameworks@2.0.3

### Patch Changes

- update Angular output path discovery
([#10678](https://github.com/vercel/vercel/pull/10678))

- Updated dependencies
\[[`34dd9c091`](34dd9c0918)]:
    -   @vercel/error-utils@2.0.2

## @vercel/fs-detectors@5.1.3

### Patch Changes

- Updated dependencies
\[[`306f653da`](306f653da9),
[`34dd9c091`](34dd9c0918)]:
    -   @vercel/frameworks@2.0.3
    -   @vercel/error-utils@2.0.2

## @vercel/gatsby-plugin-vercel-builder@2.0.9

### Patch Changes

- Fix nested SSR routes
([#10751](https://github.com/vercel/vercel/pull/10751))

- Updated dependencies
\[[`0861dc8fb`](0861dc8fbc)]:
    -   @vercel/build-utils@7.2.3

## @vercel/next@4.0.12

### Patch Changes

- fix re-mapping logic for index prefetches
([#10750](https://github.com/vercel/vercel/pull/10750))

- Fixes a case where using `basePath` along with static generation would
output a lambda that conflicts with the root route.
([#10738](https://github.com/vercel/vercel/pull/10738))

- Rework prefetch route handling
([#10779](https://github.com/vercel/vercel/pull/10779))

## @vercel/node@3.0.8

### Patch Changes

- bump: edge-runtime
([#10712](https://github.com/vercel/vercel/pull/10712))

- Updated dependencies
\[[`0861dc8fb`](0861dc8fbc),
[`34dd9c091`](34dd9c0918)]:
    -   @vercel/build-utils@7.2.3
    -   @vercel/error-utils@2.0.2

## @vercel/remix-builder@2.0.11

### Patch Changes

- Update `@remix-run/dev` fork to v2.2.0
([#10788](https://github.com/vercel/vercel/pull/10788))

## @vercel/static-build@2.0.10

### Patch Changes

- Updated dependencies
\[[`efd3cc05d`](efd3cc05dc)]:
    -   @vercel/gatsby-plugin-vercel-builder@2.0.9

## @vercel-internals/types@1.0.14

### Patch Changes

- Updated dependencies
\[[`0861dc8fb`](0861dc8fbc)]:
    -   @vercel/build-utils@7.2.3

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-07 10:51:39 -07:00
JJ Kasper
7b553c7032 Disable deployment SSO protection for tests (#10799)
Our tests rely on not being behind deployment protection which is now enabled by default so this adds a step to tests to disable this setting to allow tests to continue working as expected.
2023-11-07 05:04:29 +00:00
Kiko Beats
644b8a52cb bump: edge-runtime (#10712) 2023-11-06 09:58:22 +01:00
Chris Barber
9e2120a325 [cli] Debug log load user exceptions (#10773)
When `getUser(client)` throws an exception, the actual error is never printed. This is useful information, so we should write it to the debug log output.
2023-10-26 16:12:16 +00:00
Trek Glowacki
429a111b50 [tests] Add package-lock.json file to dev-server-and-routes vc dev fixture (#10771) 2023-10-26 10:30:56 -05:00
Trek Glowacki
431dde5fa8 [tests] Migrate docusaurus vc dev test to package-lock.json file (#10769) 2023-10-25 09:19:23 -05:00
Vercel Release Bot
7504bfbe26 Version Packages (#10668)
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
## vercel@32.5.0

### Minor Changes

-   Indicates whether @vercel/speed-insights or @vercel/analytics are used ([#10623](https://github.com/vercel/vercel/pull/10623))

-   [cli] update env var validation rule to allow name start with underscore ([#10697](https://github.com/vercel/vercel/pull/10697))

### Patch Changes

-   Updated dependencies \[[`da300030c`](da300030c9), [`de84743e1`](de84743e10), [`913608de4`](913608de4d), [`7fa08088e`](7fa08088ea)]:
    -   @vercel/next@4.0.11
    -   @vercel/python@4.1.0
    -   @vercel/remix-builder@2.0.10
    -   @vercel/redwood@2.0.5
    -   @vercel/static-build@2.0.9

## @vercel/python@4.1.0

### Minor Changes

-   Add support for pip3.10 and pip3.11 ([#10648](https://github.com/vercel/vercel/pull/10648))

## @vercel/routing-utils@3.1.0

### Minor Changes

-   Adds support for statusCode property on rewrites ([#10495](https://github.com/vercel/vercel/pull/10495))

## @vercel/client@13.0.6

### Patch Changes

-   Updated dependencies \[[`9e9fac019`](9e9fac0191)]:
    -   @vercel/routing-utils@3.1.0

## @vercel/fs-detectors@5.1.2

### Patch Changes

-   Updated dependencies \[[`9e9fac019`](9e9fac0191)]:
    -   @vercel/routing-utils@3.1.0

## @vercel/gatsby-plugin-vercel-builder@2.0.8

### Patch Changes

-   Updated dependencies \[[`9e9fac019`](9e9fac0191)]:
    -   @vercel/routing-utils@3.1.0

## @vercel/next@4.0.11

### Patch Changes

-   fix `build` in appDir on Windows ([#10708](https://github.com/vercel/vercel/pull/10708))

-   Fix RSC prefetch for index route with catch-all ([#10734](https://github.com/vercel/vercel/pull/10734))

## @vercel/redwood@2.0.5

### Patch Changes

-   Updated dependencies \[[`9e9fac019`](9e9fac0191)]:
    -   @vercel/routing-utils@3.1.0

## @vercel/remix-builder@2.0.10

### Patch Changes

-   Update `@remix-run/dev` fork to v2.1.0 ([#10732](https://github.com/vercel/vercel/pull/10732))

## @vercel/static-build@2.0.9

### Patch Changes

-   Updated dependencies \[]:
    -   @vercel/gatsby-plugin-vercel-builder@2.0.8

## @vercel-internals/types@1.0.13

### Patch Changes

-   Updated dependencies \[[`9e9fac019`](9e9fac0191)]:
    -   @vercel/routing-utils@3.1.0
2023-10-20 18:51:02 +00:00
Chris Barber
5e6ef3d569 Enable source maps in tests (#10725)
The `tsconfig` files were unified with a common configuration in https://github.com/vercel/vercel/pull/10667 including disabling source maps. The source maps greatly increase the distribution size, but they are invaluable when the tests run, so this PR enables source maps for tests including adding a `tsconfig.json` where absent.

Linear: https://linear.app/vercel/issue/ZERO-364/enable-sourcemaps-in-all-testtsconfigjson-files
2023-10-17 15:15:29 +00:00
Trek Glowacki
ed19b26603 [cli] Migrate 30-next-image-optimization fixture to use npm install (#10720) 2023-10-16 13:55:43 -05:00
Trek Glowacki
9c4589ed28 [cli] autoconfirm in CI to domain buys (#10703)
The `try to purchase a domain` CLI test starting failing on  11 October when the API became slightly slower to respond. This is because `vercel domains buy example.com` displays a prompt asking the user to `y` into agreeing to the purchase. We interacted with this in tests by spamming `y` on STDIN for a few seconds. The timing required is now a bit longer but I think we can skip that pattern entirely by passing the `--yes` option to the subcommand.

I don't _think_ we want this anywhere but in CI and let people unintentionally buy domains , so I've gated the use based on that, but happy to make it available always.

Ironically this issue went away on 13 October when the API response times improved and we could just unskip the test https://github.com/vercel/vercel/pull/10707
2023-10-16 17:33:13 +00:00