jodal / biip

📦 Biip interprets the data in barcodes.
https://biip.readthedocs.io
Apache License 2.0
46 stars 4 forks source link

pyright and related type fixes #186

Closed jodal closed 1 year ago

jodal commented 1 year ago

This PR sets up pyright in addition to mypy.

From that follows a number of type fixes, mostly in tests and helper scripts. Some old type ignores have been replaced by better solutions to make them work across mypy and pyright.

codecov[bot] commented 1 year ago

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (adcc922) 100.00% compared to head (b3b1385) 100.00%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #186 +/- ## ========================================= Coverage 100.00% 100.00% ========================================= Files 18 18 Lines 912 916 +4 Branches 146 146 ========================================= + Hits 912 916 +4 ``` | [Impacted Files](https://codecov.io/gh/jodal/biip/pull/186?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Stein+Magnus+Jodal) | Coverage Δ | | |---|---|---| | [src/biip/gtin/\_gtin.py](https://codecov.io/gh/jodal/biip/pull/186?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Stein+Magnus+Jodal#diff-c3JjL2JpaXAvZ3Rpbi9fZ3Rpbi5weQ==) | `100.00% <ø> (ø)` | | | [src/biip/\_\_init\_\_.py](https://codecov.io/gh/jodal/biip/pull/186?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Stein+Magnus+Jodal#diff-c3JjL2JpaXAvX19pbml0X18ucHk=) | `100.00% <100.00%> (ø)` | | | [src/biip/\_parser.py](https://codecov.io/gh/jodal/biip/pull/186?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Stein+Magnus+Jodal#diff-c3JjL2JpaXAvX3BhcnNlci5weQ==) | `100.00% <100.00%> (ø)` | | | [src/biip/gs1/\_element\_strings.py](https://codecov.io/gh/jodal/biip/pull/186?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Stein+Magnus+Jodal#diff-c3JjL2JpaXAvZ3MxL19lbGVtZW50X3N0cmluZ3MucHk=) | `100.00% <100.00%> (ø)` | | | [src/biip/gs1/\_messages.py](https://codecov.io/gh/jodal/biip/pull/186?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Stein+Magnus+Jodal#diff-c3JjL2JpaXAvZ3MxL19tZXNzYWdlcy5weQ==) | `100.00% <100.00%> (ø)` | | | [src/biip/gs1/\_prefixes.py](https://codecov.io/gh/jodal/biip/pull/186?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Stein+Magnus+Jodal#diff-c3JjL2JpaXAvZ3MxL19wcmVmaXhlcy5weQ==) | `100.00% <100.00%> (ø)` | | | [src/biip/gtin/\_rcn.py](https://codecov.io/gh/jodal/biip/pull/186?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Stein+Magnus+Jodal#diff-c3JjL2JpaXAvZ3Rpbi9fcmNuLnB5) | `100.00% <100.00%> (ø)` | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Stein+Magnus+Jodal). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Stein+Magnus+Jodal)

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.