Skip to content

openpyxl: add a few type annotations#9681

Closed
parched wants to merge 2 commits into
python:mainfrom
parched:openpyxl
Closed

openpyxl: add a few type annotations#9681
parched wants to merge 2 commits into
python:mainfrom
parched:openpyxl

Conversation

@parched
Copy link
Copy Markdown

@parched parched commented Feb 6, 2023

I've just added a few of the type annotations I specifically needed, but will add some more at a later date.

@parched
Copy link
Copy Markdown
Author

parched commented Feb 6, 2023

Just spotted #9487 and #9511, closing in favour of them.

@parched parched closed this Feb 6, 2023
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 6, 2023

Diff from mypy_primer, showing the effect of this PR on open source code:

pandas (https://github.com/pandas-dev/pandas)
+ pandas/io/excel/_openpyxl.py:73: error: Argument 1 to "load_workbook" has incompatible type "IO[bytes]"; expected "Union[str, Path, BinaryIO]"  [arg-type]
+ pandas/io/excel/_openpyxl.py:554: error: Argument 1 to "load_workbook" has incompatible type "Union[Union[str, PathLike[str]], ReadBuffer[bytes]]"; expected "Union[str, Path, BinaryIO]"  [arg-type]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant