[python] Support python functions >250mb in size#14976
Merged
Conversation
Signed-off-by: gscho <greg.c.schofield@gmail.com>
…e dep install. Signed-off-by: gscho <greg.c.schofield@gmail.com>
Signed-off-by: gscho <greg.c.schofield@gmail.com>
Signed-off-by: gscho <greg.c.schofield@gmail.com>
🦋 Changeset detectedLatest commit: a3ffb56 The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
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 |
Contributor
📦 CLI Tarball ReadyThe Vercel CLI tarball for this PR is now available! Quick TestYou can test this PR's CLI directly by running: npx https://vercel-8cknxqbt6.vercel.sh/tarballs/vercel.tgz --helpUse in vercel.jsonTo use this CLI version in your project builds, add to your {
"build": {
"env": {
"VERCEL_CLI_VERSION": "vercel@https://vercel-8cknxqbt6.vercel.sh/tarballs/vercel.tgz"
}
}
} |
Contributor
🧪 Unit Test StrategyComparing: Strategy: Code changed outside of a package - running all unit tests Affected packages - 40 (100%)
Results
This comment is automatically generated based on the affected testing strategy |
Signed-off-by: gscho <greg.c.schofield@gmail.com>
Signed-off-by: gscho <greg.c.schofield@gmail.com>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Signed-off-by: gscho <greg.c.schofield@gmail.com>
…thub.com/vercel/vercel into gscho/PY-58-support-large-python-lambdas
Signed-off-by: gscho <greg.c.schofield@gmail.com>
Signed-off-by: gscho <greg.c.schofield@gmail.com>
Signed-off-by: gscho <greg.c.schofield@gmail.com>
Signed-off-by: gscho <greg.c.schofield@gmail.com>
elprans
reviewed
Feb 13, 2026
Co-authored-by: Elvis Pranskevichus <elvis@vercel.com>
…-58-support-large-python-lambdas
Signed-off-by: gscho <greg.c.schofield@gmail.com>
Signed-off-by: gscho <greg.c.schofield@gmail.com>
…thub.com/vercel/vercel into gscho/PY-58-support-large-python-lambdas
elprans
approved these changes
Feb 13, 2026
ricardo-agz
approved these changes
Feb 13, 2026
Signed-off-by: gscho <greg.c.schofield@gmail.com>
…thub.com/vercel/vercel into gscho/PY-58-support-large-python-lambdas
Merged
mehulkar
pushed a commit
that referenced
this pull request
Feb 16, 2026
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 publish to npm yourself or [setup this action to publish automatically](https://github.com/changesets/action#with-publishing). 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@50.18.0 ### Minor Changes - Support easier auth from cursor / claude ([#15050](#15050)) ### Patch Changes - non-interactive mode for link ([#14884](#14884)) - Add experimental manual deployment support ([#14857](#14857)) - Fix `integration remove`, `integration balance`, and `integration open` commands failing to find integrations by explicitly passing `teamId` to the configurations API ([#15054](#15054)) - Require slash syntax for multi-product integrations in non-TTY mode, keep interactive product selector for TTY ([#15047](#15047)) - Move builders back into bundle ([#15059](#15059)) - Updated dependencies \[[`463395162462988e7d3276781d2fdff0685e225b`](4633951), [`6e58410ff849c281735c6acae59b3b0e86136f15`](6e58410)]: - @vercel/go@3.4.1 - @vercel/ruby@2.3.1 - @vercel/python@6.13.0 - @vercel/static-build@2.8.37 ## @vercel/python@6.13.0 ### Minor Changes - Add runtime dependency install to support larger Python functions ([#14976](#14976)) This adds logic to calculate the total size of a lambda at build time and offload dependencies to a \_runtime_requirements.txt file so they can be installed at runtime by uv. This allows us to deploy functions up to the total size of the /tmp folder. ## @vercel/client@17.2.42 ### Patch Changes - Add experimental manual deployment support ([#14857](#14857)) ## @vercel/fs-detectors@5.8.7 ### Patch Changes - [services] infer workspace from manifest: when workspace is not explicitly configured, infer from nearest manifest to entrypoint ([#14986](#14986)) ## @vercel/go@3.4.1 ### Patch Changes - Forward Go and Ruby dev server output through `startDevServer` stdout/stderr callbacks so service logs are correctly prefixed in multi-service `vercel dev`. ([#14989](#14989)) ## @vercel/ruby@2.3.1 ### Patch Changes - Forward Go and Ruby dev server output through `startDevServer` stdout/stderr callbacks so service logs are correctly prefixed in multi-service `vercel dev`. ([#14989](#14989)) ## @vercel/python-runtime@0.4.1 ### Patch Changes - fix PyPI publication integration in release flow ([#15033](#15033)) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
When a Python function is over the 250mb limit for lambda, we package the
uvbinary into the lambda and install the dependencies at runtime.If a package is determined to be "private" it will always be packaged into the lambda zip because we can't install it at runtime.
Enabling the feature
To enable this feature the user must set
VERCEL_EXPERIMENTAL_PYTHON_UV_INSTALL_ON_STARTUP=1in their vercel environment. ALSO in order to increase the ephemeral storage to 10GB you need to setMAXIMISE_TMP_STORAGE=1. This functionality already existed but maybe we can make the builder set that for us somehow.Blast Radius
The blast radius of this PR is small because customer's need to opt-in via environment variable.
Note
Low Risk Change
This PR adds new build-time logic for Python Lambda packaging with runtime dependency installation, gated behind an explicit opt-in environment variable (VERCEL_EXPERIMENTAL_PYTHON_UV_INSTALL_ON_STARTUP), limiting blast radius to users who enable the feature.
Risk assessment for commit a3ffb56.