Contributions are welcome for JupyterHub wiring, spawner behavior, tests, and documentation. Keep the repository thin. Core infrastructure, suite management, and environment resolution belong in the rest of the Gradient Linux stack.
Read README.md and docs/README.md before changing the JupyterHub contract or the spawner behavior.
Use Ubuntu 24.04 with Python 3.11 or newer.
git clone <repo-url>
cd gradient-lab
python3 -m venv .venv
. .venv/bin/activate
pip install -e ".[test]"
npm install --prefix extension
python3 -m unittest discover -s tests -p 'test_*.py' -v
npm testIf you need to work on the frontend extension, install Node.js 20 or newer. The canonical browser package lives in extension/.
Use one of these branch prefixes:
feat/<slug>fix/<slug>docs/<slug>
Format commits as <type>(<scope>): <summary>.
Use these types:
featfixrefactortestdocschore
Keep the summary under 72 characters.
Examples:
feat(spawner): attach gradient quota environmentfix(config): preserve notebook directory templatedocs(readme): clarify source-only install path
- Add or update tests for any new function or behavior change.
- Run
python3 -m unittest discover -s tests -p 'test_*.py' -vbefore opening a pull request. - Run
npm testafter changing the JupyterLab extension package. - Keep subprocess calls isolated and easy to replace in tests.
- Keep pull requests focused and limited to one logical change.
- Explain the effect on JupyterHub startup, spawn flow, or
concaveintegration. - Include manual validation steps when changes touch live JupyterHub behavior.
- Keep
gradient-labas a thin wrapper around upstream JupyterHub. - Do not fork JupyterHub behavior into large local subsystems.
- Preserve
~/gradient/notebooks/{username}as the notebook root template unless there is a documented migration plan. - Keep calls into
concaveexplicit and easy to mock. - Use separate command arguments instead of shell interpolation.
- Dependencies added without prior discussion in an issue.
- Environment resolver logic copied into this repository.
- Quota policy duplicated here instead of being read from
concave. - Shell string interpolation with user-controlled input.
By contributing, you agree that your contributions will be released under the repository license when one is published.