mirror of
https://github.com/deepseek-ai/DeepGEMM.git
synced 2026-11-05 00:47:26 +00:00
[GH-ISSUE #228] __version__ doesn't match Git tags for post-releases, breaking build tools #130
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
deepseek-ai/DeepGEMM#130
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @pavank63 on GitHub (Nov 18, 2025).
Original GitHub issue: https://github.com/deepseek-ai/DeepGEMM/issues/228
Problem
When building from post-release tags (e.g.,
v2.1.1.post3), the__version__indeep_gemm/__init__.pycontains only the base version (2.1.1), not the full post-release version.This causes:
Example
Affected Tags
PEP Violations
PEP 440 (Version Identification and Dependency Specification):
Post-releases are defined as versions like X.Y.Z.postN to address minor errors in final releases. The Git tags correctly use post-release format (v2.1.1.post3), but the package metadata reports only the
base version (2.1.1), making it impossible for users to install or depend on specific post-release versions. This breaks the semantic meaning of post-releases in the Python packaging ecosystem.
PEP 427 (The Wheel Binary Package Format):
The wheel filename format is strictly defined as {distribution}-{version}-{python}-{abi}-{platform}.whl. Building from tag v2.1.1.post3 produces deep_gemm-2.1.1-.whl instead of the correct
deep_gemm-2.1.1.post3-.whl. This filename mismatch breaks tools that verify artifact provenance, security scanners that match versions, and package managers that rely on filename-based version
identification.
PEP 517 (Build-System Independent Format):
Build backends must create .dist-info directories with accurate metadata. When building from v2.1.1.post3, the resulting .dist-info/METADATA file contains Version: 2.1.1 instead of Version: 2.1.1.post3.
This causes build frontends (pip, build, etc.) to receive incorrect version information, breaking dependency resolution and violating the expectation that build metadata accurately reflects the source
version.
Proposed Solution
For future post-release tags, update version in deep_gemm/init.py to match the tag:
When creating tag v2.1.1.post4:
version = '2.1.1.post4' # Include the .postN suffix
Alternatively, consider migrating to https://setuptools-scm.readthedocs.io/ which automatically derives version from Git tags, eliminating manual version management.
I am happy to submit a PR with either solution if you're interested in fixing this for future releases.
@pavank63 commented on GitHub (Nov 25, 2025):
ping @LyricZhao @ko3n1g