learningequality / learningequality/studio
Migrate to uv.lock, prek, and ruff
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 191
- Forks
- 307
- Avg merge
- 5d 6h
- Merged PRs (30d)
- 10
Description
❌ This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.
Overview
Migrate from pip/setup.cfg to uv tooling, and replace flake8/black with ruff
Complexity: Low
Target branch: unstable
Context
Kolibri Studio was previously migrated to uv, but only a partial migration. Currently, Studio still uses compiled requirements files using uv pip compile. We'd like to fully transition Studio to uv and its uv.lock tracking for dependencies.
The Change
- Convert
setup.cfgand comiledrequirements.txtandrequirements-dev.txttopyproject.tomlwith PEP 735 dependency groups - Replace flake8/black/reorder-python-imports with ruff
- Replace pre-commit with prek
- Add yamlfmt and actionlint to pre-commit hooks
- Update
pre-commitCI workflow for prek replacement - Configure
exclude-newer = "7 days"in[tool.uv]for supply chain safety - Add
uv-lockpre-commit hook (fromastral-sh/uv-pre-commit) to keepuv.lockin sync - Update developer documentation
Acceptance Criteria
-
pyproject.tomlreplacessetup.cfgas the single source of project metadata and configuration -
uv.lockreplacesrequirements*.inandrequirements*.txt - Linting and formatting handled by ruff
- Pre-commit hooks use prek with ruff, yamlfmt, and actionlint
-
exclude-newercooldown configured in pyproject.toml -
uv-lockpre-commit hook added to.pre-commit-config.yaml - All existing tests pass
- Developer documentation updated
References
- https://github.com/learningequality/kolibri/pull/14457 — Kolibri uv migration
AI usage
This issue is a revised copy of another issue drafted by Claude Code, based on the Kolibri uv migration work.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing setup.cfg, the compiled requirements files, pyproject.toml, and .pre-commit-config.yaml, then compare the referenced Kolibri migration. Check the pre-commit CI workflow and developer documentation as part of the migration. Done means the listed configuration files and hooks are replaced, uv.lock is tracked, documentation is updated, and all existing tests pass.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- build-system, ci-cd, documentation, tooling
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100