OceanParcels / Parcels

Main code for Parcels (Probably A Really Computationally Efficient Lagrangian Simulator)
https://www.oceanparcels.org
MIT License
294 stars 135 forks source link

Enable pyupgrade, add Grid repr, and other changes #1680

Closed VeckoTheGecko closed 1 month ago

VeckoTheGecko commented 2 months ago

related to #1620 and #1693

Breaking changes

codecov[bot] commented 2 months ago

Codecov Report

Attention: Patch coverage is 16.66667% with 55 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
parcels/compilation/codegenerator.py 0.00% 16 Missing :warning:
parcels/kernel.py 0.00% 10 Missing :warning:
parcels/grid.py 0.00% 6 Missing :warning:
parcels/tools/converters.py 0.00% 5 Missing :warning:
parcels/fieldset.py 0.00% 4 Missing :warning:
parcels/field.py 57.14% 2 Missing and 1 partial :warning:
parcels/particle.py 25.00% 3 Missing :warning:
parcels/particlefile.py 0.00% 2 Missing :warning:
parcels/compilation/codecompiler.py 0.00% 1 Missing :warning:
parcels/interaction/interactionkernel.py 0.00% 1 Missing :warning:
... and 4 more

:exclamation: There is a different number of reports uploaded between BASE (3a7494d) and HEAD (0296e1c). Click for more details.

HEAD has 7 uploads less than BASE | Flag | BASE (3a7494d) | HEAD (0296e1c) | |------|------|------| |unit-tests|4|0| |integration-tests|3|0|
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #1680 +/- ## =========================================== - Coverage 81.18% 15.82% -65.36% =========================================== Files 72 43 -29 Lines 13256 7872 -5384 Branches 127 129 +2 =========================================== - Hits 10762 1246 -9516 - Misses 2457 6497 +4040 - Partials 37 129 +92 ``` | [Flag](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels) | Coverage Δ | | |---|---|---| | [integration-tests](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels) | `?` | | | [mypy](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels) | `15.82% <16.66%> (+0.17%)` | :arrow_up: | | [unit-tests](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels) | `?` | | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#carryforward-flags-in-the-pull-request-comment) to find out more. | [Files with missing lines](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels) | Coverage Δ | | |---|---|---| | [parcels/\_typing.py](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree&filepath=parcels%2F_typing.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#diff-cGFyY2Vscy9fdHlwaW5nLnB5) | `96.66% <100.00%> (-3.34%)` | :arrow_down: | | [parcels/tools/\_helpers.py](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree&filepath=parcels%2Ftools%2F_helpers.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#diff-cGFyY2Vscy90b29scy9faGVscGVycy5weQ==) | `55.00% <100.00%> (-40.00%)` | :arrow_down: | | [parcels/tools/exampledata\_utils.py](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree&filepath=parcels%2Ftools%2Fexampledata_utils.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#diff-cGFyY2Vscy90b29scy9leGFtcGxlZGF0YV91dGlscy5weQ==) | `88.50% <100.00%> (-11.50%)` | :arrow_down: | | [parcels/tools/interpolation\_utils.py](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree&filepath=parcels%2Ftools%2Finterpolation_utils.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#diff-cGFyY2Vscy90b29scy9pbnRlcnBvbGF0aW9uX3V0aWxzLnB5) | `77.34% <100.00%> (-14.00%)` | :arrow_down: | | [parcels/compilation/codecompiler.py](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree&filepath=parcels%2Fcompilation%2Fcodecompiler.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#diff-cGFyY2Vscy9jb21waWxhdGlvbi9jb2RlY29tcGlsZXIucHk=) | `6.83% <0.00%> (-84.60%)` | :arrow_down: | | [parcels/interaction/interactionkernel.py](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree&filepath=parcels%2Finteraction%2Finteractionkernel.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#diff-cGFyY2Vscy9pbnRlcmFjdGlvbi9pbnRlcmFjdGlvbmtlcm5lbC5weQ==) | `21.21% <0.00%> (-55.80%)` | :arrow_down: | | [parcels/particleset.py](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree&filepath=parcels%2Fparticleset.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#diff-cGFyY2Vscy9wYXJ0aWNsZXNldC5weQ==) | `6.37% <0.00%> (-60.57%)` | :arrow_down: | | [parcels/rng.py](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree&filepath=parcels%2Frng.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#diff-cGFyY2Vscy9ybmcucHk=) | `21.48% <0.00%> (-70.32%)` | :arrow_down: | | [parcels/tools/global\_statics.py](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree&filepath=parcels%2Ftools%2Fglobal_statics.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#diff-cGFyY2Vscy90b29scy9nbG9iYWxfc3RhdGljcy5weQ==) | `31.81% <0.00%> (-51.52%)` | :arrow_down: | | [parcels/tools/timer.py](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree&filepath=parcels%2Ftools%2Ftimer.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels#diff-cGFyY2Vscy90b29scy90aW1lci5weQ==) | `8.92% <0.00%> (-75.00%)` | :arrow_down: | | ... and [8 more](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels) | | ... and [48 files with indirect coverage changes](https://app.codecov.io/gh/OceanParcels/Parcels/pull/1680/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=OceanParcels)