Skip to content

Commit

Permalink
Putting chmod in a try/except block.
Browse files Browse the repository at this point in the history
  • Loading branch information
ndilalla committed May 10, 2024
1 parent 060bbfa commit f049b66
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions threeML/utils/data_builders/fermi/lat_transient_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -629,9 +629,13 @@ def run(self, include_previous_intervals=False, recompute_intervals=False):
os.path.join(gtapp_mp_dir, 'gtltcube_mp.py'),
os.path.join(gtapp_mp_dir, 'gttsmap_mp.py'),
]
for _e in executables:
print ("Changing permission to %s" % _e)
os.chmod(_e, 0o755)

try:
for _e in executables:
log.info('Changing permission to %s' % _e)
os.chmod(_e, 0o755)
except PermissionError:
pass

log.info('About to run the following command:\n%s' % cmd)

Expand Down

0 comments on commit f049b66

Please sign in to comment.