pymagicc icon indicating copy to clipboard operation
pymagicc copied to clipboard

Discussion: tidy up post 2.1.0

Open znicholls opened this issue 6 years ago • 3 comments

So I think for 2.1.0 we should aim to:

  • [ ] integrate with openscm
  • [ ] use of some variant of pyam dataframe

Then I think we should focus on refactoring things, in particular:

  • [ ] split the MAGICCBase.run function into a number of smaller functions to make it easier to add new MAGICC7 features in future (e.g. the stderr handling is now a mess of if statements, which it needn't be)
  • [ ] get code coverage up to > 95%
  • [ ] tidying up docs
  • [ ] re-write any untidy code
  • [ ] split the tests into unit and integration so it becomes easier to see what's going on and develop in future
  • [ ] mark slow tests using pytest.mark.slow properly so if you do pytest --skip-slow the test suite runs in under 10s

znicholls avatar Oct 21 '18 17:10 znicholls

Totally agree ...!

I'd consider renaming pymagicc.api to pymagicc.core

And exposing the MAGICC6 and MAGICC7 classes in the main __init__.py:

import pymagicc
from pymagicc import MAGICC6

rgieseke avatar Oct 25 '18 06:10 rgieseke

yes but if we break that API (i.e. rename pymagicc.api to pymagicc.core) then we should really bump to 3.0 if we're going to follow semantic versioning properly. Plan b is we change it before the release?

znicholls avatar Oct 25 '18 10:10 znicholls

Both possible, just wanted to note down the idea. We can also provide an alias and deprecation warning but that's probably overkill given we have hardly any users (and need to fix the MAGICC7 pipeline ourselves).

rgieseke avatar Oct 25 '18 12:10 rgieseke