Skip to content

Commit 8b4941e

Browse files
committed
Use argfile to pass jacoco args
1 parent be5a5f2 commit 8b4941e

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

mx.graalpython/mx_graalpython.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -835,11 +835,7 @@ def make_coverage_launcher_if_needed(launcher):
835835
# jacoco agent is requested.
836836
quote = shlex.quote if sys.platform != 'win32' else lambda x: x
837837
def graalvm_vm_arg(java_arg):
838-
if java_arg.startswith("@") and os.path.exists(java_arg[1:]):
839-
with open(java_arg[1:], "r") as f:
840-
java_arg = f.read()
841-
assert java_arg[0] == "-", java_arg
842-
return quote(f'--vm.{java_arg[1:]}')
838+
return quote(f'--vm.{java_arg[1:] if java_arg.startswith("-") else java_arg}')
843839

844840
agent_args = ' '.join(graalvm_vm_arg(arg) for arg in mx_gate.get_jacoco_agent_args() or [])
845841

0 commit comments

Comments
 (0)