Currently, enterprise_extensions uses manual version management in enterprise_extensions/__init__.py, requiring maintainers to manually update version numbers before each release. This is error-prone and inconsistent with the other packages (PTMCMCSampler and enterprise) which use setuptools_scm for automatic version generation.
Current Setup:
- Manual version updates in
__init__.py (e.g., __version__ = "3.0.2")
- Version must be updated before each release
- Risk of version mismatches between git tags and package version
Proposed Improvement:
- Implement
setuptools_scm for automatic version generation
- Version automatically derived from git tags
- Consistent with PTMCMCSampler and enterprise packages
- Eliminate manual version management
Benefits:
- Eliminates manual version update step
- Reduces human error in version management
- Consistent versioning across all packages
- Automatic version generation from git tags
- Simplified release process
Implementation Steps:
- Add
setuptools_scm[toml]>=6.0 to build requirements in pyproject.toml
- Configure
setuptools_scm in pyproject.toml:
[tool.setuptools_scm]
write_to = "enterprise_extensions/version.py"
- Remove manual
__version__ from __init__.py
- Update
setup.py to use use_scm_version=True
- Update release documentation to reflect automated versioning
- Test release process with new versioning
Migration Considerations:
- Need to ensure existing version compatibility
- Update release documentation in
RELEASE.md
- Coordinate with current release workflow
Currently, enterprise_extensions uses manual version management in
enterprise_extensions/__init__.py, requiring maintainers to manually update version numbers before each release. This is error-prone and inconsistent with the other packages (PTMCMCSampler and enterprise) which usesetuptools_scmfor automatic version generation.Current Setup:
__init__.py(e.g.,__version__ = "3.0.2")Proposed Improvement:
setuptools_scmfor automatic version generationBenefits:
Implementation Steps:
setuptools_scm[toml]>=6.0to build requirements inpyproject.tomlsetuptools_scminpyproject.toml:__version__from__init__.pysetup.pyto useuse_scm_version=TrueMigration Considerations:
RELEASE.md