Skip to content

TYP: fix typing errors for mypy==0.790, bump mypy version #37108

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

Merged
merged 13 commits into from
Jan 10, 2021

Conversation

fangchenli
Copy link
Member

@fangchenli fangchenli commented Oct 13, 2020

Sorry, something went wrong.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
@jreback
Copy link
Contributor

jreback commented Oct 14, 2020

cc @simonjayhawkins

@jreback jreback added the Typing type annotations, mypy/pyright type checking label Oct 14, 2020
@jreback jreback added this to the 1.2 milestone Oct 14, 2020
Copy link
Member

@simonjayhawkins simonjayhawkins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @fangchenli for the PR. generally lgtm.

@pep8speaks
Copy link

pep8speaks commented Oct 15, 2020

Hello @fangchenli! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2021-01-10 03:12:54 UTC

@@ -179,7 +179,8 @@ def stringify_path(
# this function with convert_file_like=True to infer the compression.
return cast(FileOrBuffer[AnyStr], filepath_or_buffer)

if isinstance(filepath_or_buffer, os.PathLike):
# Only @runtime_checkable protocols can be used with instance and class checks
if isinstance(filepath_or_buffer, os.PathLike): # type: ignore[misc]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

# Unsupported operand types for + ("List[Optional[str]]" and "List[str]")
valid = ["infer", None] + sorted(
_compression_to_extension
) # type: ignore[operator]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

@simonjayhawkins simonjayhawkins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @fangchenli lgtm pending green

Copy link
Member

@simonjayhawkins simonjayhawkins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we also added the whatnew dependencies on the last bump

@jreback jreback modified the milestones: 1.2, 1.3 Jan 9, 2021
@jreback
Copy link
Contributor

jreback commented Jan 9, 2021

looks ok to me, merge master just to confirm.

@simonjayhawkins simonjayhawkins merged commit 51b04e0 into pandas-dev:master Jan 10, 2021
@simonjayhawkins
Copy link
Member

Thanks @fangchenli

@simonjayhawkins
Copy link
Member

simonjayhawkins commented Jan 10, 2021

merge master just to confirm.

np-dev failures seen on other PRs/master

@fangchenli fangchenli deleted the typing-errors branch January 10, 2021 15:29
luckyvs1 pushed a commit to luckyvs1/pandas that referenced this pull request Jan 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Typing type annotations, mypy/pyright type checking
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TYP: typing errors for mypy==0.790
4 participants