Skip to content

Commit

Permalink
Allow plotInfo SN key to be missing
Browse files Browse the repository at this point in the history
  • Loading branch information
isullivan committed Sep 20, 2022
1 parent dd74739 commit f8f3e45
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/lsst/analysis/tools/actions/plot/plotUtils.py
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ def addPlotInfo(fig, plotInfo):
for band in plotInfo["bands"]:
bandText += band + ", "
bandsText = f", Bands: {bandText[:-2]}"
SNText = f", S/N: {plotInfo['SN']}"
SNText = f", S/N: {plotInfo['SN']}" if "SN" in plotInfo.keys() else ""
infoText = f"\n{run}{datasetsUsed}{tableType}{dataIdText}{bandsText}{SNText}"
fig.text(0.01, 0.98, infoText, fontsize=7, transform=fig.transFigure, alpha=0.6, ha="left", va="top")

Expand Down

0 comments on commit f8f3e45

Please sign in to comment.