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

BUG: yt.funcs.matplotlib_style_context isn't tested #4342

Open
neutrinoceros opened this issue Feb 18, 2023 · 1 comment
Open

BUG: yt.funcs.matplotlib_style_context isn't tested #4342

neutrinoceros opened this issue Feb 18, 2023 · 1 comment

Comments

@neutrinoceros
Copy link
Member

Bug report

Bug summary

This function hasn't received any care for a while, and it's currently not tested.
Currently, it doesn't produce the expected results

Code for reproduction

import matplotlib.pyplot as plt
import yt

with yt.funcs.matplotlib_style_context():
    fig, ax = plt.subplots()
    ax.plot([0, 1], [0, 1])
    ax.set(xlabel=r"$\Sigma$", ylabel=r"$\beta$", title="My fake yt plot")
    fig.savefig("/tmp/yt_style_funcs.png")

Actual outcome
yt_style_funcs

Expected outcome

Something like
yt_style_mpl_context

@neutrinoceros
Copy link
Member Author

Actually yt.funcs.matplotlib_style_context is used internally in a couple of places, so it's not completely untested, but there are no unit tests for it.

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

No branches or pull requests

1 participant