Skip to content

Commit c335757

Browse files
Update source/discussions/single-source-version.rst
Co-authored-by: Anderson Bravalheri <[email protected]>
1 parent 3b05459 commit c335757

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

source/discussions/single-source-version.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ One of the challenges in building packages is that the version string can be req
1212
* It needs to be specified when building the package (e.g. in :file:`pyproject.toml`)
1313
This will make it available in the installed package’s metadata, from where it will be accessible at runtime using ``importlib.metadata.version("distribution_name")``.
1414

15-
* A package may set a top level ``__version__`` attribute to provide an alternative means of runtime access to the version of the imported package. If this is done, the value of ``__version__`` attribute and that used by the build system to set the distribution's version should be kept in sync in :ref:`the build systems's recommended way <Build system version handling>`.
15+
* A package may set a module attribute (e.g., ``__version__``) to provide an alternative means of runtime access to the version of the imported package. If this is done, the value of the attribute and that used by the build system to set the distribution's version should be kept in sync in :ref:`the build systems's recommended way <Build system version handling>`.
1616

1717
* If the code is in in a version control system (VCS), e.g. Git, the version may appear in a *tag* such as ``v1.2.3``.
1818

0 commit comments

Comments
 (0)