fangohr / octopus-in-spack

Develop Octopus in spack (software packaging)
BSD 3-Clause "New" or "Revised" License
3 stars 4 forks source link

Try to add style ci #85

Closed iamashwin99 closed 1 year ago

iamashwin99 commented 1 year ago

Taking inspiration form style checks performed at https://gitlab.gwdg.de/mpsd-cs/mpsd-hpc-tools, this MR tries to implement style checks using isort, and black using the standard values accepted in spack upstream.

using details menationed in https://github.com/spack/spack/blob/75bf6d665c7a7fe14cd6a0c8e4e3f72457556edb/lib/spack/spack/cmd/style.py and lining configurations present in https://github.com/spack/spack/blob/develop/pyproject.toml

iamashwin99 commented 1 year ago

CI for 9604c92 shows that the current package needs style changes, testing with upstream

iamashwin99 commented 1 year ago

If you like the changes @fangohr I will remove the commits to update the package.py and reenable the other CIs before we can merge

fangohr commented 1 year ago

Undecided: I think it is mostly a good idea. A problem is that we need to update the style definitions if they change upstream (in spack). But perhaps that's better than having the wrong spack style before we submit merge requests upstream to spack/spack. Having a separate workflow is good: it helps us identify what is wrong. (And I got the style wrong before, so the check is useful.)

So yes, I'd be happy to include that. (Once the package changes are undone.)