BUG: no longer raise user warning when plotting tz aware time series
State: closed

- [x] closes #31205
- [x] tests added / passed
- [x] passes `black pandas`
- [x] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [x] whatsnew entry


Labels:
name: Visualization
description: plotting
name: Timezones
description: Timezone data dtype

Comments:
@MarcoGorelli tiny nitpicky workflow comment: can you use "BUG:" instead of "[BUG]" for PR titles? (just for consistency, that's how the majority of PRs do it)
> likely this was introduced in master and is not apparent on 0.25.3 ? if so we don't need a whatsnew note (@jorisvandenbossche )

It seems this is already happening in released pandas as well (checked 0.25.3)
Can confirm this was already happening in 0.25.3. So, the whatsnew note is still needed?
Yes, a release note will be needed if it's fixing something present in 0.25.3.

Are we backporting this to 1.0.0?
@TomAugspurger sure, whatsnew entry added
@MarcoGorelli can you merge master to fix the CI failure?

If this is fixing a bug that was present in 0.25, then I think we should target 1.0.1 instead.
@TomAugspurger 
> I think we should target 1.0.1 instead.

Sure, I'll wait for the PR which creates that file to be merged
@TomAugspurger merged, whatsnew v1.0.1 note added
@MarcoGorelli workflow related question: can you only push new commits? (instead of squashing/rebasing and force pushing) That makes it easier to see what changed in the GitHub interface
It's not critical to backport this to 1.0.1, since it was already present in 0.25 and before. But it seems a safe fix (`.index.to_period()` basically does `.index.tz_localize(None).to_period()`), so I am fine with backporting.
I checked (visually) the output of the test function:
```
from pandas import date_range, Series
import matplotlib.pyplot as plt
import pytz

index = date_range("1/1/2011", periods=2, freq="H", tz=pytz.timezone('Europe/London'))
ts = Series([188.5, 328.25], index=index)
ts.plot()
plt.show()
```
and it looks like this:
![image](https://user-images.githubusercontent.com/33491632/73597348-f2077100-4522-11ea-8f60-e650be3d9ee5.png)

Is this right? Shouldn't both ticks be labeled?

Anyway, this isn't affected by the current change (it's present on master as well) so I believe it would count as a separate issue, but have written the current test assuming it's expected output
Hello @MarcoGorelli! Thanks for updating this PR. We checked the lines you've touched for [PEP 8](https://www.python.org/dev/peps/pep-0008) issues, and found:





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

##### Comment last updated at 2020-02-02 17:27:38 UTC
`pytest pandas/tests/plotting/test_datetimelike.py` works locally but not during CI, looking into it
In one of the tests from the CI (linux py36_local), the axis labels are
```
['01 00:01', ...1 00:51', ...]
```

I don't understand where that extra minute is coming from (nor can I understand why it only appears during CI), but I think it'll take me longer than the v1.0.1 deadline to figure this out.
cc @TomAugspurger @jorisvandenbossche  ok as is?
@jreback Should I remove the test that checks the labels (which fails during CI) and open a separate issue about that?
> @jreback Should I remove the test that checks the labels (which fails during CI) and open a separate issue about that?

yes
@jreback Done, and have opened #31580
Thanks @MarcoGorelli !