-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
MNT: deprecate epoch2num/num2epoch #19483
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
ae9d651
to
b9ec4c8
Compare
I'm conflicted about |
I'll ping for this simple one... |
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.
What's the first relase of pandas that does not depend on this? I think we need to give it "some time" to settle.
I'm fine with deprecation the julian functions. I consider them a is too specifc and not part of the core functionality that we want to provide. The few potential users of this should be able to copy the code or get the conversion from somewhere else.
@@ -1081,18 +1081,6 @@ def test_change_interval_multiples(): | |||
assert ax.get_xticklabels()[1].get_text() == 'Feb 01 2020' | |||
|
|||
|
|||
def test_epoch2num(): |
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.
I think we leave tests for deprecated features in place and run them with _api.suppress_matplotlib_deprecation_warning():
.
It was merged almost a year ago: pandas-dev/pandas#35393 milestoned 1.1, released Jul 28, 2020. They are currently on 1.2.4. I would guess that if someone updates Matplotlib they would also update pandas? Worse that happens is someone gets a deprecation warning for a while if they use a new Matplotlib and an old pandas. |
That's ok then. |
cddc143
to
6c1a79d
Compare
6c1a79d
to
669e1cc
Compare
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.
Modulo one comment
8281391
to
132a9a5
Compare
PR Summary
epoch2num
andnum2epoch
convert to and from matplotlib times from unix times.We do not use these functions anywhere internally, and their functionality is provided by
datetime
ordatetime64
modules. There is really no reason for users to be converting directly from unix times to Matplotlib times.This was deprecated before when we made the epoch change, but that broke pandas who were using this. They no longer are using this, so I think it is safe to deprecate for 3.5.
PR Checklist
pytest
passes).flake8
on changed files to check).flake8-docstrings
and runflake8 --docstring-convention=all
).doc/users/next_whats_new/
(follow instructions in README.rst there).doc/api/next_api_changes/
(follow instructions in README.rst there).