- 开发工具
- 构建工具
- CLI
- 包管理器
【免费下载链接】winpython
A free Python-distribution for Windows platform, including prebuilt packages for Scientific Python.
WinPythonZero 是 WinPython 家族中以极简包集为特征的发行口味,其3.6.2.0Zero版本在 64 位平台上将 CPython 升级至 3.6.2,并完成了一次围绕 REPL 体验与数据序列化的包集调整。本文以仓库中的 changelogs/WinPythonZero-64bit-3.6.2.0_History.md 为主线,逐项解读本次变更(新增 1 个包、升级 8 个包、移除 3 个包),并顺带结合当前仓库的构建工具链,说明此类发行版是如何由 flavor 机制组装出来的。读完本文,你将能准确理解 WinPythonZero 的包集构成、每个包的版本演化含义,并掌握在仓库中定位对应清单与构建入口的方法。
WinPythonZero 是什么
WinPython 是一个面向 Windows 平台的可移植 Python 发行版(详见 README.rst 的 Overview 部分),不需要安装即可解压运行。而版本号中的Zero后缀标识的是该发行版的一个特殊"口味":从本版本的包清单(见下文"完整包清单")可以看出,它只包含 CPython 解释器、pip / setuptools 以及少量轻量工具库,不携带 numpy、scipy、matplotlib 等科学计算栈,属于刻意保持精简的发行形态——适合作为干净的 Python 基础环境,再按需用 pip 自行补充依赖。
本次WinPython-64bit 3.6.2.0Zero是自3.6.1.1Zero以来的一个更新版本,核心变化是:
- 解释器升级:CPython
3.6.1→3.6.2(3.6 系列的一个修订版本); - WinPython 自身工具链升级:
1.9.20170423→1.9.20170812; - 围绕交互式命令行、并行计算与数据序列化生态做了一轮包版本刷新;
- 同时精简掉了 3 个不再需要的辅助包。
新增包:pyreadline 2.0
本次唯一新增的包是pyreadline 2.0。按变更记录中的说明,它的作用是让 IPython 能够在 Windows 命令行窗口中正确显示彩色文本——pyreadline 为 Windows 控制台提供了类似 GNU readline 的行编辑与着色能力。对于在 cmd / PowerShell 中重度使用 IPython 或交互式终端的用户来说,这是体验层面的补全项。
升级包详解
本次共升级 8 个包,变更记录给出了从旧版本到新版本的完整对照,整理如下:
| 包名 | 版本变化 | 官方描述(变更记录原文) |
|---|---|---|
| Python | 3.6.1 → 3.6.2 | Python programming language with standard library |
| cloudpickle | 0.2.2 → 0.3.1 | Extended pickling support for Python objects |
| dask | 0.14.3 → 0.15.1 | Minimal task scheduling abstraction |
| prompt_toolkit | 1.0.14 → 1.0.15 | Library for building powerful interactive command lines in Python |
| ptpython | 0.39 → 0.41 | Python REPL build on top of prompt_toolkit |
| pyodbc | 4.0.16 → 4.0.17 | DB API Module for ODBC |
| setuptools | 35.0.2 → 36.2.7 | Download, build, install, upgrade, and uninstall Python packages |
| winpython | 1.9.20170423 → 1.9.20170812 | WinPython distribution tools, including WPPM (package manager) |
几个值得留意的版本信号:
- Python 3.6.2:3.6 系列的 bugfix 修订版,属于解释器层面的事实性升级,无需改动用户代码,但修复了该分支上的一系列底层问题;
- dask 0.15.1 与 cloudpickle 0.3.1:两者是配合使用的——dask 依赖 cloudpickle 来序列化任务图与闭包。dask 版本号的推进同时带动了 cloudpickle 的升级,说明发行版维护者在打包时保持了这对依赖的兼容性;
- prompt_toolkit 1.0.15 与 ptpython 0.41:ptpython 是构建在 prompt_toolkit 之上的增强版 Python REPL,两者成对升级,服务于交互式命令行体验;
- setuptools 36.2.7:跨越了多个小版本,带来安装打包层面的改进;
- winpython 1.9.20170812:这是 WinPython 自己的发行工具包(含 WPPM 包管理器),随发行版一并更新,确保用户拿到与构建日期一致的工具版本。
移除包分析
本次移除的 3 个包分别是:
| 包名 | 原版本 | 描述 |
|---|---|---|
| appdirs | 1.4.3 | 用于确定平台相关目录(如用户数据目录)的小型模块 |
| packaging | 16.8 | Python 包的核心工具集 |
| pyparsing | 2.2.0 | 一个 Python 解析模块 |
从依赖关系看,packaging、pyparsing与appdirs都曾服务于包安装/打包生态(例如 setuptools 及其依赖链)。结合 setuptools 从35.0.2大幅跃升至36.2.7的事实可以推断:随着 setuptools 升级到内置/自带这些能力的版本,发行版不再需要把它们作为独立顶层包显式列出,因此从清单中移除——属于包集精简而非功能回退。需要说明的是,这是基于变更记录与依赖生态的合理推断,变更记录本身只给出移除事实。
完整包清单
与 History 文档配套的 changelogs/WinPythonZero-64bit-3.6.2.0.md 给出了3.6.2.0Zero的完整包集合,共 23 个 Python 包(Tools 表格为空,即不附带额外工具),是理解 Zero 口味"极简"定位的第一手证据:
| 包名 | 版本 | 描述 |
|---|---|---|
| Python | 3.6.2 | Python programming language with standard library |
| brotli | 0.6.0 | Python binding of the Brotli compression library |
| cloudpickle | 0.3.1 | Extended pickling support for Python objects |
| dask | 0.15.1 | Minimal task scheduling abstraction |
| docopt | 0.6.2 | Pythonic argument parser, that will make you smile |
| jedi | 0.10.2 | An autocompletion tool for Python that can be used for text editors |
| joblib | 0.11 | Lightweight pipelining: using Python functions as pipeline jobs |
| locket | 0.2.0 | File-based locks for Python for Linux and Windows |
| partd | 0.3.8 | Appendable key-value storage |
| pip | 9.0.1 | A tool for installing and managing Python packages |
| prompt_toolkit | 1.0.15 | Library for building powerful interactive command lines in Python |
| ptpython | 0.41 | Python REPL build on top of prompt_toolkit |
| pygments | 2.2.0 | Generic syntax highlighter for general use in all kinds of software |
| pyodbc | 4.0.17 | DB API Module for ODBC |
| pyreadline | 2.0 | IPython needs this module to display color text in Windows command window |
| python_snappy | 0.5.1 | Python library for the snappy compression library from Google |
| pythonnet | 2.4.0.dev0 | .Net and Mono integration for Python |
| setuptools | 36.2.7 | Download, build, install, upgrade, and uninstall Python packages - easily |
| six | 1.10.0 | Python 2 and 3 compatibility utilities |
| sqlite_bro | 0.8.11 | a graphic SQLite Client in 1 Python file |
| toolz | 0.8.2 | List processing tools and functional utilities |
| wcwidth | 0.1.7 | Measures number of Terminal column cells of wide-character codes |
| winpython | 1.9.20170812 | WinPython distribution tools, including WPPM (package manager) |
可以看到,这份清单以解释器 + pip/setuptools 为基础,辅以 REPL 工具链(prompt_toolkit、ptpython、jedi、pygments、pyreadline)、dask 并行计算小生态(dask、cloudpickle、partd、locket、toolz、joblib)以及少量实用库(pyodbc、pythonnet、brotli、python_snappy、sqlite_bro、six),整体维持在"够用且轻"的水平。
背后的机制:Zero 口味与当前仓库的 flavor 构建体系
Zero这类版本后缀,本质上是 WinPython 构建体系中的**口味(flavor)**概念。当前仓库 winpython_builds.toml 仍然沿用了这一设计:每个构建是一个(python, flavor)二元组,[flavors.*]块声明各口味的依赖文件、源码目录与工具目录,例如:
[flavors.dot] requirements = "dot_requirements.txt" source_dirs = "packages.win-amd64" toolsdirs = "bdTools\\Tools.dot"而极简口味的痕迹可以从 dot_requirements.txt 中看到,其头部注释直接写着# the essential,仅列出sqlite_bro、setuptools、wheel、build等最基础条目。历史上 WinPythonZero 正是这种"仅保留核心"思路的产物,与当前的 slim / dot 系列一脉相承。
构建入口由 generate_a_winpython_distropy_meta.bat 提供,它把参数透传给 build_winpython_meta.py:
cd /D %~dp0 rem <toml> [315 | 315:slim ...] [--dry-run] call "C:\WinPdev\WPy64-31190\python-3.11.9.amd64\python.exe" %~dp0\build_winpython_meta.py %*build_winpython_meta.py 中的load_builds()会解析 TOML,expand_builds()把[pythons."3XX"].builds列表展开为具体构建任务(例如315:slim表示 Python 3.15 的 slim 口味),再通过run_build()拼装出完整的python -m winpython.build_winpython命令,最终产物落在{root_dir_for_builds}\bd{target}\bu{flavor}\WPy{arch}-{release}目录下。若想在不实际构建的情况下查看将要执行的命令,可追加--dry-run参数。也就是说,仓库中每一份changelogs/下的 History 文档,都对应着某个 flavor 在某次构建中相对上一版本的包集差异——它们既是发布记录,也是 flavor 机制运行结果的"账本"。
延伸:WPPM 与更新检查
Zero 发行版内置的winpython包(1.9.20170812)提供了 WPPM(WinPython Package Manager),用于浏览已提供包、从随附的 Wheelhouse 安装包或注册 WinPython(参见 README.rst 与 wppm 目录);而 pip 仍是增删包的首选方式。此外,仓库根目录的 check_updates.py 展示了维护者如何系统性地回答"一个已构建版本中哪些包值得升级"的问题——它把更新决策分类为security(存在安全通告)、ready(新版本已稳定且满足约束)、blocked(被依赖范围卡住)、needs(wheelhouse 缺依赖)与too new(版本太新未沉淀),这与 History 文档中"逐包列出升级/移除决策"的书写风格互为表里:变更记录是决策结果,check_updates 是决策依据。
小结
WinPython-64bit 3.6.2.0Zero是一次典型的口味演进:解释器小幅升级至 Python 3.6.2,交互式 REPL 体验(pyreadline 新增、prompt_toolkit/ptpython 升级)与 dask 并行生态(dask/cloudpickle 升级)同步刷新,同时借 setuptools 大版本升级之机移除 3 个冗余辅助包。这份 History 文档的价值不仅在于记录版本变化,更在于作为理解 WinPython 构建体系(flavor 机制、清单文件、构建入口)的窗口——读者可在 changelogs/WinPythonZero-64bit-3.6.2.0.md 查看完整包清单,在 winpython_builds.toml 与 build_winpython_meta.py 中追溯同类的构建流程。
- 开发工具
- 构建工具
- CLI
- 包管理器
【免费下载链接】winpython
A free Python-distribution for Windows platform, including prebuilt packages for Scientific Python.
相关推荐
WinPython Zero 精简变体包清单与版本变更解析:以 WinPythonZero-64bit 3.6.2.0 为例
WinPython Zero 精简变体包清单与版本变更解析:以 WinPythonZero 64bit 3.6.2.0 为例 本文以仓库内 changelogs
开发工具构建工具CLI包管理器WinPythonZero 32 位 3.6.2.0 发行版解析:极简内置包清单与构建产物生成机制
WinPythonZero 32 位 3.6.2.0 发行版解析:极简内置包清单与构建产物生成机制 WinPythonZero 是 WinPython 便携式
开发工具构建工具CLI包管理器WinPython-64bit 3.9.2.0 版本变更全解读:Python 3.9.2 发行版的包生态演进与 Changelog 生成机制
WinPython 64bit 3.9.2.0 版本变更全解读:Python 3.9.2 发行版的包生态演进与 Changelog 生成机制 WinPython
开发工具构建工具CLI包管理器
创作声明:本文部分内容由AI辅助生成(AIGC),仅供参考