aioautomower 0.0.0.post1__tar.gz

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.
Files changed (35) hide show
  1. aioautomower-0.0.0.post1/LICENSE +21 -0
  2. aioautomower-0.0.0.post1/PKG-INFO +106 -0
  3. aioautomower-0.0.0.post1/README.md +74 -0
  4. aioautomower-0.0.0.post1/pyproject.toml +439 -0
  5. aioautomower-0.0.0.post1/src/aioautomower/__init__.py +11 -0
  6. aioautomower-0.0.0.post1/src/aioautomower/auth.py +188 -0
  7. aioautomower-0.0.0.post1/src/aioautomower/commands.py +381 -0
  8. aioautomower-0.0.0.post1/src/aioautomower/const.py +66 -0
  9. aioautomower-0.0.0.post1/src/aioautomower/exceptions.py +49 -0
  10. aioautomower-0.0.0.post1/src/aioautomower/model/__init__.py +104 -0
  11. aioautomower-0.0.0.post1/src/aioautomower/model/model.py +130 -0
  12. aioautomower-0.0.0.post1/src/aioautomower/model/model_battery.py +12 -0
  13. aioautomower-0.0.0.post1/src/aioautomower/model/model_calendar.py +239 -0
  14. aioautomower-0.0.0.post1/src/aioautomower/model/model_capabilities.py +16 -0
  15. aioautomower-0.0.0.post1/src/aioautomower/model/model_message.py +53 -0
  16. aioautomower-0.0.0.post1/src/aioautomower/model/model_metadata.py +19 -0
  17. aioautomower-0.0.0.post1/src/aioautomower/model/model_mower.py +281 -0
  18. aioautomower-0.0.0.post1/src/aioautomower/model/model_planner.py +113 -0
  19. aioautomower-0.0.0.post1/src/aioautomower/model/model_positions.py +20 -0
  20. aioautomower-0.0.0.post1/src/aioautomower/model/model_settings.py +37 -0
  21. aioautomower-0.0.0.post1/src/aioautomower/model/model_statistics.py +58 -0
  22. aioautomower-0.0.0.post1/src/aioautomower/model/model_stay_out_zones.py +27 -0
  23. aioautomower-0.0.0.post1/src/aioautomower/model/model_system.py +14 -0
  24. aioautomower-0.0.0.post1/src/aioautomower/model/model_token.py +33 -0
  25. aioautomower-0.0.0.post1/src/aioautomower/model/model_work_areas.py +29 -0
  26. aioautomower-0.0.0.post1/src/aioautomower/model/utils.py +26 -0
  27. aioautomower-0.0.0.post1/src/aioautomower/model_input/__init__.py +28 -0
  28. aioautomower-0.0.0.post1/src/aioautomower/model_input/model_event.py +50 -0
  29. aioautomower-0.0.0.post1/src/aioautomower/model_input/model_message.py +33 -0
  30. aioautomower-0.0.0.post1/src/aioautomower/model_input/model_rest.py +150 -0
  31. aioautomower-0.0.0.post1/src/aioautomower/py.typed +0 -0
  32. aioautomower-0.0.0.post1/src/aioautomower/session.py +349 -0
  33. aioautomower-0.0.0.post1/src/aioautomower/timeline.py +108 -0
  34. aioautomower-0.0.0.post1/src/aioautomower/tz_util.py +27 -0
  35. aioautomower-0.0.0.post1/src/aioautomower/utils.py +102 -0
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2024 Thomas Peter Protzner
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,106 @@
1
+ Metadata-Version: 2.3
2
+ Name: aioautomower
3
+ Version: 0.0.0.post1
4
+ Summary: MPython module to talk to Husqvarna Automower.
5
+ License: MIT
6
+ Keywords: Husqvarna,Automower,api,async,client
7
+ Author: Thomas Peter Protzner
8
+ Author-email: thomas.protzner@gmail.com
9
+ Requires-Python: >=3.11,<4.0
10
+ Classifier: Development Status :: 5 - Production/Stable
11
+ Classifier: Framework :: AsyncIO
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: License :: OSI Approved :: MIT License
14
+ Classifier: Natural Language :: English
15
+ Classifier: Programming Language :: Python :: 3
16
+ Classifier: Programming Language :: Python :: 3.11
17
+ Classifier: Programming Language :: Python :: 3.12
18
+ Classifier: Programming Language :: Python :: 3.13
19
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
20
+ Requires-Dist: PyJWT (>=2.8.0,<3.0.0)
21
+ Requires-Dist: aiohttp (>=3.9.3,<4.0.0)
22
+ Requires-Dist: ical (>=8.0.1)
23
+ Requires-Dist: mashumaro (>=3.12,<4.0)
24
+ Requires-Dist: python-dateutil (>=2.9.0-post.0,<3.0.0)
25
+ Requires-Dist: tzlocal (>=5.2,<6.0)
26
+ Project-URL: Documentation, https://github.com/Thomas55555/aioautomower
27
+ Project-URL: Homepage, https://github.com/Thomas55555/aioautomower
28
+ Project-URL: Issues, https://github.com/Thomas55555/aioautomower/issues
29
+ Project-URL: Repository, https://github.com/Thomas55555/aioautomower
30
+ Description-Content-Type: text/markdown
31
+
32
+ # Aioautomower
33
+
34
+ [![codecov](https://codecov.io/gh/Thomas55555/aioautomower/graph/badge.svg?token=2BG3S61T6K)](https://codecov.io/gh/Thomas55555/aioautomower)
35
+ [![Python Versions](https://img.shields.io/pypi/pyversions/aioautomower)](https://pypi.org/project/aioautomower/)
36
+ [![License](https://img.shields.io/github/license/Thomas55555/aioautomower.svg)](LICENSE.md)
37
+
38
+ Asynchronous library to communicate with the Automower Connect API
39
+ To use this library, you need to register on the [Husqvarna Developers Portal](https://developer.husqvarnagroup.cloud/).
40
+ And connect your account to the `Authentication API` and the `Automower Connect API`.
41
+
42
+ ## Quickstart
43
+
44
+ In order to use the library, you'll need to do some work yourself to get authentication
45
+ credentials. This depends a lot on the context (e.g. redirecting to use OAuth via web)
46
+ but should be easy to incorporate using Husqvarna's authentication examples. See
47
+ Husqvarna's [Authentication API](https://developer.husqvarnagroup.cloud/apis/authentication-api) for details.
48
+
49
+ You will implement `AbstractAuth` to provide an access token. Your implementation
50
+ will handle any necessary refreshes. You can invoke the service with your auth implementation
51
+ to access the API.
52
+
53
+ You need at least:
54
+
55
+ - Python 3.11+
56
+ - [Poetry][poetry-install]
57
+
58
+ For a first start you can run the `example.py`, by doing the following steps
59
+
60
+ - `git clone https://github.com/Thomas55555/aioautomower.git`
61
+ - `cd aioautomower`
62
+ - `poetry install`
63
+ - Enter your personal `client_id` and `client_secret` in the `_secrets.yaml` and rename it to `secrets.yaml`
64
+ - Run with `poetry run ./example.py`
65
+
66
+ ## Contributing
67
+
68
+ This is an active open-source project. We are always open to people who want to use the code or contribute to it.
69
+ This Python project is fully managed using the [Poetry][poetry] dependency manager.
70
+
71
+ As this repository uses the [pre-commit][pre-commit] framework, all changes
72
+ are linted and tested with each commit. You can run all checks and tests
73
+ manually, using the following command:
74
+
75
+ ```bash
76
+ poetry run pre-commit run --all-files
77
+ ```
78
+
79
+ To run just the Python tests:
80
+
81
+ ```bash
82
+ poetry run pytest
83
+ ```
84
+
85
+ To update snapshots:
86
+
87
+ ```bash
88
+ poetry run pytest --snapshot-update
89
+ ```
90
+
91
+ [poetry-install]: https://python-poetry.org/docs/#installation
92
+ [poetry]: https://python-poetry.org
93
+ [pre-commit]: https://pre-commit.com/
94
+
95
+
96
+ # Buying Equipment
97
+
98
+ Many mowers are available from your local garden dealer or major online retailers. Another like, the compact ideal for small and flat lawns, is available on Amazon.
99
+ The links provided below are affiliate links, so if you prefer shopping on Amazon and decide to purchase something there, you’ll also be supporting me at no additional cost to you.
100
+ Alternatively, if you'd like to support the project directly, consider contributing through [GitHub sponsors](https://github.com/sponsors/Thomas55555).
101
+ Here are some affiliate links to support my work:
102
+ - [Automower R4 Aspire](https://amzn.to/3Z987Oc)
103
+ - [Endurence blades](https://amzn.to/3OyK1YD)
104
+ - [Regular blades](https://amzn.to/3ZCn8Zt)
105
+ - [Cabel connector](https://amzn.to/4f3OtJn)
106
+
@@ -0,0 +1,74 @@
1
+ # Aioautomower
2
+
3
+ [![codecov](https://codecov.io/gh/Thomas55555/aioautomower/graph/badge.svg?token=2BG3S61T6K)](https://codecov.io/gh/Thomas55555/aioautomower)
4
+ [![Python Versions](https://img.shields.io/pypi/pyversions/aioautomower)](https://pypi.org/project/aioautomower/)
5
+ [![License](https://img.shields.io/github/license/Thomas55555/aioautomower.svg)](LICENSE.md)
6
+
7
+ Asynchronous library to communicate with the Automower Connect API
8
+ To use this library, you need to register on the [Husqvarna Developers Portal](https://developer.husqvarnagroup.cloud/).
9
+ And connect your account to the `Authentication API` and the `Automower Connect API`.
10
+
11
+ ## Quickstart
12
+
13
+ In order to use the library, you'll need to do some work yourself to get authentication
14
+ credentials. This depends a lot on the context (e.g. redirecting to use OAuth via web)
15
+ but should be easy to incorporate using Husqvarna's authentication examples. See
16
+ Husqvarna's [Authentication API](https://developer.husqvarnagroup.cloud/apis/authentication-api) for details.
17
+
18
+ You will implement `AbstractAuth` to provide an access token. Your implementation
19
+ will handle any necessary refreshes. You can invoke the service with your auth implementation
20
+ to access the API.
21
+
22
+ You need at least:
23
+
24
+ - Python 3.11+
25
+ - [Poetry][poetry-install]
26
+
27
+ For a first start you can run the `example.py`, by doing the following steps
28
+
29
+ - `git clone https://github.com/Thomas55555/aioautomower.git`
30
+ - `cd aioautomower`
31
+ - `poetry install`
32
+ - Enter your personal `client_id` and `client_secret` in the `_secrets.yaml` and rename it to `secrets.yaml`
33
+ - Run with `poetry run ./example.py`
34
+
35
+ ## Contributing
36
+
37
+ This is an active open-source project. We are always open to people who want to use the code or contribute to it.
38
+ This Python project is fully managed using the [Poetry][poetry] dependency manager.
39
+
40
+ As this repository uses the [pre-commit][pre-commit] framework, all changes
41
+ are linted and tested with each commit. You can run all checks and tests
42
+ manually, using the following command:
43
+
44
+ ```bash
45
+ poetry run pre-commit run --all-files
46
+ ```
47
+
48
+ To run just the Python tests:
49
+
50
+ ```bash
51
+ poetry run pytest
52
+ ```
53
+
54
+ To update snapshots:
55
+
56
+ ```bash
57
+ poetry run pytest --snapshot-update
58
+ ```
59
+
60
+ [poetry-install]: https://python-poetry.org/docs/#installation
61
+ [poetry]: https://python-poetry.org
62
+ [pre-commit]: https://pre-commit.com/
63
+
64
+
65
+ # Buying Equipment
66
+
67
+ Many mowers are available from your local garden dealer or major online retailers. Another like, the compact ideal for small and flat lawns, is available on Amazon.
68
+ The links provided below are affiliate links, so if you prefer shopping on Amazon and decide to purchase something there, you’ll also be supporting me at no additional cost to you.
69
+ Alternatively, if you'd like to support the project directly, consider contributing through [GitHub sponsors](https://github.com/sponsors/Thomas55555).
70
+ Here are some affiliate links to support my work:
71
+ - [Automower R4 Aspire](https://amzn.to/3Z987Oc)
72
+ - [Endurence blades](https://amzn.to/3OyK1YD)
73
+ - [Regular blades](https://amzn.to/3ZCn8Zt)
74
+ - [Cabel connector](https://amzn.to/4f3OtJn)
@@ -0,0 +1,439 @@
1
+ [build-system]
2
+ requires = ["poetry-core>=1.0.0", "poetry-dynamic-versioning>=1.0.0,<2.0.0"]
3
+ build-backend = "poetry_dynamic_versioning.backend"
4
+
5
+ [tool.poetry]
6
+ name = "aioautomower"
7
+ # The version is set by GH action on release
8
+ version = "0.0.0-post.1"
9
+ description = "MPython module to talk to Husqvarna Automower."
10
+ authors = [
11
+ "Thomas Peter Protzner <thomas.protzner@gmail.com>",
12
+ ]
13
+ license = "MIT"
14
+ readme = "README.md"
15
+ packages = [
16
+ { include = "aioautomower", from = "src" },
17
+ ]
18
+ homepage = "https://github.com/Thomas55555/aioautomower"
19
+ repository = "https://github.com/Thomas55555/aioautomower"
20
+ documentation = "https://github.com/Thomas55555/aioautomower"
21
+ keywords = ["Husqvarna", "Automower", "api", "async", "client"]
22
+ classifiers = [
23
+ "Development Status :: 5 - Production/Stable",
24
+ "Framework :: AsyncIO",
25
+ "Intended Audience :: Developers",
26
+ "Natural Language :: English",
27
+ "Programming Language :: Python :: 3.11",
28
+ "Programming Language :: Python :: 3.12",
29
+ "Programming Language :: Python :: 3.13",
30
+ "Programming Language :: Python :: 3",
31
+ "Topic :: Software Development :: Libraries :: Python Modules",
32
+ ]
33
+
34
+ [tool.poetry.urls]
35
+ Issues = "https://github.com/Thomas55555/aioautomower/issues"
36
+
37
+ [tool.poetry.dependencies]
38
+ python = "^3.11"
39
+ aiohttp = "^3.9.3"
40
+ mashumaro = "^3.12"
41
+ PyJWT = "^2.8.0"
42
+ ical = ">=8.0.1"
43
+ tzlocal = "^5.2"
44
+ python-dateutil = "^2.9.0-post.0"
45
+
46
+ [tool.poetry.group.dev.dependencies]
47
+ aioresponses = "0.7.8"
48
+ codespell = "2.4.1"
49
+ covdefaults = "2.3.0"
50
+ coverage = {version = "7.9.2", extras = ["toml"]}
51
+ mypy = "1.16.1"
52
+ pre-commit = "4.2.0"
53
+ pre-commit-hooks = "5.0.0"
54
+ pylint = "3.3.7"
55
+ pytest = "8.4.1"
56
+ pytest-asyncio = "1.0.0"
57
+ pytest-cov = "6.2.1"
58
+ ruff = "0.12.2"
59
+ syrupy = "4.9.1"
60
+ time-machine = "2.16.0"
61
+ types-python-dateutil = "^2.9.0.20240821"
62
+ types-pyyaml = "^6.0.12.20241230"
63
+ yamllint = "1.37.1"
64
+
65
+ [tool.poetry-dynamic-versioning]
66
+ enable = false
67
+ vcs = "git"
68
+ style = "semver"
69
+ metadata = false
70
+ tag_pattern = "^v(?P<version>.+)$"
71
+ latest_tag = true
72
+
73
+ [tool.pytest.ini_options]
74
+ addopts = "--cov=aioautomower --cov-report=term-missing -vv"
75
+ asyncio_mode = "auto"
76
+ asyncio_default_fixture_loop_scope = "session"
77
+
78
+ [tool.ruff]
79
+ fix = true
80
+ show-fixes = true
81
+ src = ["./src"]
82
+ target-version = "py311"
83
+ line-length = 88
84
+ include = ["src/**/*.py", "tests/**/*.py"]
85
+
86
+
87
+ [tool.ruff.lint]
88
+ ignore = [
89
+ "ANN401", # Opinioated warning on disallowing dynamically typed expressions
90
+ "D203", # Conflicts with other rules
91
+ "D213", # Conflicts with other rules
92
+ "D417", # False positives in some occasions
93
+ "PLR2004", # Just annoying, not really useful
94
+
95
+ # Conflicts with the Ruff formatter
96
+ "COM812",
97
+ ]
98
+ select = ["ALL"]
99
+
100
+ [tool.ruff.lint.per-file-ignores]
101
+ "example.py" = ["T201", "T203"] # Allow for main entry & scripts to write to stdout
102
+ "tests/**/*.py" = [
103
+ "SLF001", #access to private members
104
+ "S101", # asserts allowed in tests...
105
+ "ARG", # Unused function args -> fixtures nevertheless are functionally relevant...
106
+ "FBT", # Don't care about booleans as positional arguments in tests, e.g. via @pytest.mark.parametrize()
107
+ "PLR2004", # Magic value used in comparison, ...
108
+ "S311", # Standard pseudo-random generators are not suitable for cryptographic purposes
109
+ "S105", # needed in tests (hardcoded password)
110
+ ]
111
+
112
+ [tool.pylint.FORMAT]
113
+ max-line-length = 88
114
+
115
+ [tool.ruff.lint.flake8-annotations]
116
+ allow-star-arg-any = true
117
+ suppress-dummy-args = true
118
+
119
+ [tool.ruff.lint.flake8-builtins]
120
+ builtins-ignorelist = ["id"]
121
+
122
+ [tool.ruff.lint.pydocstyle]
123
+ # Use Google-style docstrings.
124
+ convention = "pep257"
125
+
126
+ [tool.ruff.lint.pylint]
127
+ max-branches=25
128
+ max-returns=15
129
+ max-args=10
130
+ max-statements=50
131
+
132
+ [tool.pylint]
133
+ ignore = ["R0902"]
134
+
135
+ [tool.pylint.MASTER]
136
+ ignore = [
137
+ "tests",
138
+ ]
139
+
140
+ [tool.pylint."MESSAGES CONTROL"]
141
+ # Reasons disabled:
142
+ # format - handled by ruff
143
+ # locally-disabled - it spams too much
144
+ # duplicate-code - unavoidable
145
+ # cyclic-import - doesn't test if both import on load
146
+ # abstract-class-little-used - prevents from setting right foundation
147
+ # unused-argument - generic callbacks and setup methods create a lot of warnings
148
+ # too-many-* - are not enforced for the sake of readability
149
+ # too-few-* - same as too-many-*
150
+ # abstract-method - with intro of async there are always methods missing
151
+ # inconsistent-return-statements - doesn't handle raise
152
+ # too-many-ancestors - it's too strict.
153
+ # wrong-import-order - isort guards this
154
+ # possibly-used-before-assignment - too many errors / not necessarily issues
155
+ # ---
156
+ # Pylint CodeStyle plugin
157
+ disable = [
158
+ "format",
159
+ "abstract-method",
160
+ "cyclic-import",
161
+ "duplicate-code",
162
+ "inconsistent-return-statements",
163
+ "locally-disabled",
164
+ "not-context-manager",
165
+ "too-few-public-methods",
166
+ "too-many-ancestors",
167
+ "too-many-arguments",
168
+ "too-many-instance-attributes",
169
+ "too-many-lines",
170
+ "too-many-locals",
171
+ "too-many-public-methods",
172
+ "too-many-boolean-expressions",
173
+ "too-many-positional-arguments",
174
+ "wrong-import-order",
175
+ "possibly-used-before-assignment",
176
+
177
+ # Handled by ruff
178
+ # Ref: <https://github.com/astral-sh/ruff/issues/970>
179
+ "await-outside-async", # PLE1142
180
+ "bad-str-strip-call", # PLE1310
181
+ "bad-string-format-type", # PLE1307
182
+ "bidirectional-unicode", # PLE2502
183
+ "continue-in-finally", # PLE0116
184
+ "duplicate-bases", # PLE0241
185
+ "misplaced-bare-raise", # PLE0704
186
+ "format-needs-mapping", # F502
187
+ "function-redefined", # F811
188
+ # Needed because ruff does not understand type of __all__ generated by a function
189
+ # "invalid-all-format", # PLE0605
190
+ "invalid-all-object", # PLE0604
191
+ "invalid-character-backspace", # PLE2510
192
+ "invalid-character-esc", # PLE2513
193
+ "invalid-character-nul", # PLE2514
194
+ "invalid-character-sub", # PLE2512
195
+ "invalid-character-zero-width-space", # PLE2515
196
+ "logging-too-few-args", # PLE1206
197
+ "logging-too-many-args", # PLE1205
198
+ "missing-format-string-key", # F524
199
+ "mixed-format-string", # F506
200
+ "no-method-argument", # N805
201
+ "no-self-argument", # N805
202
+ "nonexistent-operator", # B002
203
+ "nonlocal-without-binding", # PLE0117
204
+ "not-in-loop", # F701, F702
205
+ "notimplemented-raised", # F901
206
+ "return-in-init", # PLE0101
207
+ "return-outside-function", # F706
208
+ "syntax-error", # E999
209
+ "too-few-format-args", # F524
210
+ "too-many-format-args", # F522
211
+ "too-many-star-expressions", # F622
212
+ "truncated-format-string", # F501
213
+ "undefined-all-variable", # F822
214
+ "undefined-variable", # F821
215
+ "used-prior-global-declaration", # PLE0118
216
+ "yield-inside-async-function", # PLE1700
217
+ "yield-outside-function", # F704
218
+ "anomalous-backslash-in-string", # W605
219
+ "assert-on-string-literal", # PLW0129
220
+ "assert-on-tuple", # F631
221
+ "bad-format-string", # W1302, F
222
+ "bad-format-string-key", # W1300, F
223
+ "bare-except", # E722
224
+ "binary-op-exception", # PLW0711
225
+ "cell-var-from-loop", # B023
226
+ # "dangerous-default-value", # B006, ruff catches new occurrences, needs more work
227
+ "duplicate-except", # B014
228
+ "duplicate-key", # F601
229
+ "duplicate-string-formatting-argument", # F
230
+ "duplicate-value", # F
231
+ "eval-used", # S307
232
+ "exec-used", # S102
233
+ "expression-not-assigned", # B018
234
+ "f-string-without-interpolation", # F541
235
+ "forgotten-debug-statement", # T100
236
+ "format-string-without-interpolation", # F
237
+ # "global-statement", # PLW0603, ruff catches new occurrences, needs more work
238
+ "global-variable-not-assigned", # PLW0602
239
+ "implicit-str-concat", # ISC001
240
+ "import-self", # PLW0406
241
+ "inconsistent-quotes", # Q000
242
+ "invalid-envvar-default", # PLW1508
243
+ "keyword-arg-before-vararg", # B026
244
+ "logging-format-interpolation", # G
245
+ "logging-fstring-interpolation", # G
246
+ "logging-not-lazy", # G
247
+ "misplaced-future", # F404
248
+ "named-expr-without-context", # PLW0131
249
+ "nested-min-max", # PLW3301
250
+ "pointless-statement", # B018
251
+ "raise-missing-from", # B904
252
+ "redefined-builtin", # A001
253
+ "try-except-raise", # TRY302
254
+ "unused-argument", # ARG001, we don't use it
255
+ "unused-format-string-argument", #F507
256
+ "unused-format-string-key", # F504
257
+ "unused-import", # F401
258
+ "unused-variable", # F841
259
+ "useless-else-on-loop", # PLW0120
260
+ "wildcard-import", # F403
261
+ "bad-classmethod-argument", # N804
262
+ "consider-iterating-dictionary", # SIM118
263
+ "empty-docstring", # D419
264
+ "invalid-name", # N815
265
+ "line-too-long", # E501, disabled globally
266
+ "missing-class-docstring", # D101
267
+ "missing-final-newline", # W292
268
+ "missing-function-docstring", # D103
269
+ "missing-module-docstring", # D100
270
+ "multiple-imports", #E401
271
+ "singleton-comparison", # E711, E712
272
+ "subprocess-run-check", # PLW1510
273
+ "superfluous-parens", # UP034
274
+ "ungrouped-imports", # I001
275
+ "unidiomatic-typecheck", # E721
276
+ "unnecessary-direct-lambda-call", # PLC3002
277
+ "unnecessary-lambda-assignment", # PLC3001
278
+ "unnecessary-pass", # PIE790
279
+ "unneeded-not", # SIM208
280
+ "useless-import-alias", # PLC0414
281
+ "wrong-import-order", # I001
282
+ "wrong-import-position", # E402
283
+ "comparison-of-constants", # PLR0133
284
+ "comparison-with-itself", # PLR0124
285
+ "consider-merging-isinstance", # PLR1701
286
+ "consider-using-dict-comprehension", # C402
287
+ "consider-using-generator", # C417
288
+ "consider-using-get", # SIM401
289
+ "consider-using-set-comprehension", # C401
290
+ "consider-using-sys-exit", # PLR1722
291
+ "consider-using-ternary", # SIM108
292
+ "literal-comparison", # F632
293
+ "property-with-parameters", # PLR0206
294
+ "super-with-arguments", # UP008
295
+ "too-many-branches", # PLR0912
296
+ "too-many-return-statements", # PLR0911
297
+ "too-many-statements", # PLR0915
298
+ "trailing-comma-tuple", # COM818
299
+ "unnecessary-comprehension", # C416
300
+ "use-a-generator", # C417
301
+ "use-dict-literal", # C406
302
+ "use-list-literal", # C405
303
+ "useless-object-inheritance", # UP004
304
+ "useless-return", # PLR1711
305
+ "no-else-break", # RET508
306
+ "no-else-continue", # RET507
307
+ "no-else-raise", # RET506
308
+ "no-else-return", # RET505
309
+ "broad-except", # BLE001
310
+ "protected-access", # SLF001
311
+ "broad-exception-raised", # TRY002
312
+ "consider-using-f-string", # PLC0209
313
+ # "no-self-use", # PLR6301 # Optional plugin, not enabled
314
+
315
+ # Handled by mypy
316
+ # Ref: <https://github.com/antonagestam/pylint-mypy-overlap>
317
+ "abstract-class-instantiated",
318
+ "arguments-differ",
319
+ "assigning-non-slot",
320
+ "assignment-from-no-return",
321
+ "assignment-from-none",
322
+ "bad-exception-cause",
323
+ "bad-format-character",
324
+ "bad-reversed-sequence",
325
+ "bad-super-call",
326
+ "bad-thread-instantiation",
327
+ "catching-non-exception",
328
+ "comparison-with-callable",
329
+ "deprecated-class",
330
+ "dict-iter-missing-items",
331
+ "format-combined-specification",
332
+ "global-variable-undefined",
333
+ "import-error",
334
+ "inconsistent-mro",
335
+ "inherit-non-class",
336
+ "init-is-generator",
337
+ "invalid-class-object",
338
+ "invalid-enum-extension",
339
+ "invalid-envvar-value",
340
+ "invalid-format-returned",
341
+ "invalid-hash-returned",
342
+ "invalid-metaclass",
343
+ "invalid-overridden-method",
344
+ "invalid-repr-returned",
345
+ "invalid-sequence-index",
346
+ "invalid-slice-index",
347
+ "invalid-slots-object",
348
+ "invalid-slots",
349
+ "invalid-star-assignment-target",
350
+ "invalid-str-returned",
351
+ "invalid-unary-operand-type",
352
+ "invalid-unicode-codec",
353
+ "isinstance-second-argument-not-valid-type",
354
+ "method-hidden",
355
+ "misplaced-format-function",
356
+ "missing-format-argument-key",
357
+ "missing-format-attribute",
358
+ "missing-kwoa",
359
+ "no-member",
360
+ "no-value-for-parameter",
361
+ "non-iterator-returned",
362
+ "non-str-assignment-to-dunder-name",
363
+ "nonlocal-and-global",
364
+ "not-a-mapping",
365
+ "not-an-iterable",
366
+ "not-async-context-manager",
367
+ "not-callable",
368
+ "not-context-manager",
369
+ "overridden-final-method",
370
+ "raising-bad-type",
371
+ "raising-non-exception",
372
+ "redundant-keyword-arg",
373
+ "relative-beyond-top-level",
374
+ "self-cls-assignment",
375
+ "signature-differs",
376
+ "star-needs-assignment-target",
377
+ "subclassed-final-class",
378
+ "super-without-brackets",
379
+ "too-many-function-args",
380
+ "typevar-double-variance",
381
+ "typevar-name-mismatch",
382
+ "unbalanced-dict-unpacking",
383
+ "unbalanced-tuple-unpacking",
384
+ "unexpected-keyword-arg",
385
+ "unhashable-member",
386
+ "unpacking-non-sequence",
387
+ "unsubscriptable-object",
388
+ "unsupported-assignment-operation",
389
+ "unsupported-binary-operation",
390
+ "unsupported-delete-operation",
391
+ "unsupported-membership-test",
392
+ "used-before-assignment",
393
+ "using-final-decorator-in-unsupported-version",
394
+ "wrong-exception-operation",
395
+ ]
396
+ enable = [
397
+ #"useless-suppression", # temporarily every now and then to clean them up
398
+ "use-symbolic-message-instead",
399
+ ]
400
+
401
+ [tool.mypy]
402
+ platform = "linux"
403
+ python_version = "3.11"
404
+ strict = true
405
+ namespace_packages = true
406
+ mypy_path = "src"
407
+
408
+ # show error messages from unrelated files
409
+ follow_imports = "normal"
410
+
411
+ # suppress errors about unsatisfied imports
412
+ ignore_missing_imports = true
413
+
414
+ # strict rules
415
+ check_untyped_defs = true
416
+ disallow_any_generics = true
417
+ disallow_incomplete_defs = true
418
+ disallow_subclassing_any = true
419
+ disallow_untyped_calls = true
420
+ disallow_untyped_decorators = true
421
+ disallow_untyped_defs = true
422
+ no_implicit_optional = true
423
+ no_implicit_reexport = true
424
+ strict_optional = true
425
+ warn_incomplete_stub = true
426
+ warn_no_return = true
427
+ warn_redundant_casts = true
428
+ warn_return_any = true
429
+ warn_unused_configs = true
430
+ warn_unused_ignores = true
431
+
432
+
433
+ [tool.coverage.report]
434
+ show_missing = true
435
+ fail_under = 50
436
+
437
+ [tool.coverage.run]
438
+ plugins = ["covdefaults"]
439
+ source = ["aioautomower"]
@@ -0,0 +1,11 @@
1
+ """Automower library using aiohttp."""
2
+
3
+ __all__ = [
4
+ "auth",
5
+ "commands",
6
+ "const",
7
+ "exceptions",
8
+ "model",
9
+ "session",
10
+ "utils",
11
+ ]