Changeset bf48c8a in flex_extract.git for source/python/install.py


Ignore:
Timestamp:
Dec 14, 2018, 11:27:42 AM (5 years ago)
Author:
Anne Philipp <anne.philipp@…>
Branches:
master, ctbto, dev
Children:
1eca806
Parents:
524ac32
Message:

introduced a function for subprocess check_call to do error handling once

File:
1 edited

Legend:

Unmodified
Added
Removed
  • source/python/install.py

    r8652e7e rbf48c8a  
    6262from classes.UioFiles import UioFiles
    6363from mods.tools import (make_dir, put_file_to_ecserver, submit_job_to_ecserver,
    64                         silent_remove)
     64                        silent_remove, execute_subprocess)
    6565
    6666# ------------------------------------------------------------------------------
     
    677677        print(e)
    678678    else:
    679         subprocess.check_call(['ls', '-l',
    680                                os.path.join(src_path,
    681                                             _config.FORTRAN_EXECUTABLE)])
     679        execute_subprocess(['ls', '-l', os.path.join(src_path,
     680                            _config.FORTRAN_EXECUTABLE)], error_msg=
     681                           'FORTRAN EXECUTABLE COULD NOT BE FOUND!')
    682682
    683683    return
Note: See TracChangeset for help on using the changeset viewer.
hosted by ZAMG