Pre-commit configuration was out of date compared with other CPG repositories
Proposed Changes
drops isort in favour of the ruff implementation of isort
upgrades black
adds a CPG-ID checking pre-commit hook
much longer permitted line length
Then... a massive number of line changes relating to that file change
loads of multiline statements fit onto a single longer line (this is the reason for ~1000 'deleted lines')
Datetimes all over the codebase have a timezone enforced (all tzs are Australia/Brisbane - this is just to please the linter, naive dates would also be fine for this purpose)
logging.X statements using a configured root logger are instead processed through the reanalysis.static_values.get_logger logging instance, so we don't unintentionally intermingle logging calls from imported libraries along with our application logging.
Checklist
[x] Linting checks pass
Consequences
This goes against supporting forks of this repository and making sync changes easier... At the expense of hopefully making future syncs easier. This repository should move to versioned releases, with this pre-commit/code reformatting serving as a more stable platform. i.e. this should be the final development of the code-style in this repo for the foreseeable future.
Fixes
Proposed Changes
isort
in favour of the ruff implementation ofisort
Then... a massive number of line changes relating to that file change
logging.X
statements using a configured root logger are instead processed through thereanalysis.static_values.get_logger
logging instance, so we don't unintentionally intermingle logging calls from imported libraries along with our application logging.Checklist
Consequences
This goes against supporting forks of this repository and making sync changes easier... At the expense of hopefully making future syncs easier. This repository should move to versioned releases, with this pre-commit/code reformatting serving as a more stable platform. i.e. this should be the final development of the code-style in this repo for the foreseeable future.