141 Commits

Author SHA1 Message Date
645b818be2 Remove Dependabot 2021-02-15 12:00:18 +01:00
5f1c75a24b DEPRECATED (#121) 2020-12-02 17:43:56 +01:00
375e6813df Fix Upgrade API for DSM 6.1 (#106) 2020-11-19 00:00:12 +01:00
ca194c352e Bump sphinx from 3.3.0 to 3.3.1 (#102) 2020-11-18 22:12:53 +00:00
dc41e9ea6e Bump actions/download-artifact from v2.0.5 to v2.0.6 (#103) 2020-11-18 22:12:43 +00:00
e1217fe3db Bump actions/upload-artifact from v2.2.0 to v2.2.1 (#104) 2020-11-18 22:12:29 +00:00
4d422576ca Bump codecov/codecov-action from v1.0.14 to v1.0.15 (#105) 2020-11-18 22:12:16 +00:00
bbb73e4e50 Bump requests from 2.24.0 to 2.25.0 (#101) 2020-11-18 22:11:58 +00:00
23b6fab0fb Bump actions/cache from v2.1.2 to v2.1.3 (#100) 2020-11-11 19:26:01 +00:00
e1708902ed Update actions/checkout requirement to v2.3.4 (#99)
Updates the requirements on [actions/checkout](https://github.com/actions/checkout) to permit the latest version.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](5a4ac9002d)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-04 09:52:47 +01:00
ecf830fab3 Bump sphinx from 3.2.1 to 3.3.0 (#98) 2020-11-03 15:25:56 +00:00
48e37ee6e6 Bump reorder-python-imports from 2.3.5 to 2.3.6 (#97) 2020-11-02 14:23:00 +00:00
e08401bcd5 Bump pre-commit from 2.8.1 to 2.8.2 (#96) 2020-11-02 14:16:07 +00:00
b73b87ae55 Add missing code owner (#95) 2020-10-31 00:01:31 +01:00
090cf3e020 Add CODEOWNERS (#94) 2020-10-30 23:57:25 +01:00
efb0716516 Fix MAC address may be empty if NAS uses PPPoE (#93) 2020-10-29 13:51:54 +01:00
b81598640c Bump pytest from 6.1.1 to 6.1.2 (#91) 2020-10-29 08:07:43 +00:00
55f243aa8e Bump pre-commit from 2.7.1 to 2.8.1 (#90) 2020-10-29 08:01:18 +00:00
fc2bb6cf47 Add Upgrade detail infos (#86)
* get update detail info

* missing new line at the end

* black compliant

* flake8 compliant

* fix pre-commit

* Update tests/api_data/dsm_6/core/const_6_core_upgrade.py

* Update tests/api_data/dsm_6/core/const_6_core_upgrade.py

Co-authored-by: Quentame <polletquentin74@me.com>
2020-10-27 10:45:26 +01:00
d4f66ebf3f Bump poetry from 1.1.3 to 1.1.4 in /.github/workflows (#89) 2020-10-26 08:12:30 +00:00
ef0546c354 Bump virtualenv from 20.0.35 to 20.1.0 in /.github/workflows (#88) 2020-10-26 08:06:08 +00:00
61a19723f4 Bump pygments from 2.7.1 to 2.7.2 (#87) 2020-10-26 08:05:55 +00:00
336731cbc2 Fix a lot of flake8 linting errors (#85)
* Restore standard ignore list for flake8

In previous version we add some checks to ignore list.

* Fix all B950 flake8 errors (line too long)

Fix the code and add 2 per-file-ignore paterns for readability reasons.

* Fix F401 flake8 errors (import not used)

* Fix E302 flake8 errors

* Fix E266 flake8 errors

* Fix D107 flake8 errors

* Fix Dxxx Flake8 errors

* Add explanation on flake8 ignored rules

* Remove pyling inline ignore rules

pylint is no more used and replaced by flake8.

* Remove D102 flake8 errors.

* Apply suggestions from code review

Co-authored-by: Quentame <polletquentin74@me.com>

Co-authored-by: Quentame <polletquentin74@me.com>
2020-10-25 19:49:10 +01:00
708e2b2342 Bump mypy from 0.782 to 0.790 (#84) 2020-10-21 20:26:51 +00:00
144824db36 Bump release-drafter/release-drafter from v5.12.0 to v5.12.1 (#81) 2020-10-21 20:22:07 +00:00
3410010f70 Bump poetry from 1.0.10 to 1.1.3 in /.github/workflows (#82) 2020-10-21 20:21:17 +00:00
62623c41d1 Bump pre-commit-hooks from 3.2.0 to 3.3.0 (#83) 2020-10-21 20:20:30 +00:00
9622f5d314 Migrate to poetry, nox and GitHub actions (#78)
* Replace setup files with pyproject.toml

Now we can use poetry to manage the package.
poetry install to install the package in a venv
poetry run ... to launch pylint, pytest or black

* Add CI with GitHub Action

Add a tests and release workflow
Add release drafter
Add dependabot

* Remove old CI based on travis and pylint

* Add linting configuration files

Linting mainly based on flake8 and plugins.
Add specific files for darglint and mypy.

* Update .gitignore

* Add test suite with nox and pre-commit

Test suite inculde pre-commit, safety, mypy, tests, typguard and documentation
checks.

* Add .gitattributes

* Update code coverage target to 80%

* Code style update by Black

* Update poetry lock file

* Deactivate temporarly some linting tests

* Add a contributing guide

* Remove Python 3.6 in GitHub Action

* Patch noxfile.py to be able to test mypy session

* Rebase version to 1.0.0
2020-10-21 21:38:25 +02:00
a4edbd3348 Release 1.0.0 1.0.0 2020-10-21 13:40:23 +02:00
c9b8de00c5 Add logout method (#79) 2020-10-20 23:40:57 +02:00
4132155ab8 Move python file in src folder (#77)
Preparation of migration to cookiecutter-hypermodern-python template
2020-10-20 00:31:59 +02:00
08035384ad Add parameter verify_ssl (#76)
* add parameter ssl_validation

* add parameter ssl_validation

* rename to verify_ssl

* rename to verify_ssl

* object property use_https not needed

* black

* VALID_SSL_VERIFICATION --> VALID_SSL_VERIFY

* disable_warnings on urllib only if not verify_ssl

* VALID_SSL_VERIFY --> VALID_VERIFY_SSL

* VALID_SSL --> VALID_HTTPS

* Add test

* black again

* Add test

Co-authored-by: Quentin POLLET <polletquentin74@me.com>
2020-10-19 23:57:58 +02:00
590f2d9a17 Add Core System and Upgrade APIs info and actions (#72)
* add syno system data and actions

* add system usage examples

* add upgrade information

* Fix default login Exception (#73)

* Migrate to Python 3.6+ (#70)

* Migrate to Python 3.6+

Drop support of Python < 3.6
- remove six + future deps + usage
- update deps
- remove encoding
- remove (object)

* Fix pylint

- pip3 super() style
- remove simplejson dep + usage

* Black format

* lint setup

* Travix CI py version

* Use f string

* Basic Typing

* Revert setup version bump

* correct alphabetically order

* add SynoCoreUpgrade instance

* simplify update_available()

* correct defaults of .get()

* harmonize use of API_KEY

* update docs

* add test data

* due to #70

* update docs

* solve conflict

* add syno system data and actions

* add system usage examples

* add upgrade information

* correct alphabetically order

* add SynoCoreUpgrade instance

* simplify update_available()

* correct defaults of .get()

* harmonize use of API_KEY

* update docs

* add test data

* due to #70

* update docs

* Apply suggestions from code review: function return type

* Don't save previous update data

Co-authored-by: Quentame <polletquentin74@me.com>
2020-10-18 20:01:24 +02:00
eb26278b8a Fix Surveillance Station update when no cameras linked (#75) 2020-10-18 19:19:31 +02:00
212f029478 Migrate to Python 3.6+ (#70)
* Migrate to Python 3.6+

Drop support of Python < 3.6
- remove six + future deps + usage
- update deps
- remove encoding
- remove (object)

* Fix pylint

- pip3 super() style
- remove simplejson dep + usage

* Black format

* lint setup

* Travix CI py version

* Use f string

* Basic Typing

* Revert setup version bump
2020-10-15 00:48:35 +02:00
ce8c2c4e64 Fix default login Exception (#73) 2020-10-14 23:58:38 +02:00
74ad8370c6 Fix Download & Surveillance Station updates when removing entity (#69) 2020-09-29 22:53:02 +02:00
a274a44f81 Release 0.9.0 0.9.0 2020-09-08 13:37:15 +02:00
85afea6e12 Add Download Station get_stat() (#68) 2020-09-08 13:35:06 +02:00
ca56dccee9 Add DownloadStation (#62)
* Add DownloadStation

* Add test

* Add resume, fix create

* Add get_config, create destination

* Added readme
2020-09-07 23:26:41 +02:00
27379e7cd6 Add Shared Folders support (#61)
* Minimal Shared Folders support

* Bugfixes in share.py and README updates

* Added tests for shares

* Formatted with black

* Added myself as a contributor.

* Support for extended attributes for shares.

* Tidied up some comments.

* Reformatted with Black

* Fixed tests

* Fixed tests, maybe

* addressing initial feedback on pull request \#61

* Working on tests, can't repro failure locally.

* Updated test per comment on #61 and added a generic to shares.

* Fixed pylint complaint

* Tried to fix the test again, didn\'t

* Ran Black

* Implemented feedback on pull request.

* Updated tests to reflect the move of shares to UUID

* Fix CI

* Rename to SynoCoreShare

* Remove useless _execute_request() special treatment

Co-authored-by: Quentin POLLET <polletquentin74@me.com>
2020-07-12 12:45:28 +02:00
1a012611ff Refactor update: @property does not make I/O, use update() for each API (#59) 2020-06-29 02:17:09 +02:00
660d1e661f Add SurveillanceStation (#57)
* Add SurveillanceStation

* Fix error in error handling

* Fix Python 2.7 pylint

* Capitalize Camera_API.List

Co-authored-by: Xiaonan Shen <s@sxn.dev>

* Capitalize Camera_API.GetSnapshot + id instead of cameraId

Co-authored-by: Xiaonan Shen <s@sxn.dev>

* Join idList

Co-authored-by: Xiaonan Shen <s@sxn.dev>

* black

* pylint

* methods are case sensitive

* Backward compat with Camera.GetSnapshot cameraId

* raw live view data

* Add Info.GetInfo

* Use Camera.GetInfo

* Fix TakeSnapshot blSave

* Fix content type

* Add SurveillanceStation api data

* Add unit test, miss SYNO.SurveillanceStation.Camera GetInfo

* Do not use Camera.LetInfo but .List with max_version 7

* Fix Switch on param

Co-authored-by: Xiaonan Shen <s@sxn.dev>

* Update camera list api data

* Add more API data

* Take care of new test data

* Add RTSP test + previous library code owners

Co-authored-by: Joe Lu <snjoetw@gmail.com>

Co-authored-by: David <dconnor@gmail.com>

Co-authored-by: Aleksander Lyse <aleksander.lyse@gmail.com>

Co-authored-by: Loïc Gerbaud <info@loicg.net>

* Fix Py27 pipe

* Fix : get_all_cameras() test

* Update README for SurveillanceStation

* Fix README
2020-06-29 01:25:05 +02:00
dc3e7bd4df Release 0.8.2 0.8.2 2020-06-03 18:43:59 +02:00
6904c60355 Add request timeout (10s default) (#56) 2020-06-02 13:21:07 +02:00
fb5f5b0aa5 Fix POST params (#55) 2020-06-02 11:37:55 +02:00
796a1a7dc5 Add SynoSecurity status_by_check + add outOfDate test (#54) 2020-06-02 10:57:29 +02:00
1286f4aaa2 Release 0.8.1 0.8.1 2020-05-15 00:36:29 +02:00
c96d2b2de0 Fix login with space in password (#50) 2020-05-15 00:31:03 +02:00
9a523c75a2 Make Exceptions detailed (#52) 2020-05-15 00:11:25 +02:00