Commit Graph

16 Commits (039e06e43a69cb5959585d847087848e41b8eb09)

Author SHA1 Message Date
Jerry Jiarui XU 61f9e91c9f
Add syntax check in .py config (#330)
* Add syntax check in .py config

* rename validate
2020-06-10 23:07:59 +08:00
Jerry Jiarui XU a3ae781789
add reserved key in config (#315) 2020-06-04 14:55:28 +08:00
Wenwei Zhang 8ceb404ea6
Use mapping rather than dict for special keys (#304)
* Support path as a key in dict of config

* reformat test case

* update pre-commit version and fix format

* fix bug

* clean code

* reformat

* fix missing parts
2020-05-30 13:03:33 +08:00
Jerry Jiarui XU d5936d02e3
Make Config.dump() output in original file (#275)
* add dump() from for different file type

* remove exception
2020-05-11 21:48:56 +08:00
Jerry Jiarui XU a5b5193767
Fixed config import in config file (#261)
* fixed config import in code

* fixed isort
2020-05-01 21:55:07 +08:00
Jerry Jiarui XU 45a39dc6a8
make config merge a into b non-inplace (#254) 2020-04-29 15:09:27 +08:00
Jerry Jiarui XU 1e8a212187
Add DictAction and docs for config (#243)
* fixed merge_from_dict, add DictAction

* add config docs

* fixed format type

* change to easy example

* update docs

* update docs
2020-04-25 20:56:08 +08:00
Jerry Jiarui XU e87a04e3c7
add pretty_text (#220)
* add pretty_text

* add test cases

* add argument indent

* change pretty_text to property

* fixed format end
2020-04-03 21:18:34 +08:00
Kai Chen 12e5913bb9
Remove supports for python 2.7 and bump version to 0.4.0 (#211)
* remove supports for python 2.7

* fix the unit test for python 3.5

* add python 3.8 in CI

* try ubuntu 18.04 as the environment
2020-03-16 15:15:35 +08:00
Jerry Jiarui XU 6738cd3085
add base for config (#194)
* add base for config

* fixed format

* rm terminal width

* support multiple & recursive base

* add test case

* fix format

* add test construct

* minor fix

* add more test, rewrite merge from opt

* avoid depulicate keys

* delete imported config as module

* rename merge_from_dict
2020-03-15 20:29:17 +08:00
lizz c294d2713b
Support dot in config.py file (#207)
Signed-off-by: lizz <lizz@sensetime.com>
2020-03-12 23:20:50 +08:00
Kai Chen 10fa1eeaf4
Add copyright header (#171)
* add copyright header

* change # to // for cpp files
2020-01-10 13:34:42 +08:00
Kai Chen eae81c1e86
Add yapf and isort to travis (#96)
* add yapf and isort to travis

* minor formatting

* remove blank lines

* skip unit tests for progressbar when python2

* update travis to ubuntu 16.04

* use a newer version ffmpeg

* add -y to add-apt-repository
2019-07-30 23:15:56 +08:00
Kai Chen b98980b77b add some unit tests 2018-10-07 17:45:41 +08:00
Kai Chen 31e684fcfe bug fix: raise exceptions for missing config keys 2018-09-20 14:15:12 +08:00
Kai Chen 4adf7006b0 add config class 2018-08-27 20:25:52 +08:00