Skip to content

Support min_os_version on Windows#2855

Open
abdnh wants to merge 7 commits into
beeware:mainfrom
ankitects:win-version
Open

Support min_os_version on Windows#2855
abdnh wants to merge 7 commits into
beeware:mainfrom
ankitects:win-version

Conversation

@abdnh
Copy link
Copy Markdown
Contributor

@abdnh abdnh commented May 29, 2026

This adds support for specifying the minimum supported Windows build number using the min_os_version option.

PR Checklist:

  • I will abide by the BeeWare Code of Conduct
  • I have read and have followed the CONTRIBUTING.md file
  • This PR was generated or assisted using an AI tool

Context

ankitects/anki#4765

app_packages_path: Path,
**kwargs,
):
support_min_version = 10240 # Windows 10
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Hardcoded because there's no reliable way to detect the minimum version from the support package as far as I know.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The support package won't include this information, but we could include it in the briefcase.toml in the app template - that is where the support package build number is defined, so it would make sense to tie the two together, rather than hard-coding the value here. If it isn't in the template, falling back to "not defined" would make sense to me.

@abdnh abdnh marked this pull request as ready for review May 29, 2026 14:19
Copy link
Copy Markdown
Member

@freakboy3742 freakboy3742 left a comment

Choose a reason for hiding this comment

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

Thanks for the update. This looks like a really useful improvement; a couple of suggestions inline regarding how this will be applied in practice.

app_packages_path: Path,
**kwargs,
):
support_min_version = 10240 # Windows 10
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The support package won't include this information, but we could include it in the briefcase.toml in the app template - that is where the support package build number is defined, so it would make sense to tie the two together, rather than hard-coding the value here. If it isn't in the template, falling back to "not defined" would make sense to me.

"Your Windows app specifies a minimum build number of "
f"{min_version}, but the support package only supports "
f"{support_min_version}"
)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This checks the value on the installer side, but it won't put the value into the template in the "default" case. i.e., it will catch the error if I try to build the app on Windows 8, but if I build the app on Windows 11, and then try to install on Windows 8, it won't pass that information down unless I explicitly put min_os_version in the app config.

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