Details
-
Bug
-
Status: Open
-
Minor
-
Resolution: Unresolved
-
0.8.0, 0.8.1
-
None
-
None
Description
Simple plot works:
As soon as I add the class attribute I get an error:
Fail to execute line 9: p Traceback (most recent call last): File "/tmp/zeppelin_pyspark-7550126901118262154.py", line 380, in <module> exec(code, _zcUserQueryNameSpace) File "<stdin>", line 9, in <module> File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/plotnine/ggplot.py", line 95, in __repr__ self.draw() File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/plotnine/ggplot.py", line 188, in draw return self._draw(return_ggplot) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/plotnine/ggplot.py", line 219, in _draw raise err File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/plotnine/ggplot.py", line 211, in _draw self._draw_legend() File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/plotnine/ggplot.py", line 481, in _draw_legend ax.add_artist(anchored_box) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/axes/_base.py", line 1835, in add_artist self._set_artist_props(a) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/axes/_base.py", line 917, in _set_artist_props a.set_figure(self.figure) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/offsetbox.py", line 154, in set_figure martist.Artist.set_figure(self, fig) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/artist.py", line 695, in set_figure self.stale = True File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/artist.py", line 230, in stale self.stale_callback(self, val) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/artist.py", line 51, in _stale_axes_callback self.axes.stale = val File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/artist.py", line 230, in stale self.stale_callback(self, val) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/figure.py", line 51, in _stale_figure_callback self.figure.stale = val File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/artist.py", line 230, in stale self.stale_callback(self, val) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/pyplot.py", line 589, in _auto_draw_if_interactive fig.canvas.draw_idle() File "/zeppelin/zeppelin-0.8.1-bin-all/interpreter/lib/python/backend_zinline.py", line 136, in draw_idle self.draw(*args, **kwargs) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/backends/backend_agg.py", line 388, in draw self.figure.draw(self.renderer) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/artist.py", line 38, in draw_wrapper return draw(artist, renderer, *args, **kwargs) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/figure.py", line 1709, in draw renderer, self, artists, self.suppressComposite) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/image.py", line 135, in _draw_list_compositing_images a.draw(renderer) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/artist.py", line 38, in draw_wrapper return draw(artist, renderer, *args, **kwargs) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/axes/_base.py", line 2647, in draw mimage._draw_list_compositing_images(renderer, self, artists) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/image.py", line 135, in _draw_list_compositing_images a.draw(renderer) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/offsetbox.py", line 1169, in draw width, height, xdescent, ydescent = self.get_extent(renderer) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/offsetbox.py", line 1071, in get_extent w, h, xd, yd = self.get_child().get_extent(renderer) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/offsetbox.py", line 236, in get_extent w, h, xd, yd, offsets = self.get_extent_offsets(renderer) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/offsetbox.py", line 363, in get_extent_offsets for c in self.get_visible_children()] File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/offsetbox.py", line 363, in <listcomp> for c in self.get_visible_children()] File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/offsetbox.py", line 236, in get_extent w, h, xd, yd, offsets = self.get_extent_offsets(renderer) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/offsetbox.py", line 363, in get_extent_offsets for c in self.get_visible_children()] File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/offsetbox.py", line 363, in <listcomp> for c in self.get_visible_children()] File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/offsetbox.py", line 810, in get_extent bbox, info, d = self._text._get_layout(renderer) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/text.py", line 276, in _get_layout key = self.get_prop_tup(renderer=renderer) File "/zeppelin/anaconda/anaconda3/envs/zeppelin/lib/python3.7/site-packages/matplotlib/text.py", line 837, in get_prop_tup self.figure.dpi, weakref.ref(renderer), AttributeError: 'NoneType' object has no attribute 'dpi'