PythonBiellaGroup / Bear

Python Biella Group basic template for a modern generic python application
https://pythonbiellagroup.it
MIT License
12 stars 4 forks source link

New version of Bear #7

Open JeyDi opened 1 year ago

JeyDi commented 1 year ago

We have to work on the new version of Bear with new components:

And also adding some github pipelines to:

baggiponte commented 1 year ago

AHAHAHAH I got you with Just

I can work on just (imho you can copy paste the justfile from chef, and I can work on replacing bandit isort etc with ruff, pip-audit.

I was using deptry too but eventually dropped it; might look into that again.

I wanted to make a package out of chef too - the guy who developed deptry actually did so

JeyDi commented 1 year ago

ahaha Just I really want to use it!!! So we will have a proper modern Makefile cross platform!

Deptry it's just an Idea, probably we can have something in Just commands, Makefile and pre-commit only

The idea to have a package it's really interesting in fact!

Also we need to update the docker image.

I have one question @baggiponte : how can we support multiple python version (for example python 3.9, 3.10, 3.11)? And also have cross python automated tests?

baggiponte commented 1 year ago

ahaha Just I really want to use it!!! So we will have a proper modern Makefile cross platform!

just is awesome, I cannot imagine my development without it. scripts managed by pdm/poetry work but right now they are not as capable as just.

Deptry it's just an Idea

I recently brought it back into my templates not as a precommit hook but as a step in just. basically I have a just release command that also runs a bunch of checks like pip audit and deptry fits nicely. At first I was running deptry from pre-commit (rather than via pdm) and it was weird. Now I am running all precommit hooks through pdm so it might make sense to have it run as a pre-commit hook to ensure dependencies are well-specified.

how can we support multiple python version (for example python 3.9, 3.10, 3.11)? And also have cross python automated tests?

Never done that, but I guess you should specify in your pyproject.toml the smallest version and stick to that when developing; then run tests via github actions using a matrix with all the versions you are interested in supporting (see how fastapi does it). Or you can also try tox, but I never used it.

JeyDi commented 1 year ago

With the new version of the project we have integrated:

There are few things missing: