Use standardizedVersioning from vscode-engineering for pre-release version numbers#1441
Conversation
|
|
There seems to be test failures. But I can do the run for you if you need |
The test failures should be fixed after #1442 is checked in. Sure it would be great if you could run the pre-release pipeline on this branch with |
|
This branch is in your fork. Can you push a copy to the origin? I just gave you write access. |
|
Sure, you should be able to run pipeline from https://github.com/microsoft/vscode-python-environments/tree/version |
|
Sounds good, can you actually run the pipeline again for me? I installed the vsix from build artifacts, was trying to do some manual testing to make sure the vsix is built properly with the changes, but was seeing the same issue as Fix refresh failure caused by JSON-RPC sending [null] params to pet binary, so just rebased against |

Summary
This PR stops
update_ext_version.pyfrom overriding the pre-release version number and instead lets thevscode-engineeringshared pipeline template handle it via thestandardizedVersioningflag (which was already enabled but being overriden).Why change the versioning?
Problem 1: Poor readability
The old pre-release version format was
1.27.10931010, computed as1+ Julian day (093) + hour (10) + minute (10). Looking at1.27.10931010, there's no easy way to tell when it was built. You'd have to reverse-engineer the Julian day and time to figure out it means "April 3, 10:10 AM UTC".Problem 2: Different platforms got different version numbers
The pre-release pipeline builds 10 platform-specific packages (win32-x64, darwin-arm64, linux-x64, etc.) in parallel. Each platform ran
update_ext_version.pyindependently, and because the script uses the current time (down to the minute), each platform ended up with a slightly different version:In VS Code, users only see their own platform's version, so this wasn't visually obvious — but the Marketplace version history showed multiple entries per day, which was confusing.
For example, marketplace shows


while vscode shows
What does
standardizedVersioningdo?The flag is already set in our pre-release pipeline (
azure-pipeline.pre-release.ymlline 32):When this flag is
trueand it's a pre-release build, thevscode-engineeringtemplate runs a step calledmodify-extension-version.ymlbefore ourbuildSteps. See https://github.com/microsoft/vscode-engineering/blob/main/azure-pipelines/extension/templates/steps/modify-extension-version.yml for what it does.This runs once per platform job, but
$(Build.BuildNumber)is the same for all jobs in a pipeline run, so every platform gets the identical version.Example versions under the new scheme
1.27.20260406011.27.20260406021.27.2026040701Why this is better
1.27.2026040601clearly means "April 6, 2026, build 1".Revsuffix from Azure DevOps handles re-triggers2026040601>13652359(old max), so new versions always sort ahead of old ones on the Marketplace2099123199≈ 2.1 billion, well under the uint32 max of ~4.3 billionWhat changed in the code?
build/update_ext_version.py--release, no--build-id). The script now validates the even/odd minor version rule and strips any-dev/-rcsuffix if--for-publishing, but does not overwrite the version set by the template.elsebranch that calledmicro_build_number()— this was the code that was clobbering the template's version.--releaseand--build-idcode paths are completely unchanged.build/azure-pipeline.pre-release.ymlbuild/test_update_ext_version.py--for-publishing(without--releaseor--build-id) cases now expect the original micro version to be preserved instead of being replaced with a computed timestamp.EXPECTED_BUILD_IDconstant.Stable releases are not affected
The stable pipeline (
azure-pipeline.stable.yml) does not usestandardizedVersioningand continues to callupdate_ext_version.py --release --for-publishing, which is unchanged.