Skip to content

Commit 28a51e4

Browse files
authored
Use Hatch Dynamic Versions (#539)
* Correct package versions and add single version source * remove unused imports
1 parent aa22d45 commit 28a51e4

File tree

13 files changed

+32
-29
lines changed

13 files changed

+32
-29
lines changed

packages/aws-sdk-signers/pyproject.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "aws-sdk-signers"
3-
version = "0.0.3"
3+
dynamic = ["version"]
44
requires-python = ">=3.12"
55
authors = [
66
{name = "Amazon Web Services"},
@@ -35,6 +35,9 @@ classifiers = [
3535
requires = ["hatchling"]
3636
build-backend = "hatchling.build"
3737

38+
[tool.hatch.version]
39+
path = "src/aws_sdk_signers/__init__.py"
40+
3841
[tool.hatch.build]
3942
exclude = [
4043
"tests",

packages/aws-sdk-signers/src/aws_sdk_signers/__init__.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@
55

66
from __future__ import annotations
77

8-
import importlib.metadata
9-
108
from ._http import AWSRequest, Field, Fields, URI
119
from ._identity import AWSCredentialIdentity
1210
from ._io import AsyncBytesReader
@@ -18,7 +16,7 @@
1816
)
1917

2018
__license__ = "Apache-2.0"
21-
__version__ = importlib.metadata.version("aws-sdk-signers")
19+
__version__ = "0.0.3"
2220

2321
__all__ = (
2422
"URI",

packages/smithy-aws-core/pyproject.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "smithy-aws-core"
3-
version = "0.0.1"
3+
dynamic = ["version"]
44
requires-python = ">=3.12"
55
authors = [
66
{name = "Amazon Web Services"},
@@ -40,6 +40,9 @@ dependencies = [
4040
requires = ["hatchling"]
4141
build-backend = "hatchling.build"
4242

43+
[tool.hatch.version]
44+
path = "src/smithy_aws_core/__init__.py"
45+
4346
[project.optional-dependencies]
4447
eventstream = [
4548
"smithy-aws-event-stream"
Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
22
# SPDX-License-Identifier: Apache-2.0
33

4-
import importlib.metadata
5-
6-
__version__: str = importlib.metadata.version("smithy-aws-core")
4+
__version__ = "0.0.3"

packages/smithy-aws-event-stream/pyproject.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "smithy-aws-event-stream"
3-
version = "0.0.1"
3+
dynamic = ["version"]
44
requires-python = ">=3.12"
55
authors = [
66
{name = "Amazon Web Services"},
@@ -38,6 +38,9 @@ dependencies = [
3838
requires = ["hatchling"]
3939
build-backend = "hatchling.build"
4040

41+
[tool.hatch.version]
42+
path = "src/smithy_aws_event_stream/__init__.py"
43+
4144
[tool.hatch.build]
4245
exclude = [
4346
"tests",
Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
22
# SPDX-License-Identifier: Apache-2.0
33

4-
import importlib.metadata
5-
6-
__version__: str = importlib.metadata.version("smithy-aws-event-stream")
4+
__version__ = "0.0.1"

packages/smithy-core/pyproject.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "smithy-core"
3-
version = "0.0.2"
3+
dynamic = ["version"]
44
requires-python = ">=3.12"
55
authors = [
66
{name = "Amazon Web Services"},
@@ -41,6 +41,9 @@ typing = [
4141
requires = ["hatchling"]
4242
build-backend = "hatchling.build"
4343

44+
[tool.hatch.version]
45+
path = "src/smithy_core/__init__.py"
46+
4447
[tool.hatch.build]
4548
exclude = [
4649
"tests",

packages/smithy-core/src/smithy_core/__init__.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
22
# SPDX-License-Identifier: Apache-2.0
3-
import importlib.metadata
43
from dataclasses import dataclass
54
from enum import Enum
65
from functools import cached_property
@@ -9,7 +8,7 @@
98
from . import interfaces, rfc3986
109
from .exceptions import SmithyError
1110

12-
__version__: str = importlib.metadata.version("smithy-core")
11+
__version__ = "0.0.2"
1312

1413

1514
class HostType(Enum):

packages/smithy-http/pyproject.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "smithy-http"
3-
version = "0.0.1"
3+
dynamic = ["version"]
44
requires-python = ">=3.12"
55
authors = [
66
{name = "Amazon Web Services"},
@@ -47,6 +47,9 @@ aiohttp = [
4747
requires = ["hatchling"]
4848
build-backend = "hatchling.build"
4949

50+
[tool.hatch.version]
51+
path = "src/smithy_http/__init__.py"
52+
5053
[tool.hatch.build]
5154
exclude = [
5255
"tests",

packages/smithy-http/src/smithy_http/__init__.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
22
# SPDX-License-Identifier: Apache-2.0
3-
import importlib.metadata
43
from collections import Counter, OrderedDict
54
from collections.abc import Iterable, Iterator
65

76
from . import interfaces
87
from .interfaces import FieldPosition
98

10-
__version__: str = importlib.metadata.version("smithy-http")
9+
__version__ = "0.0.1"
1110

1211

1312
class Field(interfaces.Field):

0 commit comments

Comments
 (0)