Skip to content

registry: fix sourcery platform archive format#9902

Merged
jdx merged 1 commit into
jdx:mainfrom
risu729:registry/fix-sourcery-platform-format
May 17, 2026
Merged

registry: fix sourcery platform archive format#9902
jdx merged 1 commit into
jdx:mainfrom
risu729:registry/fix-sourcery-platform-format

Conversation

@risu729

@risu729 risu729 commented May 16, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Move Sourcery's format = "tar.gz" override to the Linux x64 platform only.
  • Add os = ["linux", "macos"] because current Sourcery releases do not publish Windows assets.
  • Leave macOS archive format detection to the selected .zip asset so macOS installs no longer try to extract zip files as gzip tar archives.

Fixes #9876.

Popularity

No new registry tool is added in this PR. This only fixes the existing sourcery registry entry, so new-tool popularity data is not applicable.

Existing upstream signals:

  • GitHub: krzysztofzablocki/Sourcery has 7,996 stars and 632 forks, pushed 2026-05-06.

Release asset check

  • Latest 2.3.0 assets: sourcery-2.3.0-ubuntu-22.04.5-lts-jammy-x86_64.tar.xz, sourcery-2.3.0.artifactbundle.zip, sourcery-2.3.0.zip.
  • Reported 2.2.7 assets: sourcery-2.2.7-ubuntu-22.04.5-lts-jammy-x86_64.tar.gz, sourcery-2.2.7.artifactbundle.zip, sourcery-2.2.7.zip.
  • No Windows assets were present in the current/recent release asset lists checked, so this registry entry is limited to Linux and macOS.

Testing

  • taplo fmt --check registry/sourcery.toml && taplo check registry/sourcery.toml
  • git diff --check
  • Linux extraction check with explicit backend options: MISE_DATA_DIR=$(mktemp -d) MISE_CACHE_DIR="$MISE_DATA_DIR/cache" mise x 'github:krzysztofzablocki/Sourcery[format=tar.gz]@2.3.0' -- which sourcery
  • macOS asset extraction simulation: MISE_DATA_DIR=$(mktemp -d) MISE_CACHE_DIR="$MISE_DATA_DIR/cache" MISE_OS=macos MISE_ARCH=x64 mise x 'github:krzysztofzablocki/Sourcery@2.3.0' -- true

mise run lint-fix was attempted on the #9789 branch earlier, but its cargo-check phase was stopped after waiting behind unrelated Cargo build locks from other worktrees. The relevant TOML formatting/checks above passed for this PR.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request updates the sourcery.toml configuration to define supported operating systems and specifies platform-specific backend options for Linux x64. A review comment suggests removing the explicit tar.gz format specification for Linux, as it is redundant and could cause installation failures with newer versions of Sourcery that use .tar.xz archives.

Comment thread registry/sourcery.toml
@greptile-apps

greptile-apps Bot commented May 16, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR scopes the format = "tar.gz" override to linux-x64 only (so macOS no longer tries to extract .zip releases as gzip-tar) and adds os = ["linux", "macos"] to exclude the non-existent Windows assets.

  • The macOS fix is correct: removing the global format override lets macOS auto-detect the .zip asset format properly.
  • The os = ["linux", "macos"] restriction is appropriate given the current release asset list.
  • However, format = "tar.gz" is still kept under [backends.options.platforms.linux-x64], while the PR description itself shows that the latest 2.3.0 Linux asset is a .tar.xz file — not .tar.gz — meaning the extraction decoder will mismatch and break Linux installs at the current version.

Confidence Score: 3/5

The macOS portion of the fix is correct, but the linux-x64 format override is mismatched against the current 2.3.0 release format, which would cause extraction failures on the primary linux-x64 path.

The macOS fix and OS restriction are both sound. The linux-x64 format = "tar.gz" override would force GzDecoder on the current 2.3.0 .tar.xz asset, since the format key drives extraction (not asset selection). Removing the override and relying on filename-based auto-detection would handle both old and new release formats correctly.

registry/sourcery.toml — specifically the [backends.options.platforms.linux-x64] section and its format key.

Important Files Changed

Filename Overview
registry/sourcery.toml Moves format = "tar.gz" to linux-x64 platform and adds os restriction; the format override is wrong for the current 2.3.0 release which ships a .tar.xz Linux archive, risking extraction failure.

Reviews (1): Last reviewed commit: "registry: fix sourcery platform archive ..." | Re-trigger Greptile

Comment thread registry/sourcery.toml
@risu729 risu729 marked this pull request as ready for review May 16, 2026 08:41
@jdx jdx merged commit d50d542 into jdx:main May 17, 2026
33 checks passed
@risu729 risu729 deleted the registry/fix-sourcery-platform-format branch May 17, 2026 15:31
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.

2 participants