Skip to content
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

COMPAT: some compatibility fixes with new numpies #13010

Merged
merged 1 commit into from Apr 27, 2016

Conversation

jreback
Copy link
Contributor

@jreback jreback commented Apr 27, 2016

No description provided.

@jreback jreback added the Compat pandas objects compatability with Numpy or Python functions label Apr 27, 2016
@jreback jreback added this to the 0.18.1 milestone Apr 27, 2016
dtype=np.uint16),
'u32': Series(np.random.random_integers(0, high=2**30, size=5),
'u32': Series(np.random.randint(0, high=2**30, size=5),
dtype=np.uint32),
Copy link
Member

Choose a reason for hiding this comment

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

Not sure if this a problem, but these function calls aren't quite equivalent (closed vs. open interval for random_integers and randint respectively).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

they seem the same.

Copy link
Member

@gfyoung gfyoung Apr 27, 2016

Choose a reason for hiding this comment

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

It's a moot point if Travis is still happy, but for reference, they are not equivalent by definition.

@jreback
Copy link
Contributor Author

jreback commented Apr 27, 2016

@tacaswell @mdboom, using mpl 1.5.0 here. I was turning on deprecation warnings. (we get a bunch of these in test suite), known issue?

cc @TomAugspurger

======================================================================
ERROR: test_ts_area_lim (pandas.tests.test_graphics.TestSeriesPlots)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "pandas/tests/test_graphics.py", line 612, in test_ts_area_lim
    ax = self.ts.plot.area(stacked=False, x_compat=True)
  File "pandas/tools/plotting.py", line 3688, in area
    return self(kind='area', **kwds)
  File "pandas/tools/plotting.py", line 3564, in __call__
    **kwds)
  File "pandas/tools/plotting.py", line 2643, in plot_series
    **kwds)
  File "pandas/tools/plotting.py", line 2439, in _plot
    plot_obj.generate()
  File "pandas/tools/plotting.py", line 1032, in generate
    self._post_plot_logic_common(ax, self.data)
  File "pandas/tools/plotting.py", line 1160, in _post_plot_logic_common
    fontsize=self.fontsize)
  File "pandas/tools/plotting.py", line 1208, in _apply_axis_properties
    labels = axis.get_majorticklabels() + axis.get_minorticklabels()
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/axis.py", line 1161, in get_majorticklabels
    ticks = self.get_major_ticks()
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/axis.py", line 1290, in get_major_ticks
    numticks = len(self.get_major_locator()())
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/dates.py", line 1007, in __call__
    return self._locator()
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/dates.py", line 813, in __call__
    return self.tick_values(dmin, dmax)
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/dates.py", line 830, in tick_values
    self.rule.set(dtstart=start, until=stop, count=self.MAXTICKS + 1)
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/matplotlib/dates.py", line 724, in set
    self._rrule = rrule(**self._construct)
  File "/Users/jreback/miniconda/lib/python2.7/site-packages/dateutil/rrule.py", line 470, in __init__
    "raise an error.", DeprecationWarning)
DeprecationWarning: Using both 'count' and 'until' is inconsistent with RFC 2445 and has been deprecated in dateutil. Future versions will raise an error.

@mdboom
Copy link
Contributor

mdboom commented Apr 27, 2016

Thanks for pointing out. Not a known issue (to me at least). I'll see if I can reproduce locally.

@jreback
Copy link
Contributor Author

jreback commented Apr 27, 2016

@mdboom this is using pretty recently released python-dateutil 2.5.3 FYI (might be new there)

@tacaswell
Copy link
Contributor

There is a pr fixing this, but I am failing to find it.

@tacaswell
Copy link
Contributor

@mdboom
Copy link
Contributor

mdboom commented Apr 27, 2016

Thanks @tacaswell. Unfortunately, it doesn't look there's much of a way to workaround that from the outside...

@tacaswell
Copy link
Contributor

the fix will be it 1.5.2 / 2.0, which ever comes first

@jreback
Copy link
Contributor Author

jreback commented Apr 27, 2016

thanks @mdboom @tacaswell no worries. just trying to have clean test outputs.

@jreback jreback merged commit 65ed3af into pandas-dev:master Apr 27, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Compat pandas objects compatability with Numpy or Python functions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants