Hatch v1.18.22026-10-28
Changed:
- Upgrade default CPython distributions to 20261009
Added:
- Officially support Python 3.15. Managed Python 3.15 distributions are now the final 3.15.0 release rather than a release candidate, and the default test command matrix includes 3.15 and 3.15t
Fixed:
- Fix syncing environment plugin requirements on standalone binaries built to forward to pip
- Fix the test command raising an IndexError with --cover, or silently doing nothing otherwise, when the --include or --exclude options match no environments. It now aborts with a clear message.
- Fix build hooks that set require-runtime-dependencies (or otherwise declare dynamic build dependencies) failing with ModuleNotFoundError because those dependencies were never installed into the build environment. Environment plugins should use the new addadditionaldependencies method to extend additional_dependencies so that cached dependency views are invalidated.
- Fix the fmt command dropping the default Ruff configuration when the user's Ruff configuration contains keys that merely start with extend, such as extend-exclude. Only an exact extend key now prevents the default configuration from being injected.
Hatchling v1.33.02026-10-28
Added:
- Officially support Python 3.15.
Hatchling v1.32.42026-09-20
Fixed:
- Revert the extra type parameter added to BuildHookInterface in 1.32.3, which broke plugins that subscripted the interface with a single argument (e.g. BuildHookInterface[MyConfig]) by raising TypeError at import time. BuilderConfig is likewise no longer generic, restoring the pre-1.32.3 plugin interface.
- Strip spaces around version metadata when using original input for CalVer to keep leading zeroes.
Hatchling v1.32.32026-09-17
Fixed:
- Preserve the version string exactly as written in core metadata, so stylized versions such as CalVer 2026.08.10 are no longer stripped of leading zeros. Distribution file names and .dist-info directories continue to use the PEP 440 normalized form.
Hatch v1.18.12026-09-16
Added:
- Apply context formatting to the lock-filename environment option so fields such as {env_name} and {matrix:...} are resolved when computing the lock file path.
Fixed:
- Consolidate extras and feature resolution into a single code path, fixing regressions where environment and project extras could be dropped or resolved inconsistently, and always validate undefined features.
- Normalize hyphens in the plugin name when building environment option environment variable names in getenvvar(), so options for hyphenated plugins resolve to the correct variable.
Hatch v1.18.02026-08-11
Changed:
- Upgrade default CPython distributions to 20260807
Added:
- Add the sources environment option, which redirects dependencies to a local path, Git repository, URL, alternate index, or workspace member at install time without altering published metadata. The top-level [tool.hatch.sources] table is an alias for the default environment, environments inherit sources entry by entry, the HATCHNOSOURCES environment variable disables them, and hatch dep show sources reports what each source redirects
- Add the --all/-a flag to the build command to build the workspace root and every workspace member defined by the selected environment, consolidating artifacts in the workspace root's dist directory by default. A root that does not define a project table is skipped so that a top-level pyproject.toml may only contain workspace configuration
- Add the tool.hatch.requires-hatch field, a version specifier set that commands reading the project's metadata enforce against the running version of Hatch
- Add first-class support for free-threaded distribution names such as 3.13t and 3.14t to the python commands and environment python option, rather than requiring the HATCHPYTHONVARIANT_GIL environment variable
- The version command can now bump versions that are statically defined by the project.version field, updating pyproject.toml in place. Pass --force to allow an explicit downgrade
- Support managing Python 3.15 distributions, currently 3.15.0rc1
Fixed:
- Erase stale coverage data before running hatch test --cover.
- Fix environment creation crashing when a metadata hook exists that doesn’t happen to be installed in the hatch CLI’s environment.
- Fix commands run by hatch run no longer being interruptible with Ctrl-C, which happened because the ignored SIGINT of the parent process was inherited by the child process.
- Fix the generated Pyrefly config being invalid on Windows, since backslashes in the absolute paths were interpreted as TOML escape sequences.
- Fix the hardcoded reliance on pip when installing dependencies internally by using uv instead.
- Fix environment creation silently installing a GIL-enabled Python distribution when Hatch itself runs on a free-threaded build. The distribution matching the running interpreter, such as 3.14t, is now selected.
- Fix free-threaded selectors such as 3.14t being rejected by an environment's python option, even though hatch python install 3.14t already accepted them.
- Never automatically select a prerelease Python distribution, such as 3.15.0rc1, when falling back to the latest compatible version. A prerelease is still installed when requested explicitly.
Hatchling v1.32.02026-08-11
Changed:
- Bump default core metadata version to 2.5
- Add tomlkit as a runtime dependency, which is required to rewrite pyproject.toml when setting a static version
Added:
- The version command can now set a version that is statically defined by the project.version field, updating pyproject.toml in place. Pass --force to allow an explicit downgrade
Fixed:
- Allow the ; private annotation on project.import-names and project.import-namespaces entries rather than rejecting them as invalid import names.
- Reject project.readme paths that are absolute or resolve outside of the project directory.
Hatch v1.17.12026-07-08
Fixed
- Use TemporaryDirectory and pylock*.toml for temporary lock files.
- Skip injection of ruff extend if a key already exists in ruff.toml.
- Pass --no-header to uv pip compile in the uv locker so that generated lockfiles are deterministic.
- Fix env-dependency extras being dropped when a metadata hook is configured and resolve workspace-member extras from the member's own metadata.
Hatchling v1.31.02026-07-08
Fixed
- Only rewrite the shebang of a shared script when a Python shebang is present on the first line, preserving binary files and other content verbatim instead of dropping leading bytes.
Hatch v1.17.02026-06-02
Changed:
- The hatch fmt command is now deprecated in favor of the new hatch check command group
- Migrate HTTP client from httpx to httpx2
Added:
- Add hatch check command group with subcommands for check code (linting), check fmt (formatting), and check types (type checking)
- Add hatch check types command for type checking using Pyrefly, with --summarize and --cover flags
- Add hatch env lock command to generate PEP 751 compliant lockfiles (pylock.toml) for environments
- Add hatch dep lock and hatch lock commands as shortcuts for locking the active environment
- Add hatch dep sync command for syncing dependencies from a lockfile
- Add pluggable dependency locker interface with built-in UV and pip implementations
- Add --cover-xml and --cover-xml-output flags to the hatch test command for generating XML coverage reports
- Add linehaul telemetry data to User-Agent header for PyPI download statistics
- Auto-create environment when locking if it doesn't exist
Fixed:
- Fix help output formatting for the run command