Support sdk_version: "prerelease" sentinel in cog.yaml#2862
Merged
michaeldwan merged 1 commit intomainfrom Mar 24, 2026
Merged
Conversation
Adds a special "prerelease" value for build.sdk_version that generates `uv pip install --pre cog` without a version pin. This lets testers always get the latest pre-release SDK without updating cog.yaml each time a new RC is cut. When stable ships, builds automatically move to stable. A build-time warning nudges users to pin a specific version for production.
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.
Testers using RC builds have to hardcode
sdk_version: "0.17.0rc2"in cog.yaml and bump it every time a new RC drops. That's friction for prerelease testing -- you end up pinging everyone to update their config.This adds
sdk_version: "prerelease"as a special value that generatesuv pip install --pre cogwith no version pin. Testers set it once, and eachcog buildpicks up whatever the latest pre-release is. Once stable ships, builds transparently move to stable (pip prefers stable over RC of the same version). A build-time warning nudges folks to pin a specific version before going to production.Related: #2832 (RC example project that currently hardcodes
0.17.0rc2)