I’ve noticed that a lot of my projects follow the same basic architecture and I often like to write some simple tools for myself where it takes much longer to set up the project than it does to write the domain specific code. So I’ve been looking into scaffolding tools to help with this. I’m aware of Cookiecutter and Copier. Are there others? How do they compare? What are your preferences and why?
I tried getting used to cookiecutter with one of the well-known Python project templates several times, but I always found that those are way too much boilerplate for my simple needs.
So I stick with copying and modifying my previous project every time, and even that doesn’t make things much easier because I always find something I should do different next time, so in the end no project is completely like its predecessor.
Let us know what you’ll come up with!
I’m just playing around with Copier for now. An arbitrary choice since I have nothing to go on and it seems popular enough. It’ll probably be a while before I develop my own opinions on it.
I agree with existing templates having too much boilerplate. I’m basically also just copying and modifying my previous projects, but automated with Copier so that I don’t have to search and replace all the project/module names. For this particular task, I have no complaints so far.
deleted by creator
Package DevOPs is a skill. Half assing it will not:
-
impress a published package author’s peers
-
encourage confidence in the authors perseverance to maintain the package
-
encourage confidence in the author’s willingness to politely respond to Issues and PRs
-
package will have issues that never get resolved cuz the author packaging skillset is woefully lacking including but not limited to: Makefile, pre-commit, tox, gha, doctest, documentation, test coverage, multiple platform support, manylinux support, setup for collaboration, and static typing.
So suggest redirecting efforts towards studying how to improve packaging rather than how to avoid packaging.
A suggestion on things to improve documentation:
move the doctest out of in-code documentation and into test suite! So the doctest are proof and contribute to coverage
python -m coverage run --parallel --data-file=.coverage-combine-tests -m pytest --doctest-glob="*.rst" --showlocals $(verbose_text) tests/safe tests/a tests/bThis is straight from a
Makefile. Where the file extension for doctest was changed to.rst. Can see have A B testing setup to compare two packages.Example how to include doctest into Sphinx document
.. literalinclude:: ../tests/a/test_presentation.rst :language: pycon :name: unique-id :caption: illustrative-descriptionWas this meant for a different thread?
On this board, and hope everyone else is, to learn and share. Try to contribute, not just state my opinion.
Didn’t feel this thread offered anything substantial to learn, so threw out some gem that others might find useful in their projects.
-
test comment


