pyproject.toml: [tool.setuptools_scm] is inert — maturin takes the version from Cargo.toml
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 2/5
- Tempo estimado
- 1-3 horas
- Facilidade para iniciantes
- 45/100
- Tipo de issue
- Refatoração
- Clareza
- Razoavelmente clara
- Status de atividade
- Pouca atividade
- Domínio
- build-system, release
Direção de pesquisa
The inert section is [tool.setuptools_scm] near line 110 of pyproject.toml, while dynamic = ["version"] on line 7 is resolved by maturin from rust/Cargo.toml. Confirm that by building a wheel and checking its version against Cargo.toml. Done means the maintainers have picked an option: either remove the section so Cargo.toml is clearly the single source, or make SCM actually drive the version. Optionally add a tag-vs-version check to the publish workflow. The issue has no comments yet, so pick the direction with a maintainer first.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Third one from modelling ddx's packaging on this repo (after #242 and #243) — this one I checked empirically rather than by reading, because I was about to copy the pattern.
pyproject.toml declares SCM versioning:
[project]
dynamic = ["version"] # L7
...
[tool.setuptools_scm] # L110
but setuptools-scm is never installed at build time:
[build-system]
requires = ["maturin>=1.9,<2.0"]
build-backend = "maturin"
and maturin is the backend, not setuptools — it does not consult setuptools-scm at all. For dynamic = ["version"], maturin takes the version from Cargo.toml.
How I checked
I put the identical configuration on ddx's own maturin package — dynamic = ["version"], [tool.setuptools_scm], and (unlike here) setuptools-scm actually present in build-system.requires — in a repo with no matching git tag at all. SCM versioning would have had to produce a 0.1.x.dev...+g<sha> string. The build produced:
📦 Built wheel ... ddxdb-0.1.0-cp310-abi3-macosx_11_0_arm64.whl
0.1.0 is exactly the Cargo.toml version. Git was never consulted.
So [tool.setuptools_scm] here is inert configuration: the published version is whatever rust/Cargo.toml says, and the section reads as though tags drive it. That is harmless today but misleading — someone bumping a tag and expecting the wheel to follow would be surprised, and the failure is silent.
Options
- Drop
[tool.setuptools_scm]and treatrust/Cargo.tomlas the single source, which is what already happens. Optionally assert tag-vs-version in the publish workflow so a mismatched tag fails the release rather than shipping. - Actually use SCM, which means not using maturin's version handling — e.g. generate the version in CI and pass
--version/ rewriteCargo.tomlbefore building. More machinery than it is likely worth.
I went with (1) plus a tag check in ddx. Happy to send a PR here if useful.
- Linguagem predominante
- Python
- Estrelas
- 142
- Forks
- 19
- Merge médio
- 1d 6h
- PRs com merge (30d)
- 10
Preparar o ambiente
- Sem Dockerfile nem arquivo Docker Compose
- Sem modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de xqlsystems/xarray-sql
-
documentation
Dificuldade 1/5 1-3 horas Facilidade para iniciantes 85/100
xqlsystems/xarray-sql#268 ·
Mantenedores costumam responder em até 1 dia
-
enhancement
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 64/100
xqlsystems/xarray-sql#267 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 74/100
xqlsystems/xarray-sql#243 ·
Mantenedores costumam responder em até 1 dia
-
publish.yml: the TestPyPI verification step is unreachable (and installs the wrong package name)Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 62/100
xqlsystems/xarray-sql#242 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
xqlsystems/xarray-sql#237 ·
Mantenedores costumam responder em até 1 dia
Todas as issues de xqlsystems/xarray-sql
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 76/100
aws-samples/sample-per-model-bedrock#464 ·
Mantenedores costumam responder em até 1 dia
-
lesson-submission pending-review
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 67/100
Ikalus1988/MisakaNet#3789 ·
Mantenedores costumam responder em até 1 dia
-
Python Volcengine provider returns failures instead of raising themTalvez já em andamento @Ricardo-M-L assumiu hoje. Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 79/100
agent-infra/sandbox#248 ·
-
[Bug] cloud JSON directory loading assumes a Key field in fsspec listingsTalvez já em andamento @Ricardo-M-L assumiu hoje. Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 88/100
hiyouga/LlamaFactory#10910 ·
Mantenedores costumam responder em até 1 dia
-
Bundled uv is never updated and trusts the compromised eMudhra certificatesTalvez já em andamento @FabienDanieau assumiu hoje. Abertabug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 76/100