Skip to content

Conversation

@petrasvestartas
Copy link
Collaborator

@petrasvestartas petrasvestartas commented Sep 1, 2025

3rd-party requirements to pyproject.toml: #36

Change: Moved from setuptools.dynamic with requirements.txt to PEP 621 native dependencies and dependency groups (PEP 735) based on this discussion: scikit-build/scikit-build-core#1098

Why:

  • More modern, standards-compliant metadata (works without setuptools).
  • Dependencies are now declarative in pyproject.toml rather than spread across multiple files.
  • Groups (dev, tests, docs) replace optional-dependencies, making environments easier to reproduce with modern tools like uv or pip-tools.

Before:

dynamic = ['dependencies', 'optional-dependencies', 'version']



[tool.setuptools.dynamic]
dependencies = { file = "requirements.txt" }
optional-dependencies = { dev = { file = "requirements-dev.txt" } }

After:

dynamic = ['version']
dependencies = [
    "compas >=2.0.0",
    "tessagon",
]

[dependency-groups]
dev = [
    "ruff",
    "pre-commit",
    "build",
    { include-group = "tests" },
    { include-group = "docs" },
]
tests = [
    "pytest",
    "numpy",
]
docs = [
    "sphinx",
    "sphinx-compas-theme",
]

@petrasvestartas petrasvestartas changed the title CHANGE requirements. CHANGE requirements, tessagon. Sep 1, 2025
@petrasvestartas petrasvestartas changed the title CHANGE requirements, tessagon. Bug: pip wheel has no metadata about tessagon. Sep 1, 2025
@tomvanmele
Copy link
Member

if this now solves the problem, is it something we should do everywhere?

@petrasvestartas
Copy link
Collaborator Author

@tomvanmele We need to check this, but it is hard to know 100% percent until it is released in pip.

This is the recommendation from scikit developers.

@tomvanmele tomvanmele merged commit 35abea3 into compas-dev:main Sep 3, 2025
9 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.

2 participants