Skip to content

Commit cee98ea

Browse files
authored
Merge pull request #1840 from McStasMcXtrace/willend-patch2
Param default adj Union_master + mcrun fallback solution for picking up code generator from PATH
2 parents dd00818 + 2025a60 commit cee98ea

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

mcstas-comps/union/Union_master.comp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ SETTING PARAMETERS(verbal = 1,
5858
history_limit=300000,
5959
enable_conditionals=1,
6060
inherit_number_of_scattering_events=0,
61-
weight_ratio_limit=0.0000001,
61+
weight_ratio_limit=1e-90,
6262
string init="init")
6363

6464
NOACC

tools/Python/mcrun/mccode.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,10 @@ def x_path(file):
141141
# Generate C-code (implicit: prepare for --trace mode if not no_main / Vitess)
142142
LOG.info('Regenerating c-file: %s', basename(self.cpath))
143143
mccode_bin_abspath = str( pathlib.Path(mccode_config.directories['bindir']) / options.mccode_bin )
144+
if not os.path.exists(mccode_bin_abspath):
145+
LOG.warning('Full-path code-generator "%s" not found!!', mccode_bin_abspath)
146+
mccode_bin_abspath=basename(mccode_bin_abspath)
147+
LOG.warning('Attempting replacement by "%s"', mccode_bin_abspath)
144148

145149
if not options.no_main:
146150
if self.options.I is not None:

0 commit comments

Comments
 (0)