aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar ionite34 <[email protected]>2022-11-18 14:31:43 -0500
committerGravatar ionite34 <[email protected]>2022-11-18 14:31:43 -0500
commit1655e52299823a61bda0cff43077bb0fd9b6aec1 (patch)
treea4884f1667493985b8d49623dc8476725c51f8ec
parentFix name assignment (diff)
Add override for timeit
-rw-r--r--snekbox/nsjail.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/snekbox/nsjail.py b/snekbox/nsjail.py
index 825fb9a..6866377 100644
--- a/snekbox/nsjail.py
+++ b/snekbox/nsjail.py
@@ -207,6 +207,10 @@ class NsJail:
c_arg = "c" in "".join(py_args)
+ # Override for `timeit`
+ if "timeit" in py_args:
+ use_file = False
+
match (use_file, c_arg):
case (True, _) | (None, False):
args.append("main.py")