Where should matplotlib.use('Agg') be?
Issue #130
resolved
We currently have it at the top of some modules --- it needs to be run before any other matplotlib import for headless operation. This means when we run our nightly tests, and it can't open a display, that it won't crash.
However, if we're setting this at the module level, then users are probably not free to change their backend unless they hack the module.
I tried putting it instead in the test script for fpplot_test.py. If this works, this is a better place for it. If the test succeeds, switch the other instance(s)...
Comments (2)
-
reporter -
reporter - changed status to resolved
- Log in to comment
All the matplotlib.use statements are only in the test scripts or example scripts, so this seems like the way to do it.