Skip to content

Commit

Permalink
Use dynamic version in pyproject.toml and remove unused header declar…
Browse files Browse the repository at this point in the history
…ation from package data.

The version will be imported from `ml_dtypes.__version__`.

PiperOrigin-RevId: 723138894
  • Loading branch information
cantonios authored and The ml_dtypes Authors committed Feb 4, 2025
1 parent 7ef2351 commit f902c19
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,12 @@ To release a new version (e.g. from `1.0.0` -> `2.0.0`):

## [Unreleased]

## [0.5.2] - 2025-01-06
## [0.5.2] - 2025-01-31

* Dropped support for Power wheels again. These turned out to cause problems in
our release process. We will consider readding these if NumPy ships Power
wheels.
* Fixed GCC compilation issues related to ambiguous casts.

## [0.5.1] - 2025-01-06

Expand Down
2 changes: 1 addition & 1 deletion ml_dtypes/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

__version__ = "0.5.1" # Keep in sync with pyproject.toml:version
__version__ = "0.5.1"
__all__ = [
"__version__",
"bfloat16",
Expand Down
6 changes: 4 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "ml_dtypes"
version = "0.5.1" # Keep in sync with ml_dtypes/__init__.py:__version__
dynamic = ["version"] # Load from ml_dtypes.__version__.
description = ""
readme = "README.md"
requires-python = ">=3.9"
Expand Down Expand Up @@ -60,6 +60,8 @@ build-backend = "setuptools.build_meta"
packages = ["ml_dtypes"]
include-package-data = false

[tool.setuptools.dynamic]
version = {attr = "ml_dtypes.__version__"}

[tool.setuptools.package-data]
ml_dtypes = ["py.typed"]
"ml_dtypes.include" = ["*.h"]

0 comments on commit f902c19

Please sign in to comment.