Skip to content
Snippets Groups Projects
Commit 84c11172 authored by Jameson Graef Rollins's avatar Jameson Graef Rollins
Browse files

catch matplotlib error import more gracefully

parent 82dee4a1
No related branches found
No related tags found
No related merge requests found
Pipeline #29231 passed
......@@ -122,7 +122,11 @@ def main():
# set this opportunistically.
import matplotlib
matplotlib.use('AGG')
from matplotlib import pyplot as plt
try:
from matplotlib import pyplot as plt
except RuntimeError:
logging.warning("no display, plotting disabled.")
args.plot = False
if args.matlab:
gwinc = gwinc_matlab.gwinc_matlab
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment