Skip to content

Fix type annotations in pandas.tseries.* #26013

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

Closed
gwrome opened this issue Apr 6, 2019 · 0 comments · Fixed by #26014
Closed

Fix type annotations in pandas.tseries.* #26013

gwrome opened this issue Apr 6, 2019 · 0 comments · Fixed by #26014
Labels
Typing type annotations, mypy/pyright type checking
Milestone

Comments

@gwrome
Copy link
Contributor

gwrome commented Apr 6, 2019

Part of #25882

pandas.tseries files currently have these errors:

pandas/tseries/frequencies.py:40: error: Need type annotation for '_offset_map'

pandas/tseries/holiday.py:332: error: Need type annotation for 'rules'

pandas/tseries/offsets.py:1656: error: Incompatible types in assignment (expression has type "int", base class "QuarterOffset" defined the type as "None")
pandas/tseries/offsets.py:1657: error: Incompatible types in assignment (expression has type "int", base class "QuarterOffset" defined the type as "None")
pandas/tseries/offsets.py:1666: error: Incompatible types in assignment (expression has type "int", base class "QuarterOffset" defined the type as "None")
pandas/tseries/offsets.py:1667: error: Incompatible types in assignment (expression has type "int", base class "QuarterOffset" defined the type as "None")
pandas/tseries/offsets.py:1681: error: Incompatible types in assignment (expression has type "int", base class "QuarterOffset" defined the type as "None")
pandas/tseries/offsets.py:1688: error: Incompatible types in assignment (expression has type "int", base class "QuarterOffset" defined the type as "None")
pandas/tseries/offsets.py:1689: error: Incompatible types in assignment (expression has type "int", base class "QuarterOffset" defined the type as "None")

I have added annotations to address these issues and removed the modules from mypy.ini. PR to follow presently.

@jreback jreback added the Typing type annotations, mypy/pyright type checking label Apr 6, 2019
@jreback jreback added this to the 0.25.0 milestone Apr 6, 2019
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 a pull request may close this issue.

2 participants