Skip to content

Conversation

@branchv
Copy link
Contributor

@branchv branchv commented Jun 11, 2025

Fixes #1605

A common value for SOURCE_DATE_EPOCH is 0, which unfortunately breaks hatchling:

$ uv init --build-backend=hatch
$ SOURCE_DATE_EPOCH=0 uv build
# ...
  File "/opt/homebrew/Cellar/[email protected]/3.13.4/Frameworks/Python.framework/Versions/3.13/lib/python3.13/zipfile/__init__.py", line 412, in __init__
    raise ValueError('ZIP does not support timestamps before 1980')
ValueError: ZIP does not support timestamps before 1980

This clamps to 1980 instead (same as setuptools and flit-core. poetry also support this but defaults to 2016)

Copy link
Contributor

@ofek ofek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@branchv
Copy link
Contributor Author

branchv commented Dec 10, 2025

@ofek @cjames23 sorry for the ping, but Homebrew has been working around this bug for a while so I'd love to see this merged

@branchv branchv force-pushed the source-date-epoch branch from a4cba26 to bc8804a Compare January 9, 2026 19:11
@cjames23
Copy link
Member

I will need to get a PR out to address the changes with Rich in 14.3 this week to merge this.

davep added a commit to davep/homebrew-homebrew that referenced this pull request Jan 31, 2026
@cjames23 cjames23 enabled auto-merge (squash) February 3, 2026 23:43
@cjames23 cjames23 disabled auto-merge February 3, 2026 23:44
@cjames23 cjames23 merged commit f400be1 into pypa:master Feb 3, 2026
94 of 99 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

zipfile will fail if SOURCE_DATE_EPOCH is before 1980

3 participants