Skip to content

Commit

Permalink
MNT #45 do not crash if filename is actually a dir
Browse files Browse the repository at this point in the history
  • Loading branch information
Service Account for Jan Ilavsky committed Sep 17, 2020
1 parent fd87e5f commit 455e35a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions specplotsAllScans.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,10 @@ def saveCacheFile(cache_file, cache):
def plotAllSpecFileScans(specFile):
'''make standard plots for all scans in the specFile'''
if not os.path.exists(specFile):
logger.debug("Does not exist: %s", specFile)
return
if not os.path.isfile(specFile):
logger.debug("Is not a file: %s", specFile)
return

# decide here if SPEC file needs to be opened for possible replot of scan data
Expand Down

0 comments on commit 455e35a

Please sign in to comment.