DRAFT
Scope:
- Developing small or middle-size services in Python.
- Mixing PYPI and in-house dependencies
Restictions:
- No Plone yet, because of unsolved issues in generating Nix-expression, and issues with setuptools namespackages and wheels.
Issues working with Nixpkgs:
- Which nixpkgs to use
- nixpkgs is growing fast and stable is probably missing packages
- unstable updates may bring breakages
- How to mix stable with unstable with security patches
- e.g. fork release, rebase to next release, cherry-pick patches (but may cause world rebuild)
- Adding new packages
- add to fork, create pull request, get from upstream in the next release
Issues working with in-house packages
- Each package requires:
- expression to build the package (incl. tests)
- expression to build Docker image with the package
- shell expression for running tests for the package
- buildable interpreter expression with package requiremens for IDE
- The most "logical" place for the expressions are each package's repository, but
- that's different to nixpkgs
- makes composing expressions harder
- Apparently it's possible also to package's default.nix with traditional python sdist release and require it in Nix expression via import fetchTarball. Would you see any downsides with this approach?
- Other issues with in-house packages
- double work in defining both python and nix packaging
- maybe one JSON where all data flows to default.nix and setup.py
- updating versions in both places
- extra work in making python package releases to in-house package respository, even Nix could build from version control
- double work in defining both python and nix packaging
Misc issues
- How to package apps with plugins?
- Let A be the main app. A includes the CLI script.
- Let B and C be add-ons for A. They require A.
- Building either B or C includes A, but don't install CLI script.
- Building A installs CLI script, but A cannot have B or C as its inputs.
- So, how to package A with B and C without python.buildEnv?
- Using Nixpkgs best practices
- Creating Python packages best practices
- setup.py
- tests
- default.nix
- packaging dist
- Makefile
- Managing local Nix package tree
- Running local hydra