|
43 | 43 | for i in range(len(folder)): |
44 | 44 | print('generating smokeview image ' + case[i]) |
45 | 45 | os.chdir(outdir + folder[i]) |
46 | | - if os_name == "Linux": |
47 | | - try: |
| 46 | + try: |
| 47 | + if os_name == "Linux": |
48 | 48 | subprocess.run(['xvfb-run','-w','10','-s','-fp /usr/share/X11/fonts/misc -screen 0 1280x1024x24','-a',smokeview_path, |
49 | | - '-bindir',bindir,'-runscript', case[i] ], check=True, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) |
50 | | - except subprocess.CalledProcessError as e: |
51 | | - print(f"Smokeview failed with return code {e.returncode}") |
52 | | - except FileNotFoundError: |
53 | | - print(f"Smokeview executable not found: {smokeview_path}") |
54 | | - else: |
55 | | - subprocess.run([smokeview_path,'-bindir',bindir,'-runscript',case[i]], stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) |
| 49 | + '-bindir',bindir,'-runscript', case[i] ], check=True, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) |
| 50 | + else: |
| 51 | + subprocess.run([smokeview_path,'-bindir',bindir,'-runscript',case[i]], |
| 52 | + check=True, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) |
| 53 | + except subprocess.CalledProcessError as e: |
| 54 | + print(f"Error: Smokeview failed with return code {e.returncode}") |
| 55 | + except FileNotFoundError: |
| 56 | + print(f"Error: Smokeview executable not found: {smokeview_path}") |
56 | 57 |
|
57 | 58 | os.chdir(original_dir) |
58 | 59 |
|
0 commit comments