-
-
Notifications
You must be signed in to change notification settings - Fork 216
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
solves Line2D attribute error with matplotlib 3.7.0
#571
base: main
Are you sure you want to change the base?
Conversation
the error on most recent matplotlib version is the following: ```bash AttributeError: 'Line2D' object has no attribute '_us_dashSeq' ```
@nschloe, ping. Is tikzplotlib still maintained? I'd like to know whether there's a point waiting for new matplotlib support or if we should remove tikzplotlib from Gentoo. |
@mgorny I haven't had much time for tpl indeed. Not exactly sure when I'll be able to again. If it's a blocker for you, best remove it, and add it again when I get back to it. |
dashOffset = line._dash_pattern[0] | ||
dashSeq = line._dash_pattern[1] |
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.
As in https://github.com/nschloe/tikzplotlib/pull/558/files, it would be better to keep this backwards-compatible:
dashOffset = line._dash_pattern[0] | |
dashSeq = line._dash_pattern[1] | |
try: | |
dashOffset, dashSeq = line._dash_pattern[:2] | |
except AttributeError: | |
# backwards-compatibility with matplotlib < 3.7.0 | |
dashOffset = line._us_dashOffset | |
dashSeq = line._us_dashSeq |
…schloe#571] * solves attribute error with matplotlib `3.7.0` the error on most recent matplotlib version is the following: ```bash AttributeError: 'Line2D' object has no attribute '_us_dashSeq' ``` * Update src/tikzplotlib/_path.py --------- Co-authored-by: Thomas Gillis <25429825+thomasgillis@users.noreply.github.com>
the error on most recent matplotlib version is the following: