rbx.cp 0.5.42__py3-none-any.whl → 0.5.46__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- rbx/box/cli.py +8 -0
- rbx/box/code.py +76 -3
- rbx/box/generators.py +77 -40
- rbx/box/main.py +0 -4
- rbx/box/package.py +16 -2
- rbx/box/solutions.py +5 -3
- rbx/box/state.py +1 -0
- rbx/box/statements/builders.py +22 -3
- rbx/box/tasks.py +32 -5
- rbx/box/testcase_utils.py +66 -0
- rbx/grading/judge/cacher.py +0 -4
- rbx/grading/judge/digester.py +0 -3
- rbx/grading/judge/sandbox.py +7 -0
- rbx/grading/judge/sandboxes/isolate.py +2 -2
- rbx/grading/judge/sandboxes/stupid_sandbox.py +11 -2
- rbx/grading/judge/sandboxes/timeit.py +109 -5
- rbx/grading/judge/storage.py +0 -4
- rbx/main.py +0 -4
- {rbx_cp-0.5.42.dist-info → rbx_cp-0.5.46.dist-info}/METADATA +1 -2
- {rbx_cp-0.5.42.dist-info → rbx_cp-0.5.46.dist-info}/RECORD +23 -54
- {rbx_cp-0.5.42.dist-info → rbx_cp-0.5.46.dist-info}/WHEEL +1 -1
- rbx/testdata/box1/gen1.cpp +0 -7
- rbx/testdata/box1/gen2.cpp +0 -9
- rbx/testdata/box1/genScript.py +0 -2
- rbx/testdata/box1/hard-tle.sol.cpp +0 -26
- rbx/testdata/box1/ole.cpp +0 -17
- rbx/testdata/box1/problem.rbx.yml +0 -39
- rbx/testdata/box1/re.sol.cpp +0 -23
- rbx/testdata/box1/sol.cpp +0 -22
- rbx/testdata/box1/tests/1.in +0 -1
- rbx/testdata/box1/tle-and-incorrect.sol.cpp +0 -33
- rbx/testdata/box1/tle.sol.cpp +0 -35
- rbx/testdata/box1/validator.cpp +0 -11
- rbx/testdata/box1/wa.sol.cpp +0 -22
- rbx/testdata/caching/executable.py +0 -1
- rbx/testdata/compatible +0 -0
- rbx/testdata/interactive/checker.cpp +0 -21
- rbx/testdata/interactive/gen.cpp +0 -11
- rbx/testdata/interactive/interactor.cpp +0 -63
- rbx/testdata/interactive/problem.rbx.yml +0 -40
- rbx/testdata/interactive/sols/af_ac_pe.cpp +0 -75
- rbx/testdata/interactive/sols/af_ac_re.cpp +0 -76
- rbx/testdata/interactive/sols/af_ac_too_many_iter.cpp +0 -72
- rbx/testdata/interactive/sols/af_inf_cout_with_flush.cpp +0 -79
- rbx/testdata/interactive/sols/af_inf_cout_without_flush.cpp +0 -78
- rbx/testdata/interactive/sols/af_ml.cpp +0 -78
- rbx/testdata/interactive/sols/af_tl_after_ans.cpp +0 -74
- rbx/testdata/interactive/sols/af_wa.cpp +0 -74
- rbx/testdata/interactive/sols/interactive-binary-search_mm_naive_cin.cpp +0 -17
- rbx/testdata/interactive/sols/main.cpp +0 -26
- rbx/testdata/interactive/testplan.txt +0 -6
- rbx/testdata/interactive/validator.cpp +0 -16
- {rbx_cp-0.5.42.dist-info → rbx_cp-0.5.46.dist-info}/LICENSE +0 -0
- {rbx_cp-0.5.42.dist-info → rbx_cp-0.5.46.dist-info}/entry_points.txt +0 -0
@@ -556,7 +556,7 @@ class IsolateSandbox(SandboxBase):
|
|
556
556
|
)
|
557
557
|
except OSError:
|
558
558
|
logger.critical(
|
559
|
-
'Failed to execute program in sandbox
|
559
|
+
'Failed to execute program in sandbox with command: %s',
|
560
560
|
str(args),
|
561
561
|
exc_info=True,
|
562
562
|
)
|
@@ -680,4 +680,4 @@ class IsolateSandbox(SandboxBase):
|
|
680
680
|
if delete:
|
681
681
|
logger.debug('Deleting sandbox in %s.', self._outer_dir)
|
682
682
|
# Delete the working directory.
|
683
|
-
shutil.rmtree(str(self._outer_dir))
|
683
|
+
shutil.rmtree(str(self._outer_dir), ignore_errors=True)
|
@@ -105,8 +105,17 @@ class StupidSandbox(SandboxBase):
|
|
105
105
|
file_args.append(f'-e{self.params.stderr_file}')
|
106
106
|
if self.params.reverse_io:
|
107
107
|
file_args.reverse()
|
108
|
+
args.extend(file_args)
|
108
109
|
|
109
|
-
|
110
|
+
if self.params.timeit_dups:
|
111
|
+
for i, files in self.params.timeit_dups.items():
|
112
|
+
assert i.lower() in ['di', 'do', 'de']
|
113
|
+
for file in files:
|
114
|
+
args.append(f'-{i}{file}')
|
115
|
+
if self.params.timeit_prefix:
|
116
|
+
args.append(f'-P{self.params.timeit_prefix}')
|
117
|
+
|
118
|
+
return args
|
110
119
|
|
111
120
|
def get_root_path(self) -> pathlib.Path:
|
112
121
|
"""Return the toplevel path of the sandbox.
|
@@ -312,4 +321,4 @@ class StupidSandbox(SandboxBase):
|
|
312
321
|
# This sandbox doesn't have any cleanup, but we might want to delete.
|
313
322
|
if delete:
|
314
323
|
logger.debug('Deleting sandbox in %s.', self._path)
|
315
|
-
shutil.rmtree(str(self._path))
|
324
|
+
shutil.rmtree(str(self._path), ignore_errors=True)
|
@@ -6,7 +6,7 @@ import signal
|
|
6
6
|
import stat
|
7
7
|
import sys
|
8
8
|
from time import monotonic
|
9
|
-
from typing import List, Optional
|
9
|
+
from typing import Any, Dict, List, Optional, Set, Union
|
10
10
|
|
11
11
|
|
12
12
|
@dataclasses.dataclass
|
@@ -22,12 +22,96 @@ class Options:
|
|
22
22
|
memory_limit: Optional[int] = None # kb, but passed in args as mb
|
23
23
|
fs_limit: Optional[int] = None # kb
|
24
24
|
files_to_open: List[int] = dataclasses.field(default_factory=list)
|
25
|
+
file_duplicates: Dict[int, List[str]] = dataclasses.field(default_factory=dict)
|
26
|
+
prefixed: Set[str] = dataclasses.field(default_factory=set)
|
27
|
+
prefix: str = ''
|
25
28
|
|
26
29
|
|
27
30
|
def exit_with(code: int):
|
28
31
|
sys.exit(code)
|
29
32
|
|
30
33
|
|
34
|
+
def get_tee_command(files: List[str]) -> str:
|
35
|
+
path = (
|
36
|
+
os.path.join(os.path.dirname(os.path.realpath(__file__)), 'tee.py')
|
37
|
+
+ ' '
|
38
|
+
+ ' '.join(files)
|
39
|
+
)
|
40
|
+
return sys.executable + ' ' + path
|
41
|
+
|
42
|
+
|
43
|
+
valid_modes = ['a', 'w']
|
44
|
+
|
45
|
+
|
46
|
+
@dataclasses.dataclass
|
47
|
+
class Tee:
|
48
|
+
file: Any
|
49
|
+
prefix: Union[str, bytes] = ''
|
50
|
+
|
51
|
+
|
52
|
+
def create_tee(files, mode, buffer_size=4096, prefix=''):
|
53
|
+
"""Get a file object that will mirror writes across multiple files objs
|
54
|
+
|
55
|
+
Options:
|
56
|
+
files A list of files and/or file objects. All strings will be
|
57
|
+
treated as file paths and opened for writing. Everything
|
58
|
+
else is assumed to be a file-like object that implements
|
59
|
+
both the write() and flush() methods.
|
60
|
+
|
61
|
+
mode Which mode to use when opening new files. Valid values
|
62
|
+
are 'a' (append) and 'w' (overwrite).
|
63
|
+
|
64
|
+
buffer_size
|
65
|
+
Control the size of the buffer between writes to the
|
66
|
+
resulting file object and the list of files.
|
67
|
+
"""
|
68
|
+
if mode not in valid_modes:
|
69
|
+
raise IOError(
|
70
|
+
'Only valid modes to create_tee() are: %s' % ', '.join(valid_modes)
|
71
|
+
)
|
72
|
+
|
73
|
+
tee_list = []
|
74
|
+
for file in files:
|
75
|
+
if isinstance(file, Tee):
|
76
|
+
tee_list.append(file)
|
77
|
+
else:
|
78
|
+
tee_list.append(Tee(file))
|
79
|
+
for tee in tee_list:
|
80
|
+
if isinstance(tee.file, str):
|
81
|
+
tee.file = open(tee.file, f'{mode}b')
|
82
|
+
if isinstance(tee.prefix, str):
|
83
|
+
tee.prefix = tee.prefix.encode()
|
84
|
+
|
85
|
+
pipe_read, pipe_write = os.pipe()
|
86
|
+
pid = os.fork()
|
87
|
+
if pid == 0:
|
88
|
+
# Child -- Read bytes from the pipe and write them to the specified
|
89
|
+
# files.
|
90
|
+
try:
|
91
|
+
# Close parent's end of the pipe
|
92
|
+
os.close(pipe_write)
|
93
|
+
|
94
|
+
bytes = os.read(pipe_read, buffer_size)
|
95
|
+
while bytes:
|
96
|
+
for tee in tee_list:
|
97
|
+
if tee.prefix:
|
98
|
+
tee.file.write(tee.prefix)
|
99
|
+
tee.file.write(bytes)
|
100
|
+
tee.file.flush()
|
101
|
+
# TODO maybe add in fsync() here if the fileno() method
|
102
|
+
# exists on file
|
103
|
+
|
104
|
+
bytes = os.read(pipe_read, buffer_size)
|
105
|
+
except Exception:
|
106
|
+
pass
|
107
|
+
finally:
|
108
|
+
os._exit(255)
|
109
|
+
else:
|
110
|
+
# Parent -- Return a file object wrapper around the pipe to the
|
111
|
+
# child.
|
112
|
+
return os.fdopen(pipe_write, 'w', closefd=False)
|
113
|
+
|
114
|
+
|
31
115
|
def parse_opts() -> Options:
|
32
116
|
options = Options(output_file=sys.argv[1], argv=[])
|
33
117
|
options.files_to_open = []
|
@@ -50,10 +134,21 @@ def parse_opts() -> Options:
|
|
50
134
|
elif opt.startswith('-e'):
|
51
135
|
options.stderr_file = opt[2:]
|
52
136
|
options.files_to_open.append(2)
|
137
|
+
elif opt.startswith('-d') or opt.startswith('-D'):
|
138
|
+
is_prefixed = opt.startswith('-D')
|
139
|
+
possibilities = [None, 'o', 'e']
|
140
|
+
index = possibilities.index(opt[2])
|
141
|
+
if index not in options.file_duplicates:
|
142
|
+
options.file_duplicates[index] = []
|
143
|
+
options.file_duplicates[index].append(opt[3:])
|
144
|
+
if is_prefixed:
|
145
|
+
options.prefixed.add(opt[3:])
|
53
146
|
elif opt.startswith('-c'):
|
54
147
|
options.chdir = opt[2:]
|
55
148
|
elif opt.startswith('-f'):
|
56
149
|
options.fs_limit = int(opt[2:])
|
150
|
+
elif opt.startswith('-P'):
|
151
|
+
options.prefix = opt[2:]
|
57
152
|
else:
|
58
153
|
raise Exception(f'Invalid option {opt}')
|
59
154
|
num_opts += 1
|
@@ -108,10 +203,18 @@ def redirect_fds(options: Options):
|
|
108
203
|
if i == 0:
|
109
204
|
# stdin
|
110
205
|
open_args = [os.O_RDONLY]
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
206
|
+
if i in options.file_duplicates:
|
207
|
+
dups = [
|
208
|
+
Tee(f, prefix=options.prefix if f in options.prefixed else '')
|
209
|
+
for f in options.file_duplicates[i]
|
210
|
+
]
|
211
|
+
tee = create_tee(dups + [file], 'a', prefix=options.prefix)
|
212
|
+
fd = tee.fileno()
|
213
|
+
else:
|
214
|
+
fd = os.open(
|
215
|
+
file,
|
216
|
+
*open_args,
|
217
|
+
)
|
115
218
|
os.dup2(fd, i)
|
116
219
|
os.close(fd)
|
117
220
|
|
@@ -221,3 +324,4 @@ def main():
|
|
221
324
|
|
222
325
|
if __name__ == '__main__':
|
223
326
|
main()
|
327
|
+
# type: ignore
|
rbx/grading/judge/storage.py
CHANGED
@@ -6,8 +6,6 @@ import tempfile
|
|
6
6
|
from abc import ABC, abstractmethod
|
7
7
|
from typing import IO, AnyStr, List, Optional
|
8
8
|
|
9
|
-
import gevent
|
10
|
-
|
11
9
|
logger = logging.getLogger(__name__)
|
12
10
|
|
13
11
|
TOMBSTONE = 'x'
|
@@ -40,11 +38,9 @@ def copyfileobj(
|
|
40
38
|
if maxlen > 0 and maxlen < len(buffer):
|
41
39
|
buffer = buffer[:maxlen]
|
42
40
|
while len(buffer) > 0:
|
43
|
-
gevent.sleep(0)
|
44
41
|
written = destination_fobj.write(buffer)
|
45
42
|
buffer = buffer[written:]
|
46
43
|
maxlen -= written
|
47
|
-
gevent.sleep(0)
|
48
44
|
|
49
45
|
|
50
46
|
@dataclasses.dataclass
|
rbx/main.py
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.3
|
2
2
|
Name: rbx.cp
|
3
|
-
Version: 0.5.
|
3
|
+
Version: 0.5.46
|
4
4
|
Summary:
|
5
5
|
Author: Roberto Sales
|
6
6
|
Requires-Python: >=3.9,<4.0
|
@@ -13,7 +13,6 @@ Classifier: Programming Language :: Python :: 3.13
|
|
13
13
|
Requires-Dist: chardet (>=5.2.0,<6.0.0)
|
14
14
|
Requires-Dist: fastapi (>=0.115.8,<0.116.0)
|
15
15
|
Requires-Dist: filelock (>=3.14.0,<4.0.0)
|
16
|
-
Requires-Dist: gevent (>=24.2.1,<25.0.0)
|
17
16
|
Requires-Dist: gitpython (>=3.1.43,<4.0.0)
|
18
17
|
Requires-Dist: jinja2 (>=3.1.4,<4.0.0)
|
19
18
|
Requires-Dist: lark (>=1.2.2,<2.0.0)
|
@@ -5,8 +5,8 @@ rbx/box/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
5
5
|
rbx/box/builder.py,sha256=MDm2qqmhedAbhn3rWP6cDwbBsGhV6sz_2sg1zLkPDw0,3613
|
6
6
|
rbx/box/cd.py,sha256=9a_SOnzoJBXxxffp4Wbf3UKXIwKuN3Hvj7K6SocALwE,1194
|
7
7
|
rbx/box/checkers.py,sha256=l_QYatpKHQTSQ-R7DzNjEkDtdo2g9MkdT_3Kr6xgABU,8690
|
8
|
-
rbx/box/cli.py,sha256=
|
9
|
-
rbx/box/code.py,sha256=
|
8
|
+
rbx/box/cli.py,sha256=J8mqlZLLZO720FNvkdbV2K1-RGFezNYtyY7Mb4aBrT0,26371
|
9
|
+
rbx/box/code.py,sha256=Cnts7noJaaoM35DZ9xcJAKXLwsKB4oBebMidqmMMO4M,18795
|
10
10
|
rbx/box/compile.py,sha256=OJLthDQ921w9vyoE6Gk1Df54i5RwtRJ2YG-8XEfefcs,2489
|
11
11
|
rbx/box/conftest.py,sha256=sEmciXSeDC-wmrZ1JSxbsUenKNP_VWW32mrCun2pY3I,1070
|
12
12
|
rbx/box/contest/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -22,12 +22,12 @@ rbx/box/download.py,sha256=MFP-R26JiYGAP89I0TK-0fYc69Fsd20tsBqgtRCy5AE,2234
|
|
22
22
|
rbx/box/environment.py,sha256=47NtyuVC6zSQKAtQaXPEXvqcD-KJiuWRpWF8pYvcG4c,11158
|
23
23
|
rbx/box/extensions.py,sha256=Von8kIeXvNFTkGlMRMTvL2HIHPwlkuiMswr-ydbGV1w,519
|
24
24
|
rbx/box/formatting.py,sha256=3phFRHzqVXj4Ok1yDhCq6Clbw6KlqwJNpMhs--oTWFI,405
|
25
|
-
rbx/box/generators.py,sha256=
|
25
|
+
rbx/box/generators.py,sha256=5-3K0JSLR9GbV0LmOkvNsWiQaMvhFBrI56ZaV1WgodQ,13472
|
26
26
|
rbx/box/generators_test.py,sha256=J7aBfuJhU84MWDWzgReRoOuQw_hVa09B8gTKAvL2XVo,1987
|
27
27
|
rbx/box/lazy_importing_main.py,sha256=6Z8As7qVFFT619xHH9Xt8VCH57NjC4aDxfAgkWiUwT8,116
|
28
28
|
rbx/box/lazy_importing_test.py,sha256=B0-b3y_DkxEmtVfu4NfmVsgVdFl6kRCsEL6GLMHJISo,628
|
29
|
-
rbx/box/main.py,sha256=
|
30
|
-
rbx/box/package.py,sha256=
|
29
|
+
rbx/box/main.py,sha256=Imwc0ZkheOpa5r8S0Xpb8RLQzJgxb9vyuSR4_wab11g,43
|
30
|
+
rbx/box/package.py,sha256=YuX_FS6yKx6FaFz0NF0cx3v6jzhqwvsLr3Oprx_TTJA,13645
|
31
31
|
rbx/box/packaging/boca/extension.py,sha256=hQhcbocNfW2ESv5RalS1wf6uvOoOfOnR_gHvbXUbSzY,852
|
32
32
|
rbx/box/packaging/boca/packager.py,sha256=KE-BpFZh8r7ftZJGmD6Zx1bWOTrbNhgS7i9k-yDtfK4,10740
|
33
33
|
rbx/box/packaging/contest_main.py,sha256=nMdgPE4OK_tsnUMdRI1cJwLpgxGrwW_mJjox0oOALWw,2757
|
@@ -45,12 +45,12 @@ rbx/box/retries.py,sha256=tRk2K1bXw2xnwkAj2CsktRHTEhw7YKcPxMQTT6mCy-E,4707
|
|
45
45
|
rbx/box/sanitizers/warning_stack.py,sha256=RI97_GJgdjTKIXY_r0EKp5h0qQQSDSdNDh5K7zINrqs,2861
|
46
46
|
rbx/box/schema.py,sha256=P1jVaeqe4OcotAJOqu3T5WD8DR-amZyyq3cau5rPiM8,17086
|
47
47
|
rbx/box/setter_config.py,sha256=s53talhwM6FTGDCcBhY7IlZ6_6mJ3PMp6V4kTtaSs50,4262
|
48
|
-
rbx/box/solutions.py,sha256=
|
48
|
+
rbx/box/solutions.py,sha256=MEpbLvD2Wnj9NZ4Fm5SqE1xQkg1TNgnfWUDd0IsG9RE,42666
|
49
49
|
rbx/box/solutions_test.py,sha256=TCowbxBG3SvDlFO5-qtBj_M_HrAHe0IJaI1XwoQ1d00,1718
|
50
|
-
rbx/box/state.py,sha256=
|
50
|
+
rbx/box/state.py,sha256=MMf3DvfQji0jKEliCHct2Tpp_0epL1tvP8HbHNArQIc,166
|
51
51
|
rbx/box/statements/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
52
52
|
rbx/box/statements/build_statements.py,sha256=uHlC3y3PtKaGUd2ZS_zYxi6-AKco6v_yd-lvm6BfrNA,12091
|
53
|
-
rbx/box/statements/builders.py,sha256=
|
53
|
+
rbx/box/statements/builders.py,sha256=6lYV-cnC-NXMnJf1wasbq_AMbjdIuPpMirm7QsjZI6s,11825
|
54
54
|
rbx/box/statements/joiners.py,sha256=jItNXkAbTjFQpPMgfDMW86n3vMTbaE8sgo9I8Yf4Txg,2886
|
55
55
|
rbx/box/statements/latex.py,sha256=LkcHwXjMFxbw--Gj9T1VkFKQFsXhY9dN7xZHpZycNW8,1346
|
56
56
|
rbx/box/statements/latex_jinja.py,sha256=7WBfn1h8DpqCAmSE6Av64HfURMnJ2AO4QX1CD72sz5E,7096
|
@@ -59,9 +59,9 @@ rbx/box/stresses.py,sha256=E4JU1JrUcikPA6QEACKnEOBkRocpEhswkF1iE7aRD5U,12147
|
|
59
59
|
rbx/box/stressing/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
60
60
|
rbx/box/stressing/finder_parser.py,sha256=jXpYNa4FyugzmHi3r96Uv4rU1krRQJc5Ihr9jf1cvNo,11918
|
61
61
|
rbx/box/stressing/generator_parser.py,sha256=oHZryjR3YohgaSO9WEirQ7b2e-98WgZStF0N99W4Thw,7380
|
62
|
-
rbx/box/tasks.py,sha256=
|
62
|
+
rbx/box/tasks.py,sha256=t_yZE7dqgh0vzxbmvuvsDbQq9BzbWALA5jUx3hZ_2pA,9863
|
63
63
|
rbx/box/testcase_extractors.py,sha256=T5vCW5qERlqitGrFP6RuITEVr9o8XQozNa4AsxfuV_Y,11871
|
64
|
-
rbx/box/testcase_utils.py,sha256=
|
64
|
+
rbx/box/testcase_utils.py,sha256=eeE7pr0vwxTEdHcZcpr9bIQlgIY5qI4-HpqR041LKxQ,6697
|
65
65
|
rbx/box/testcases/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
66
66
|
rbx/box/testcases/main.py,sha256=sLEgpVCDjRc3tJcU--DNWMmc58KgrkQe4zGzBorO-rk,5394
|
67
67
|
rbx/box/ui/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -83,14 +83,14 @@ rbx/grading/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
83
83
|
rbx/grading/caching.py,sha256=tnCQl08kUC0IYx5XKxfvaUGJIvEC_C2LPJHNv90clOw,12029
|
84
84
|
rbx/grading/conftest.py,sha256=iN9LUG1IQqhK5JjkctcP68v6675oYsiD2sQSgyLMTqw,960
|
85
85
|
rbx/grading/judge/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
86
|
-
rbx/grading/judge/cacher.py,sha256=
|
87
|
-
rbx/grading/judge/digester.py,sha256=
|
88
|
-
rbx/grading/judge/sandbox.py,sha256=
|
86
|
+
rbx/grading/judge/cacher.py,sha256=TDgYDhehnJIv64EFiXxPAtVADD8q9WcJa_BE9TsE-JM,17669
|
87
|
+
rbx/grading/judge/digester.py,sha256=gtOIe_iL4PEWA7OKelW1gjSI-nBvbOpDPJGV8VQyjSg,912
|
88
|
+
rbx/grading/judge/sandbox.py,sha256=Pc1JAh_ZZ46m-S10rmoYCA7ZWGpLCYB0UnhdzSFMDyY,24054
|
89
89
|
rbx/grading/judge/sandboxes/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
90
|
-
rbx/grading/judge/sandboxes/isolate.py,sha256=
|
91
|
-
rbx/grading/judge/sandboxes/stupid_sandbox.py,sha256=
|
92
|
-
rbx/grading/judge/sandboxes/timeit.py,sha256=
|
93
|
-
rbx/grading/judge/storage.py,sha256=
|
90
|
+
rbx/grading/judge/sandboxes/isolate.py,sha256=TToY4IEIBwdxlcvVn7s6lzoC3hKvsenF58kLxuBKAsg,25666
|
91
|
+
rbx/grading/judge/sandboxes/stupid_sandbox.py,sha256=O-HK6n5Swu3BiER8W03AeV_emmdDZqaoxL6WQc4-yBY,10626
|
92
|
+
rbx/grading/judge/sandboxes/timeit.py,sha256=HR_5CRyuY4OHZ1rTcEXZ796UfqlAJGX8HiZpgxOApkk,10475
|
93
|
+
rbx/grading/judge/storage.py,sha256=3vv0HvtenbUZBH33CB5ZzX66ppL22G6munBaAA9BgwQ,9418
|
94
94
|
rbx/grading/judge/test.py,sha256=ll0Iw7zyOpGdKPD_PGH7dvUkb4stQLu-ikbQnqJvuAc,944
|
95
95
|
rbx/grading/judge/testiso.py,sha256=v14DtkWiZFJ9AKMzrb0_vZKPWDt8jz8iIw1Z2O-Advk,1397
|
96
96
|
rbx/grading/steps.py,sha256=jpGsUMvyquaZraZlwf5YqxfQLK-F2OateFpJ8ZheQO8,25219
|
@@ -98,7 +98,7 @@ rbx/grading/steps_with_caching.py,sha256=nez2YwgauGXKRjhk6tQxTDGQ-HEk7KfZOeAPhsx
|
|
98
98
|
rbx/grading/steps_with_caching_run_test.py,sha256=mh4DRInrOGhnQFWD1SlcjDm_HvcSDFTDMSpAlG-Q5SI,15570
|
99
99
|
rbx/grading_utils.py,sha256=lL2KtSkOsMElqrRoApQTbFcqVOeHVWUDTMCa3IsLpC4,4484
|
100
100
|
rbx/hydration.py,sha256=WqbgIfCZNwqspVhMuUlx8-sNOYhq_ZWbeZnkcetuAZI,3669
|
101
|
-
rbx/main.py,sha256=
|
101
|
+
rbx/main.py,sha256=pFZreQhcoq-vIvWuVVeJEa8s_ka24dxF0WmaasarscE,2865
|
102
102
|
rbx/metadata.py,sha256=4eIHWlwwq-eAbpRDZkCovcGMbwOVVy-5JMmbLtk429w,3116
|
103
103
|
rbx/providers/__init__.py,sha256=gHXg1BTiXJ_0Z_HoVTZrqhi5IIZ57Dhy0pt7K2ETbA4,1378
|
104
104
|
rbx/providers/codeforces.py,sha256=HWQN3Zb9UfXgCfwcNMEk6m1HoXQ-UE2odVfZoPukyCg,2294
|
@@ -158,41 +158,10 @@ rbx/submitors/submitor.py,sha256=8q-Hbdahxt30ciT_R9j_xF6lEPUh9IcfAUnzjQjbvHU,457
|
|
158
158
|
rbx/test.py,sha256=tZyTrXDK8MLR-1TyCRxiOiNz-PhlXVpshfUGphakkT4,11830
|
159
159
|
rbx/testcase.py,sha256=yKOq3CAJZ1YTmInvnoIs0u1iJnRj_X85XiWbLI-p9d8,1951
|
160
160
|
rbx/testcase_rendering.py,sha256=nfmv6dSEqd4aR3TsaODwkKGK6AXty_DDKtWf_ejiQpI,2084
|
161
|
-
rbx/testdata/box1/gen1.cpp,sha256=Yx4uxlEtCeuC7NjrnRotONJBldiR5HSD6jvvVyjjh1I,91
|
162
|
-
rbx/testdata/box1/gen2.cpp,sha256=hRxLtUfj5ZvCrWF0G2is6-np9cVBPsP6Dj32-QLp3Bk,139
|
163
|
-
rbx/testdata/box1/genScript.py,sha256=HkMDSw7_ttj_2rpnZnlNMYGrj_PWzZzMDCUbCgXraVI,42
|
164
|
-
rbx/testdata/box1/hard-tle.sol.cpp,sha256=SnnhfKIngu6-xzTvHJ51stSPvXCsCKeHJnKr4hwzNZ8,389
|
165
|
-
rbx/testdata/box1/ole.cpp,sha256=7brjB5CWBDWOmRgwSOIQ8E65SGIJRrg7jQ4ClMYLmxY,253
|
166
|
-
rbx/testdata/box1/problem.rbx.yml,sha256=pA21zLlyyqM_iQP3vVrCBWVAMf8tJ5vy5y7T3UYwr-0,801
|
167
|
-
rbx/testdata/box1/re.sol.cpp,sha256=A6s7E-_2lG3ZRViecYy5vI6SElBOtpbhZUMcMQPIyQU,426
|
168
|
-
rbx/testdata/box1/sol.cpp,sha256=fSaVcFEq0_cYP-z2RfCvyTP4MwoE4nexwFDBgRpE_Fw,421
|
169
|
-
rbx/testdata/box1/tests/1.in,sha256=UciUkcfyYz8ZrSF_cy2DKt4L13PRmy8eh-Dlw7RbKdM,4
|
170
|
-
rbx/testdata/box1/tle-and-incorrect.sol.cpp,sha256=BM7iFwuYE4jD4Q16-pOD0RwQxxYZF-t-VwVgVcrEgao,582
|
171
|
-
rbx/testdata/box1/tle.sol.cpp,sha256=k3mboV4p_aNtM3VOm1vvxlVUiNfSEM1TP8hr-gnttYI,630
|
172
|
-
rbx/testdata/box1/validator.cpp,sha256=EWiKEWB6Nvke3SjBWHnkhkKJjwOqY_WX5kuXLxibABY,196
|
173
|
-
rbx/testdata/box1/wa.sol.cpp,sha256=qsHmvtLJOFI_sdvUT6ITqk7FJYqhrRTCmEIRdy4gSGE,407
|
174
|
-
rbx/testdata/caching/executable.py,sha256=WKRHNf_fprFJd1Fq1ubmQtR3mZzTYVNwKPLWuZ4HrWg,10
|
175
|
-
rbx/testdata/compatible,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
176
|
-
rbx/testdata/interactive/checker.cpp,sha256=ILPhx0x6XyahJs_zuMkB9D_6swWs7PJE2dALO4wBXFE,516
|
177
|
-
rbx/testdata/interactive/gen.cpp,sha256=XF8NezWJy2XFxp2O03eiSUZUH6uHfFIPuvsZ5mqohc8,235
|
178
|
-
rbx/testdata/interactive/interactor.cpp,sha256=2kcX4W9P2iqnNUTya2Cckoj-NO8jEIZoDAjTrPdpn8A,1319
|
179
|
-
rbx/testdata/interactive/problem.rbx.yml,sha256=LY0Ti-ZHLJCIwYwQ1dcX0WsAwAk4WwHIjLkzUD7DfX8,889
|
180
|
-
rbx/testdata/interactive/sols/af_ac_pe.cpp,sha256=GYDSmcyoZVtDbLlvMmJhMweb3jutgkjnZjHqaI9tJZE,1369
|
181
|
-
rbx/testdata/interactive/sols/af_ac_re.cpp,sha256=mlD0izWJIxwvbSLq3zkdBAZRfo8cOoaEty-w7swqJMk,1376
|
182
|
-
rbx/testdata/interactive/sols/af_ac_too_many_iter.cpp,sha256=k1bYYxDlXHz_RVnPeWyfTRzCctSctfxIsLc6l0nHCKM,1306
|
183
|
-
rbx/testdata/interactive/sols/af_inf_cout_with_flush.cpp,sha256=591Vfc7AqxgcR6fUMkb8mOS_jX8lXUnXnnghx3e2tks,1449
|
184
|
-
rbx/testdata/interactive/sols/af_inf_cout_without_flush.cpp,sha256=11fjgkxdaZvsT_0g4mtjHaaWjH4ciD3MduVJyv62-0Q,1425
|
185
|
-
rbx/testdata/interactive/sols/af_ml.cpp,sha256=h9FfzvtUdZFpJ95dTIf5JBJElIUy4R6wnnhcmalvBPo,1438
|
186
|
-
rbx/testdata/interactive/sols/af_tl_after_ans.cpp,sha256=oLXUMn9gZ06hA19UE5rxhnUl-cJ8tI_7J8bxqQ670dU,1334
|
187
|
-
rbx/testdata/interactive/sols/af_wa.cpp,sha256=zlE6aAVIcQvrdH-KUYLXsHOc8CgcuJmUNS-BxhNbL5Q,1364
|
188
|
-
rbx/testdata/interactive/sols/interactive-binary-search_mm_naive_cin.cpp,sha256=90ZUuIWehGmn4_L3wX_J4nRps9W1Po_kZrEJuWxUOIQ,281
|
189
|
-
rbx/testdata/interactive/sols/main.cpp,sha256=whWhcJfHP6QJ1DGaqcoDc_MDbqG_gfpD4hNAUT8vAa8,394
|
190
|
-
rbx/testdata/interactive/testplan.txt,sha256=ZPoU7O5nAasROa2evnaR3gHGDZsiKZ3PUTbtUHhe8rs,69
|
191
|
-
rbx/testdata/interactive/validator.cpp,sha256=KCxrwDqiBf8z6Ml1Xk9XSZbEtH35Ud7gy9ux-Ek2cPY,301
|
192
161
|
rbx/testing_utils.py,sha256=ZXMysGXpTtvS1lfLL38FuD5iSIyxi3ARjQePDrUmEtc,2067
|
193
162
|
rbx/utils.py,sha256=6e1eXRzNE-52D0UVtqclePxqR4Haiqt8qWCrSVjnGuE,4585
|
194
|
-
rbx_cp-0.5.
|
195
|
-
rbx_cp-0.5.
|
196
|
-
rbx_cp-0.5.
|
197
|
-
rbx_cp-0.5.
|
198
|
-
rbx_cp-0.5.
|
163
|
+
rbx_cp-0.5.46.dist-info/LICENSE,sha256=QwcOLU5TJoTeUhuIXzhdCEEDDvorGiC6-3YTOl4TecE,11356
|
164
|
+
rbx_cp-0.5.46.dist-info/METADATA,sha256=3rjgO4K3_womzC9XQhPR2R1JNTJTk2gEBxUrhNPBBec,3261
|
165
|
+
rbx_cp-0.5.46.dist-info/WHEEL,sha256=fGIA9gx4Qxk2KDKeNJCbOEwSrmLtjWCwzBz351GyrPQ,88
|
166
|
+
rbx_cp-0.5.46.dist-info/entry_points.txt,sha256=qBTLBOeifT1F00LWaEewRRE_jQPgvH7BUdJfZ-dYsFU,57
|
167
|
+
rbx_cp-0.5.46.dist-info/RECORD,,
|
rbx/testdata/box1/gen1.cpp
DELETED
rbx/testdata/box1/gen2.cpp
DELETED
rbx/testdata/box1/genScript.py
DELETED
@@ -1,26 +0,0 @@
|
|
1
|
-
#include <bits/stdc++.h>
|
2
|
-
#include <ctime>
|
3
|
-
|
4
|
-
using namespace std;
|
5
|
-
|
6
|
-
void busy_loop() {
|
7
|
-
double wait = 5.0;
|
8
|
-
int start = clock();
|
9
|
-
int end = clock();
|
10
|
-
while (((double) (end - start)) / CLOCKS_PER_SEC < wait)
|
11
|
-
{
|
12
|
-
end = clock();
|
13
|
-
}
|
14
|
-
}
|
15
|
-
|
16
|
-
int32_t main() {
|
17
|
-
ios::sync_with_stdio(false);
|
18
|
-
cin.tie(0);
|
19
|
-
|
20
|
-
int n; cin >> n;
|
21
|
-
|
22
|
-
busy_loop();
|
23
|
-
|
24
|
-
cout << "hard" << endl;
|
25
|
-
return 0;
|
26
|
-
}
|
rbx/testdata/box1/ole.cpp
DELETED
@@ -1,17 +0,0 @@
|
|
1
|
-
|
2
|
-
#include <bits/stdc++.h>
|
3
|
-
|
4
|
-
using namespace std;
|
5
|
-
|
6
|
-
int32_t main() {
|
7
|
-
ios::sync_with_stdio(false);
|
8
|
-
cin.tie(0);
|
9
|
-
|
10
|
-
int n;
|
11
|
-
cin >> n;
|
12
|
-
|
13
|
-
for (int i = 1; i <= 100000; i++) { // more than output limit of 100kb
|
14
|
-
cout << 123456 << "\n";
|
15
|
-
}
|
16
|
-
return 0;
|
17
|
-
}
|
@@ -1,39 +0,0 @@
|
|
1
|
-
---
|
2
|
-
name: "test-problem"
|
3
|
-
timeLimit: 1000
|
4
|
-
memoryLimit: 256
|
5
|
-
outputLimit: 100 # 100 kb
|
6
|
-
generators:
|
7
|
-
- name: "gen1"
|
8
|
-
path: "gen1.cpp"
|
9
|
-
- name: "gen2"
|
10
|
-
path: "gen2.cpp"
|
11
|
-
validator:
|
12
|
-
path: "validator.cpp"
|
13
|
-
testcases:
|
14
|
-
- name: "gen1"
|
15
|
-
testcaseGlob: "tests/*.in"
|
16
|
-
subgroups:
|
17
|
-
- name: "gen"
|
18
|
-
generators:
|
19
|
-
- name: "gen1"
|
20
|
-
- name: "gen2"
|
21
|
-
args: "424242"
|
22
|
-
- name: "genScript"
|
23
|
-
generatorScript:
|
24
|
-
path: "genScript.py"
|
25
|
-
solutions:
|
26
|
-
- path: "sol.cpp"
|
27
|
-
outcome: "ac"
|
28
|
-
- path: "wa.sol.cpp"
|
29
|
-
outcome: "fail"
|
30
|
-
- path: "re.sol.cpp"
|
31
|
-
outcome: "rte"
|
32
|
-
- path: "tle.sol.cpp"
|
33
|
-
outcome: "tle"
|
34
|
-
- path: "tle-and-incorrect.sol.cpp"
|
35
|
-
outcome: "tle"
|
36
|
-
- path: "hard-tle.sol.cpp"
|
37
|
-
outcome: "tle"
|
38
|
-
- path: "ole.cpp"
|
39
|
-
outcome: "ole"
|
rbx/testdata/box1/re.sol.cpp
DELETED
@@ -1,23 +0,0 @@
|
|
1
|
-
#include <bits/stdc++.h>
|
2
|
-
|
3
|
-
using namespace std;
|
4
|
-
|
5
|
-
int32_t main() {
|
6
|
-
ios::sync_with_stdio(false);
|
7
|
-
cin.tie(0);
|
8
|
-
|
9
|
-
int n; cin >> n;
|
10
|
-
|
11
|
-
vector<int> divisors;
|
12
|
-
assert(false);
|
13
|
-
for(int i = 0; i*i <= n; i++) {
|
14
|
-
if (n % i == 0) {
|
15
|
-
divisors.push_back(i);
|
16
|
-
divisors.push_back(n/i);
|
17
|
-
}
|
18
|
-
}
|
19
|
-
|
20
|
-
sort(divisors.begin(), divisors.end());
|
21
|
-
for (int x : divisors) cout << x << '\n';
|
22
|
-
return 0;
|
23
|
-
}
|
rbx/testdata/box1/sol.cpp
DELETED
@@ -1,22 +0,0 @@
|
|
1
|
-
#include <bits/stdc++.h>
|
2
|
-
|
3
|
-
using namespace std;
|
4
|
-
|
5
|
-
int32_t main() {
|
6
|
-
ios::sync_with_stdio(false);
|
7
|
-
cin.tie(0);
|
8
|
-
|
9
|
-
int n; cin >> n;
|
10
|
-
|
11
|
-
vector<int> divisors;
|
12
|
-
for(int i = 1; i*i <= n; i++) {
|
13
|
-
if (n % i == 0) {
|
14
|
-
divisors.push_back(i);
|
15
|
-
if (i != n/i) divisors.push_back(n/i);
|
16
|
-
}
|
17
|
-
}
|
18
|
-
|
19
|
-
sort(divisors.begin(), divisors.end());
|
20
|
-
for (int x : divisors) cout << x << '\n';
|
21
|
-
return 0;
|
22
|
-
}
|
rbx/testdata/box1/tests/1.in
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
777
|
@@ -1,33 +0,0 @@
|
|
1
|
-
#include <bits/stdc++.h>
|
2
|
-
#include <ctime>
|
3
|
-
|
4
|
-
using namespace std;
|
5
|
-
|
6
|
-
void busy_loop() {
|
7
|
-
double wait = 1.0;
|
8
|
-
int start = clock();
|
9
|
-
int end = clock();
|
10
|
-
while (((double) (end - start)) / CLOCKS_PER_SEC < wait)
|
11
|
-
{
|
12
|
-
end = clock();
|
13
|
-
}
|
14
|
-
}
|
15
|
-
|
16
|
-
int32_t main() {
|
17
|
-
ios::sync_with_stdio(false);
|
18
|
-
cin.tie(0);
|
19
|
-
|
20
|
-
int n; cin >> n;
|
21
|
-
busy_loop();
|
22
|
-
|
23
|
-
vector<int> divisors;
|
24
|
-
for(int i = 1; i*i <= n; i++) {
|
25
|
-
if (n % i == 0) {
|
26
|
-
divisors.push_back(i);
|
27
|
-
}
|
28
|
-
}
|
29
|
-
|
30
|
-
sort(divisors.begin(), divisors.end());
|
31
|
-
for (int x : divisors) cout << x << '\n';
|
32
|
-
return 0;
|
33
|
-
}
|
rbx/testdata/box1/tle.sol.cpp
DELETED
@@ -1,35 +0,0 @@
|
|
1
|
-
#include <bits/stdc++.h>
|
2
|
-
#include <ctime>
|
3
|
-
|
4
|
-
using namespace std;
|
5
|
-
|
6
|
-
void busy_loop() {
|
7
|
-
double wait = 1.0;
|
8
|
-
int start = clock();
|
9
|
-
int end = clock();
|
10
|
-
while (((double) (end - start)) / CLOCKS_PER_SEC < wait)
|
11
|
-
{
|
12
|
-
end = clock();
|
13
|
-
}
|
14
|
-
}
|
15
|
-
|
16
|
-
int32_t main() {
|
17
|
-
ios::sync_with_stdio(false);
|
18
|
-
cin.tie(0);
|
19
|
-
|
20
|
-
int n; cin >> n;
|
21
|
-
|
22
|
-
busy_loop();
|
23
|
-
|
24
|
-
vector<int> divisors;
|
25
|
-
for(int i = 1; i*i <= n; i++) {
|
26
|
-
if (n % i == 0) {
|
27
|
-
divisors.push_back(i);
|
28
|
-
if (i != n/i) divisors.push_back(n/i);
|
29
|
-
}
|
30
|
-
}
|
31
|
-
|
32
|
-
sort(divisors.begin(), divisors.end());
|
33
|
-
for (int x : divisors) cout << x << '\n';
|
34
|
-
return 0;
|
35
|
-
}
|
rbx/testdata/box1/validator.cpp
DELETED
rbx/testdata/box1/wa.sol.cpp
DELETED
@@ -1,22 +0,0 @@
|
|
1
|
-
#include <bits/stdc++.h>
|
2
|
-
|
3
|
-
using namespace std;
|
4
|
-
|
5
|
-
int32_t main() {
|
6
|
-
ios::sync_with_stdio(false);
|
7
|
-
cin.tie(0);
|
8
|
-
|
9
|
-
int n; cin >> n;
|
10
|
-
|
11
|
-
vector<int> divisors;
|
12
|
-
for(int i = 1; i*i <= n; i++) {
|
13
|
-
if (n % i == 0) {
|
14
|
-
divisors.push_back(i);
|
15
|
-
divisors.push_back(n/i);
|
16
|
-
}
|
17
|
-
}
|
18
|
-
|
19
|
-
sort(divisors.begin(), divisors.end());
|
20
|
-
for (int x : divisors) cout << x << '\n';
|
21
|
-
return 0;
|
22
|
-
}
|
@@ -1 +0,0 @@
|
|
1
|
-
print(42)
|
rbx/testdata/compatible
DELETED
File without changes
|