Shared rule-metadata vocabulary for the galaxy-tool-refactor tiers (tier 0.5).
Project description
galaxy-tool-refactor-rules
Shared rule-metadata vocabulary for the Galaxy tool refactoring framework — a small, dependency-free "tier 0.5" package consumed by both higher tiers:
| Tier | Layer | Package |
|---|---|---|
| 0.5 | rule metadata | galaxy-tool-refactor-rules (this package) |
| 1 | parsing & validation | galaxy-tool-source |
| 2 | structure | galaxy-tool-codemod |
| 3 | formatting | galaxy-tool-fmt |
| 3.5 | advisory checks | galaxy-tool-lint |
| 3.6 | rule registry / rulesets | galaxy-tool-refactor-registry |
| 4 | app / CLI | galaxy-tool-refactor-cli |
It provides:
galaxy_tool_refactor_rules.meta.RuleMeta— a frozen dataclass describing one GTR rule (code,summary,since,until,cite,order,detect_only,applies_to). A tier-3 formatterRule, a tier-2CodemodCommand, and a tier-3.5CheckRuleeach carry ameta: ClassVar[RuleMeta], so the tiers share one registry vocabulary.galaxy_tool_refactor_rules.violation.Violation— a frozen dataclass for a detect-phase finding (code,sourceline,xpath,message); the pure, lxml-free, read-only counterpart to the mutating tier-2Change/ tier-3Edit.galaxy_tool_refactor_rules.reference.render_rule_reference_table— a pure helper that renders(RuleMeta, tier)pairs as a GitHub-flavored markdown glossary table.
Why a separate package
The descriptor is the only thing the two tiers genuinely share — their
behavioral bases differ (fmt yields lxml edits; codemod walks a cursor), so
those stay in their own packages. Keeping RuleMeta here, with zero runtime
dependencies, lets both fmt and codemod depend on it without depending on each
other — preserving the tier independence documented in
galaxy-tool-fmt/docs/decisions.md §D10. The extraction was anticipated in
that package's §D1 ("a shared rule-engine package will be extracted only when a
second consumer materialises"); the codemod tier is that consumer.
Install / test
uv sync # from the workspace root
uv run --package galaxy-tool-refactor-rules pytest galaxy-tool-refactor-rules/tests/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file galaxy_tool_refactor_rules-0.2.0.tar.gz.
File metadata
- Download URL: galaxy_tool_refactor_rules-0.2.0.tar.gz
- Upload date:
- Size: 12.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b61416ff29411d40afc073572987ad1390ba110df5a7d29db5637b521656ad24
|
|
| MD5 |
9e611b729c108cbac4d78893fdd96b47
|
|
| BLAKE2b-256 |
36d421552dece9e124c2024e4faec56503fb1ae55071dd1bed69a2c25ddc69c3
|
Provenance
The following attestation bundles were made for galaxy_tool_refactor_rules-0.2.0.tar.gz:
Publisher:
release.yml on richard-burhans/galaxy-tool-refactor
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
galaxy_tool_refactor_rules-0.2.0.tar.gz -
Subject digest:
b61416ff29411d40afc073572987ad1390ba110df5a7d29db5637b521656ad24 - Sigstore transparency entry: 1792616694
- Sigstore integration time:
-
Permalink:
richard-burhans/galaxy-tool-refactor@524c6b6ee8dba405f5d3b1d192d120d996140a65 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/richard-burhans
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@524c6b6ee8dba405f5d3b1d192d120d996140a65 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file galaxy_tool_refactor_rules-0.2.0-py3-none-any.whl.
File metadata
- Download URL: galaxy_tool_refactor_rules-0.2.0-py3-none-any.whl
- Upload date:
- Size: 8.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c8a41e04feee4be6e4a1057be894c7f93ae67afd0e388c3ac09a9ef68b443d84
|
|
| MD5 |
016eb06e1d94b3749a9c80f2158ae8e6
|
|
| BLAKE2b-256 |
e4f14d1dbc1aab82ccc6e8a074ad6523d5a3636c1a792489264294bcdf657061
|
Provenance
The following attestation bundles were made for galaxy_tool_refactor_rules-0.2.0-py3-none-any.whl:
Publisher:
release.yml on richard-burhans/galaxy-tool-refactor
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
galaxy_tool_refactor_rules-0.2.0-py3-none-any.whl -
Subject digest:
c8a41e04feee4be6e4a1057be894c7f93ae67afd0e388c3ac09a9ef68b443d84 - Sigstore transparency entry: 1792616878
- Sigstore integration time:
-
Permalink:
richard-burhans/galaxy-tool-refactor@524c6b6ee8dba405f5d3b1d192d120d996140a65 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/richard-burhans
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@524c6b6ee8dba405f5d3b1d192d120d996140a65 -
Trigger Event:
workflow_dispatch
-
Statement type: