simpeg / discretize

Discretization tools for finite volume and inverse problems.
http://discretize.simpeg.xyz/
MIT License
163 stars 33 forks source link

Use any Python 3 in pre-commit #328

Closed santisoler closed 1 year ago

santisoler commented 1 year ago

Unpin Python 3.10 in pre-commit configuration and use any available Python 3 interpreter. This fixes issues when the Python version in the environment is not 3.10.

santisoler commented 1 year ago

@jcapriot I run into some errors today because the environment I had for discretize wasn't running python 3.10, and pre-commit wasn't throwing some errors when trying to create the virtual environments. Since we are pinning the black and flake8 versions, the python version shouldn't be so important.

If you think otherwise, then I suggest pinning a python version in the environment_test.yml.

codecov[bot] commented 1 year ago

Codecov Report

Merging #328 (17c23f0) into main (e14e13e) will not change coverage. The diff coverage is n/a.

@@           Coverage Diff           @@
##             main     #328   +/-   ##
=======================================
  Coverage   85.16%   85.16%           
=======================================
  Files          38       38           
  Lines       11538    11538           
=======================================
  Hits         9826     9826           
  Misses       1712     1712           
jcapriot commented 1 year ago

Yeah, this should be fine. I know I was having issues getting pre-commit to run properly on windows on anything less than 3.10