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

[ctimer--overall] QuadMesh object has no property 'fig_suptitle' #38

Open
zztin opened this issue Nov 10, 2020 · 1 comment
Open

[ctimer--overall] QuadMesh object has no property 'fig_suptitle' #38

zztin opened this issue Nov 10, 2020 · 1 comment

Comments

@zztin
Copy link
Owner

zztin commented Nov 10, 2020

Description

Describe the bug
code breaks while given ctimer --overall

  • ctimer version:1.1.0
  • Python version:3.8
  • Operating System:MacOS

Steps to Reproduce

Steps to reproduce the behavior: ctimer --overall

Trackback:
/Users/lchen/miniconda/envs/ctimer-dev/lib/python3.8/site-packages/calmap-0.0.8-py3.8.egg/calmap/__init__.py:181: FutureWarning: weekofyear and week have been deprecated, please use DatetimeIndex.isocalendar().week instead, which returns a Series.  To exactly reproduce the behavior of week and weekofyear and return an Index, you may call pd.Int64Index(idx.isocalendar().week)
  "week": by_day.index.week,
Traceback (most recent call last):
  File "/Users/lchen/miniconda/envs/ctimer-dev/bin/ctimer", line 33, in <module>
    sys.exit(load_entry_point('pomodoro-ctimer', 'console_scripts', 'ctimer')())
  File "/Users/lchen/current_projects/ctimer/ctimer/cli.py", line 125, in main
    ss.plot_calmap(events=events)
  File "/Users/lchen/current_projects/ctimer/ctimer/visual/show_stats.py", line 25, in plot_calmap
    calmap.calendarplot(events, monthticks=True, daylabels='MTWTFSS',
  File "/Users/lchen/miniconda/envs/ctimer-dev/lib/python3.8/site-packages/calmap-0.0.8-py3.8.egg/calmap/__init__.py", line 348, in calendarplot
    yearplot(by_day, year=year, how=None, ax=ax, **kwargs)
  File "/Users/lchen/miniconda/envs/ctimer-dev/lib/python3.8/site-packages/calmap-0.0.8-py3.8.egg/calmap/__init__.py", line 207, in yearplot
    ax.pcolormesh(plot_data, vmin=vmin, vmax=vmax, cmap=cmap, **kwargs)
  File "/Users/lchen/miniconda/envs/ctimer-dev/lib/python3.8/site-packages/matplotlib-3.3.1-py3.8-macosx-10.9-x86_64.egg/matplotlib/__init__.py", line 1438, in inner
    return func(ax, *map(sanitize_sequence, args), **kwargs)
  File "/Users/lchen/miniconda/envs/ctimer-dev/lib/python3.8/site-packages/matplotlib-3.3.1-py3.8-macosx-10.9-x86_64.egg/matplotlib/axes/_axes.py", line 6098, in pcolormesh
    collection = mcoll.QuadMesh(Nx - 1, Ny - 1, coords,
  File "/Users/lchen/miniconda/envs/ctimer-dev/lib/python3.8/site-packages/matplotlib-3.3.1-py3.8-macosx-10.9-x86_64.egg/matplotlib/collections.py", line 1919, in __init__
    Collection.__init__(self, **kwargs)
  File "/Users/lchen/miniconda/envs/ctimer-dev/lib/python3.8/site-packages/matplotlib-3.3.1-py3.8-macosx-10.9-x86_64.egg/matplotlib/cbook/deprecation.py", line 411, in wrapper
    return func(*inner_args, **inner_kwargs)
  File "/Users/lchen/miniconda/envs/ctimer-dev/lib/python3.8/site-packages/matplotlib-3.3.1-py3.8-macosx-10.9-x86_64.egg/matplotlib/collections.py", line 213, in __init__
    self.update(kwargs)
  File "/Users/lchen/miniconda/envs/ctimer-dev/lib/python3.8/site-packages/matplotlib-3.3.1-py3.8-macosx-10.9-x86_64.egg/matplotlib/artist.py", line 996, in update
    raise AttributeError(f"{type(self).__name__!r} object "
AttributeError: 'QuadMesh' object has no property 'fig_suptitle'
@tai271828
Copy link
Collaborator

tai271828 commented Dec 8, 2020

tl;dr use the updated calmap modified by you https://github.com/zztin/calmap

The issue seems to be introduced by pandas version bump a few months ago, and the corresponding python package calmap should be updated along with the pandas version bump. The updated calmap is in your repository by forking the original calmap. : ) So, we may close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants