Skip to content

Commit 6a52363

Browse files
Release/1.1.1 (kyuridenamida#94)
* Update change log * Update version * Fix bug around version notification * Update README
1 parent 75b629e commit 6a52363

File tree

4 files changed

+35
-9
lines changed

4 files changed

+35
-9
lines changed

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# Change Log
22

3+
## 1.1.1 / 2018-02-14
4+
- [#84](https://github.com/kyuridenamida/atcoder-tools/pull/84) Output stdout even when getting RE or TLE.
5+
- [#86](https://github.com/kyuridenamida/atcoder-tools/pull/86) Support Rust
6+
- Thanks for [@fukatani](https://github.com/fukatani/)'s contribution and [@koba-e964](https://github.com/koba-e964/)'s code review!
7+
- [#88](https://github.com/kyuridenamida/atcoder-tools/pull/88) Fix a bug you can't specify a code to submit by --code for submit command.
8+
- [#92](https://github.com/kyuridenamida/atcoder-tools/pull/92) Add unit tests to check if the default templates / code generators are correct, including a bug fix of Java code generator about two-dimensional input.
9+
10+
311
## 1.1.0 / 2018-01-18
412
This version includes a breaking change. Deleting --replacement parameter requires some changes in your template. See [#79](https://github.com/kyuridenamida/atcoder-tools/pull/79).
513
- [#80](https://github.com/kyuridenamida/atcoder-tools/pull/80) Anything configurable from command line is configurable from toml

README.md

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,16 @@ Python 3.5 以降で動作する [AtCoder](http://atcoder.jp/) からサンプ
1010
- AtCoderへのログイン,入出力例データなどの抽出
1111
- 枝刈り探索による高精度・高速な入力フォーマット解析 (ARC、ABC、AGCについては約9割ほど)
1212
- 問題文中に含まれるMOD値やYES/NO文字列等の定数値抽出
13-
- 入力フォーマット解析結果や抽出した定数値を用いたテンプレートコードの自動生成(C++, Java, Rust)
13+
- コード提出機能
14+
- 入力フォーマット解析結果や抽出した定数値を用いたテンプレートからのコード自動生成(以下の表に記載されている言語をサポートしています)
1415
- カスタムテンプレートに対応
1516
- 他言語対応のためのコントリビューション(≒中間形式からコードに変換する部分のPR)を募集中です!
16-
- コード提出機能
17+
18+
|対応言語 |Contributor 1|Contributor 2|
19+
|:---:|:---:|:---:|
20+
|C++|[@kyuridenamida](https://github.com/kyuridenamida/) (generator, template)|[@asi1024](https://github.com/asi1024/) (template)|
21+
|Java|[@kyuridenamida](https://github.com/kyuridenamida/) (generator, template)||
22+
|Rust|[@fukatani](https://github.com/fukatani/) (generator, template)|[@koba-e964](https://github.com/koba-e964/) (template, CR)|
1723

1824
## How to install
1925
`pip3 install atcoder-tools`
@@ -71,8 +77,10 @@ optional arguments:
7177
--lang LANG Programming language of your template code, cpp or java.
7278
[Default] cpp
7379
--template TEMPLATE File path to your template code
74-
[Default (C++)] /atcoder-tools/atcodertools/tools/templates/cpp/default_template.cpp
75-
[Default (Java)] /atcoder-tools/atcodertools/tools/templates/java/default_template.java
80+
[Default (C++)] /atcodertools/tools/templates/default_template.cpp
81+
[Default (Java)] /atcodertools/tools/templates/default_template.java
82+
[Default (Rust)] /atcodertools/tools/templates/default_template.rs
83+
7684
--parallel Prepare problem directories asynchronously using multi processors.
7785
--save-no-session-cache
7886
Save no session cache to avoid security risk
@@ -224,3 +232,6 @@ int main(){
224232
## Author
225233

226234
[kyuridenamida](https://github.com/kyuridenamida) ([@kyuridenamida](https://twitter.com/kyuridenamida))
235+
236+
## 免責
237+
このソフトウェア等に起因するいかなる損害に対しても、[@kyuridenamida](https://github.com/kyuridenamida)並びにこのソフトウェアの開発者達は何ら責任を負いません。
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "1.1.0"
1+
__version__ = "1.1.1"

atcodertools/release_management/version_check.py

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import time
44

55
import requests
6-
6+
from atcodertools.release_management.version import __version__
77
from atcodertools.fileutils.artifacts_cache import get_cache_file_path
88

99

@@ -26,10 +26,17 @@ def _get_latest_version_cache():
2626
if not os.path.exists(cache_file_path):
2727
return None
2828
with open(cache_file_path, 'r') as f:
29-
version, timestamp_sec = f.read().split()
29+
info = f.read().split()
30+
version, timestamp_sec = info[:2]
31+
32+
if len(info) >= 3:
33+
captured_version = info[2]
34+
else:
35+
captured_version = None
36+
3037
timestamp_sec = float(timestamp_sec)
3138

32-
if time.time() - timestamp_sec > HOUR_IN_SEC:
39+
if time.time() - timestamp_sec > HOUR_IN_SEC or __version__ != captured_version:
3340
return None
3441

3542
return version
@@ -38,7 +45,7 @@ def _get_latest_version_cache():
3845
def store_version_cache(version):
3946
os.makedirs(os.path.dirname(cache_file_path), exist_ok=True)
4047
with open(cache_file_path, 'w') as f:
41-
f.write("{} {}".format(version, time.time()))
48+
f.write("{} {} {}".format(version, time.time(), __version__))
4249

4350

4451
def get_latest_version(use_cache=True):

0 commit comments

Comments
 (0)