Repository navigation
Bump to 6.1.1: Release Windows apps drop Python's debug modules again - #260
Merged
Merged
Conversation
The 3.0.0 rewrite of the CopyPythonDLLs step (cmd.exe DEL -> rm_globs.cmake) lost the Release-only removal of DLLs\*_d.*, so every Release Windows app shipped each extension module twice (_ctypes.pyd and _ctypes_d.pyd, ...): 23 files, ~10 MB, and as many extra signatures when the app is code-signed. Release and Profile builds remove them again; Debug builds keep them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.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.
Release Windows apps ship Python's debug modules next to the release ones (
_ctypes.pydand_ctypes_d.pyd,_ssl.pydand_ssl_d.pyd, …). In a Flet app built withflet build windowsthat's 23 files, ~10 MB (about 10% of the unpacked app), and when the app is code-signed, as many extra signatures.Cause
python-build's Windows package carries both Release and Debug builds of CPython, so Debug Flutter builds can load the debug runtime. Before 3.0.0,
CopyPythonDLLsremoved the debug files from Release builds:The 3.0.0 rewrite (#209) replaced the
cmd.exeDELs withcmake -E rm/rm_globs.cmake. The.ico,.cat,tcl86t.dllandtk86t.dllremovals came across, but this Release-only one didn't; only its comment stayed.Fix
CopyPythonDLLsremovesDLLs/*_d.*again in every non-Debug build (Release and Profile), through the samerm_globs.cmakehelper. Debug builds keep them ($<IF:$<CONFIG:Debug>,__none__,*_d.*>;__none__matches nothing). Thepython3*_d.dll/dart_bridge_d.dllchoice is unchanged:serious_python_windows_bundled_librariesalready picks those per config.Also:
build.gradle.kts, the Darwin podspec, the example lockfiles), with changelog entries.Testing
Not built on Windows from this branch yet. Seen in a Release app built with 6.1.0 (
flet build windowson a Flet Studio builder):DLLs/held 23*_d.*files, 9.9 MB uncompressed. After the release, the same build should list none.