Skip to content

Commit 1867a90

Browse files
authored
Update the default version of core metadata to 2.4 (#1829)
1 parent 6bc4bbe commit 1867a90

File tree

39 files changed

+43
-3
lines changed

39 files changed

+43
-3
lines changed

backend/src/hatchling/metadata/spec.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
if TYPE_CHECKING:
66
from hatchling.metadata.core import ProjectMetadata
77

8-
DEFAULT_METADATA_VERSION = '2.3'
8+
DEFAULT_METADATA_VERSION = '2.4'
99
LATEST_METADATA_VERSION = '2.4'
1010
CORE_METADATA_PROJECT_FIELDS = {
1111
'Author': ('authors',),

docs/history/hatchling.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
88

99
## Unreleased
1010

11+
***Added:***
12+
13+
- Update the default version of core metadata to 2.4
14+
1115
## [1.26.3](https://github.com/pypa/hatch/releases/tag/hatchling-v1.26.3) - 2024-11-12 ## {: #hatchling-v1.26.3 }
1216

1317
***Fixed:***

docs/plugins/builder/sdist.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ The builder plugin name is `sdist`.
1616

1717
| Option | Default | Description |
1818
| --- | --- | --- |
19-
| `core-metadata-version` | `"2.3"` | The version of [core metadata](https://packaging.python.org/specifications/core-metadata/) to use |
19+
| `core-metadata-version` | `"2.4"` | The version of [core metadata](https://packaging.python.org/specifications/core-metadata/) to use |
2020
| `strict-naming` | `true` | Whether or not file names should contain the normalized version of the project name |
2121
| `support-legacy` | `false` | Whether or not to include a `setup.py` file to support legacy installation mechanisms |
2222

docs/plugins/builder/wheel.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ The builder plugin name is `wheel`.
1616

1717
| Option | Default | Description |
1818
| --- | --- | --- |
19-
| `core-metadata-version` | `"2.3"` | The version of [core metadata](https://packaging.python.org/specifications/core-metadata/) to use |
19+
| `core-metadata-version` | `"2.4"` | The version of [core metadata](https://packaging.python.org/specifications/core-metadata/) to use |
2020
| `shared-data` | | A mapping similar to the [forced inclusion](../../config/build.md#forced-inclusion) option corresponding to the `data` subdirectory within the standard [data directory](https://packaging.python.org/en/latest/specifications/binary-distribution-format/#the-data-directory) that will be installed globally in a given Python environment, usually under `#!python sys.prefix` |
2121
| `shared-scripts` | | A mapping similar to the [forced inclusion](../../config/build.md#forced-inclusion) option corresponding to the `scripts` subdirectory within the standard [data directory](https://packaging.python.org/en/latest/specifications/binary-distribution-format/#the-data-directory) that will be installed in a given Python environment, usually under `Scripts` on Windows or `bin` otherwise, and would normally be available on PATH |
2222
| `extra-metadata` | | A mapping similar to the [forced inclusion](../../config/build.md#forced-inclusion) option corresponding to extra [metadata](https://peps.python.org/pep-0427/#the-dist-info-directory) that will be shipped in a directory named `extra_metadata` |

tests/helpers/templates/sdist/standard_default.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ def get_files(**kwargs):
1616
Metadata-Version: {DEFAULT_METADATA_VERSION}
1717
Name: {kwargs['project_name']}
1818
Version: 0.0.1
19+
License-File: LICENSE.txt
1920
""",
2021
)
2122
)

tests/helpers/templates/sdist/standard_default_build_script_artifacts.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ def initialize(self, version, build_data):
3939
Metadata-Version: {DEFAULT_METADATA_VERSION}
4040
Name: {kwargs['project_name']}
4141
Version: 0.0.1
42+
License-File: LICENSE.txt
4243
""",
4344
),
4445
))

tests/helpers/templates/sdist/standard_default_build_script_extra_dependencies.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ def initialize(self, version, build_data):
4040
Metadata-Version: {DEFAULT_METADATA_VERSION}
4141
Name: {kwargs['project_name']}
4242
Version: 0.0.1
43+
License-File: LICENSE.txt
4344
Requires-Dist: binary
4445
""",
4546
),

tests/helpers/templates/sdist/standard_default_support_legacy.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ def get_files(**kwargs):
1616
Metadata-Version: {DEFAULT_METADATA_VERSION}
1717
Name: {kwargs['project_name']}
1818
Version: 0.0.1
19+
License-File: LICENSE.txt
1920
""",
2021
),
2122
File(

tests/helpers/templates/sdist/standard_default_vcs_git_exclusion_files.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ def get_files(**kwargs):
2525
Metadata-Version: {DEFAULT_METADATA_VERSION}
2626
Name: {kwargs['project_name']}
2727
Version: 0.0.1
28+
License-File: LICENSE.txt
2829
""",
2930
),
3031
))

tests/helpers/templates/sdist/standard_default_vcs_mercurial_exclusion_files.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ def get_files(**kwargs):
3131
Metadata-Version: {DEFAULT_METADATA_VERSION}
3232
Name: {kwargs['project_name']}
3333
Version: 0.0.1
34+
License-File: LICENSE.txt
3435
""",
3536
),
3637
))

0 commit comments

Comments
 (0)