Skip to content

Advance workspace dependency bounds - #336

Open
scotttrinh wants to merge 4 commits into
mainfrom
fix/advance-workspace-upper-bounds
Open

scotttrinh wants to merge 4 commits into
mainfrom
fix/advance-workspace-upper-bounds

Conversation

@scotttrinh

@scotttrinh scotttrinh commented Aug 26, 2026 •

Copy link
Copy Markdown
Collaborator

When a workspace package release reaches a dependent's existing exclusive upper bound, release preparation now advances that bound to the next compatibility boundary in the same generated release PR. This keeps deliberate compatibility bounds such as vercel-internal-core<0.2.0 from producing an uninstallable release when internal core first moves to 0.2.0.

Comment thread scripts/release.py
for item in requirement.specifier
]
marker = f" ; {requirement.marker}" if requirement.marker else ""
updated = f"{requirement.name}{extras}{','.join(specifiers)}{marker}"

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

packaging normalizes the marker to double quotes, producing:

dependencies = ["core>=0.1,<0.3.0 ; python_version < "3.11""]

tomllib.loads() then raises:

TOMLDecodeError: Unclosed array

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

ooof, thanks for catching that. I'm going to add some (failing) e2e tests to replace a bunch of monkeypatched stub-based tests to catch real-world issues like this. Going to push it failing now, and follow-up with the simple fix.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

@elprans ⚡ 1a4c721

Moved a few mock-based unit tests into this fixture test, so take a look there and I'm open to feedback on expanding it further, or ditching this approach and updating some mocks.

Comment thread scripts/release.py
Update existing exclusive upper bounds during release preparation when a planned sibling version reaches them. Leave unbounded dependencies alone and reject ambiguous constraints instead of guessing.
@scotttrinh
scotttrinh force-pushed the fix/advance-workspace-upper-bounds branch from 115c970 to ccbc0d2 Compare September 2, 2026 15:43
h/t @elprans

> packaging normalizes the marker to double quotes, producing:
>
> dependencies = ["core>=0.1,<0.3.0 ; python_version < "3.11""]
>
> tomllib.loads() then raises:
>
> TOMLDecodeError: Unclosed array
@scotttrinh
scotttrinh force-pushed the fix/advance-workspace-upper-bounds branch from c02dbca to 505e914 Compare September 2, 2026 15:48
@scotttrinh
scotttrinh marked this pull request as ready for review September 2, 2026 17:33
@scotttrinh scotttrinh mentioned this pull request Sep 14, 2026

This branch was successfully deployed

1 active deployment
ci — 505e9147 Deployed Sep 2, 2026 by scotttrinh via Test (Windows, py3.12) #1372
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.

2 participants