Skip to content

Use pax instead of GNU headers for tar#3203

Merged
messense merged 2 commits into
mainfrom
konsti/tar-pax
May 28, 2026
Merged

Use pax instead of GNU headers for tar#3203
messense merged 2 commits into
mainfrom
konsti/tar-pax

Conversation

@konstin
Copy link
Copy Markdown
Member

@konstin konstin commented May 27, 2026

maturin has been using GNU headers for tar, while the spec wants pax headers (pypa/packaging.python.org#2058). This PR switches maturin over to pax headers.

Using a constraint tar/zip format is important to avoid parser differentials.

Fixes #3195

maturin has been using GNU headers for tar, while the spec wants pax headers (pypa/packaging.python.org#2058). This PR switches maturin over to pax headers.

Using a constraint tar/zip format is important to avoid parser differentials.
@konstin konstin added the bug Something isn't working label May 27, 2026
@messense messense requested a review from Copilot May 27, 2026 12:38
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates sdist tar generation to avoid GNU headers and emit pax-compatible tar entries for paths that exceed ustar limits or require UTF-8 pax path metadata.

Changes:

  • Switches sdist entry headers from GNU to ustar.
  • Adds manual pax extended header generation for archive paths that cannot be represented directly in ustar.
  • Adds a regression test inspecting raw tar blocks for pax path handling.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/module_writer/sdist_writer.rs Outdated
@messense messense merged commit 697a283 into main May 28, 2026
45 checks passed
@messense messense deleted the konsti/tar-pax branch May 28, 2026 11:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

maturin generates non-pax source distributions

3 participants