Skip to content

Python template: select services by dk.itkdev.language=python - #155

Merged
turegjorup merged 4 commits into
developfrom
feature/python-language-label
Oct 5, 2026
Merged

turegjorup merged 4 commits into
developfrom
feature/python-language-label

Conversation

@turegjorup

Copy link
Copy Markdown
Contributor

The Python template's lint and tests workflows find their services by the label dk.itkdev.language: python instead of dk.itkdev.python: "true".

Changes

  • templates/python/.github/workflows/lint.yml and tests.yml: the header comment, the jq selection (labels["dk.itkdev.language"] == "python") and the error when no service has the label
  • templates/python/docker-compose.yml: the label on app
  • templates/python/.github/workflows/README.md: the label, and what it means

Why

  • One key for every language: a PHP or Node template can select its services with dk.itkdev.language: php and the same lookup, instead of a new boolean label per language.
  • It names the language whose checks run in the service, not how the service runs. That is a separate question (php-fpm or FrankenPHP, uvicorn or a CLI); a dk.itkdev.runtime label can answer it once a template or tool needs it.
  • No quoting trap: Compose labels must be strings, so an unquoted dk.itkdev.python: true is rejected; python needs no quotes.

Breaking for projects that already use the label. A code search across itk-dev, itk-devops and aarhusai finds only this template; itk-devops/itk-server-harvest#32 switches with this PR. PYTHON_SERVICES is unchanged.

@turegjorup turegjorup self-assigned this Oct 5, 2026
@turegjorup
turegjorup requested a review from cableman October 5, 2026 11:58
@turegjorup
turegjorup merged commit aef8b21 into develop Oct 5, 2026
40 checks passed
@turegjorup
turegjorup deleted the feature/python-language-label branch October 5, 2026 12:06
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