primap-community / primap2

The next generation of the PRIMAP climate policy analysis suite
https://primap2.readthedocs.io
Apache License 2.0
9 stars 2 forks source link

fully type everything and add py.typed marker #189

Open mikapfl opened 11 months ago

mikapfl commented 11 months ago

Is your feature request related to a problem? Please describe.

If you import primap2 in a file and check the file with mypy, you get an error:

app.py:1: error: Skipping analyzing "primap2": module is installed, but missing library stubs or py.typed marker  [import]

That's of course stupid because primap2 is in fact typed, we just haven't added the correct marker to tell the world about it.

Describe the solution you'd like

Add the py.typed marker file.

Additional context

I'm unfortunately not sure what will happen with the xarray accessor and if typing works on it. May have to investigate.

mikapfl commented 8 months ago

Actually, we are not mypy-clean, so we need to put the work in to fix all remaining mypy issues before we can add the py.typed marker.