File: pyBART_run_test.py

package info (click to toggle)
bart 0.9.00-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 9,040 kB
  • sloc: ansic: 116,116; python: 1,329; sh: 726; makefile: 639; javascript: 589; cpp: 106
file content (14 lines) | stat: -rw-r--r-- 314 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
import sys
import traceback
import os

try:
    with open(sys.argv[1], 'r') as fd:
        for line in fd.readlines():
            exec(line)               
except:
    exc_info = sys.exc_info()
    traceback.print_exception(*exc_info)
    print('Exception occurred while executing line: ', line)
    sys.exit(1)