Skip to content

Commit 01a01f7

Browse files
authored
Merge pull request #387 from online-judge-tools/atcoder
Allow users to use AtCoder's system cases
2 parents 75b7b0f + 09afd50 commit 01a01f7

File tree

4 files changed

+5
-1
lines changed

4 files changed

+5
-1
lines changed

.verify-helper/docs/static/document.ja.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,7 @@ verification_file_suffix = ".test.sed"
113113
| [Library Checker](https://judge.yosupo.jp/) | |
114114
| [Aizu Online Judge](https://onlinejudge.u-aizu.ac.jp/home) | |
115115
| [HackerRank](https://www.hackerrank.com/) | たぶん動きますが保証はしません。 |
116+
| [AtCoder](https://atcoder.jp) | 環境変数 `DROPBOX_TOKEN` の設定が必要です。突然動かなくなる可能性があります。 |
116117
| [yukicoder](https://yukicoder.me) | 環境変数 `YUKICODER_TOKEN` の設定が必要です。[ヘルプ - yukicoder](https://yukicoder.me/help) の「ログインしてないと使えない機能をAPIとして使いたい」の節や [暗号化されたシークレットの作成と利用 - GitHub ヘルプ](https://help.github.com/ja/actions/configuring-and-managing-workflows/creating-and-storing-encrypted-secrets#creating-encrypted-secrets) 参考にして設定してください。 |
117118

118119
これらの他サービスはテストケースを利用できる形で公開してくれていないため利用できません。

.verify-helper/docs/static/document.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@ verification_file_suffix = ".test.sed"
112112
| [Library Checker](https://judge.yosupo.jp/) | |
113113
| [Aizu Online Judge](https://onlinejudge.u-aizu.ac.jp/home) | |
114114
| [HackerRank](https://www.hackerrank.com/) | |
115+
| [AtCoder](https://atcoder.jp) | You must set the `DROPBOX_TOKEN` environment variable. It may suddenly stop working. |
115116
| [yukicoder](https://yukicoder.me) | You must set the `YUKICODER_TOKEN` environment variable. See 「ログインしてないと使えない機能をAPIとして使いたい」 in [ヘルプ - yukicoder](https://yukicoder.me/help) and [Creating and using encrypted secrets - GitHub Help](https://help.github.com/en/actions/configuring-and-managing-workflows/creating-and-storing-encrypted-secrets). |
116117

117118
Other judging platforms do not currently publish the test cases in usable forms, and so are not currently supported.

onlinejudge_verify/verify.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,8 @@ def verify_file(path: pathlib.Path, *, compilers: List[str], tle: float, jobs: i
7979
exec_command(['sleep', '2'])
8080
command = ['oj', 'download', '--system', '-d', str(directory / 'test'), '--silent', url]
8181

82+
if os.environ.get('DROPBOX_TOKEN'):
83+
command += ['--dropbox-token', os.environ['DROPBOX_TOKEN']]
8284
if os.environ.get('YUKICODER_TOKEN'):
8385
command += ['--yukicoder-token', os.environ['YUKICODER_TOKEN']]
8486
try:

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
install_requires=[
1414
'colorlog',
1515
'pyyaml',
16-
'online-judge-tools >= 8.0.0',
16+
'online-judge-tools >= 11.3.0',
1717
'setuptools',
1818
'toml',
1919
'importlab',

0 commit comments

Comments
 (0)