-
-
Notifications
You must be signed in to change notification settings - Fork 5
Added mypy to this repo. #16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Codecov Report
@@ Coverage Diff @@
## main #16 +/- ##
=======================================
+ Coverage 91.6% 92.8% +1.1%
=======================================
Files 3 3
Lines 24 28 +4
=======================================
+ Hits 22 26 +4
Misses 2 2
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
|
Hm. I can have a look at that later. Could you, first, merge #15 and rebase this PR on it, so that this PR really only contains changes related to the PR? Makes it easier to check. A few things as a heads-up. DDSIM is not yet typed. So it definitely needs to be excluded somehow. |
|
You will also have to move the |
Done. Also added the CI workflow. |
You still need to skip the mypy check in the ci (see the pre-commit Config of the predictor). Otherwise it is run twice. |
Oh, my bad. I fixed both issues. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Many thanks for adding mypy here. I just have a couple of really small comments.
Feel free to ignore them and merge as is.
Getting mypy to stop complaining was easier than I thought originally. I just replaced
from mqt import dddim with from mqt.ddsim import <...>. That way the configuration from the pyproject.toml takes effect.
I suspect the original error is due to DDSIM not yet being typed and thus not getting installed as part of the mypy check.
I still get an error for the `mqt.ddsim` import and do not really
understand why it is there, since `mqt.ddsim` is both listed as an
additional dependency in the `pre-commit-config.yaml` and also excluded
in the `pyproject.toml`. I would have assumed, that either of those two
options should resolve the problem:
```
error: Module "mqt" has no attribute "ddsim"
[attr-defined]
from mqt import ddsim
```
---------
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Lukas Burgholzer <lukas.burgholzer@jku.at>
…/setup-python-5 Bump actions/setup-python from 4 to 5
I still get an error for the
mqt.ddsimimport and do not really understand why it is there, sincemqt.ddsimis both listed as an additional dependency in thepre-commit-config.yamland also excluded in thepyproject.toml. I would have assumed, that either of those two options should resolve the problem: