deebot-client 3.0.2__tar.gz → 4.0.0__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 (179) hide show
  1. deebot-client-4.0.0/.codecov.yml +5 -0
  2. deebot-client-4.0.0/.coveragerc +11 -0
  3. deebot-client-4.0.0/.devcontainer.json +73 -0
  4. deebot-client-4.0.0/.gitattributes +2 -0
  5. deebot-client-4.0.0/.github/FUNDING.yml +1 -0
  6. deebot-client-4.0.0/.github/ISSUE_TEMPLATE/bug_report.yml +94 -0
  7. deebot-client-4.0.0/.github/ISSUE_TEMPLATE/config.yml +8 -0
  8. deebot-client-4.0.0/.github/dependabot.yml +17 -0
  9. deebot-client-4.0.0/.github/release-drafter.yml +53 -0
  10. deebot-client-4.0.0/.github/workflows/ci.yml +60 -0
  11. deebot-client-4.0.0/.github/workflows/codeql-analysis.yml +71 -0
  12. deebot-client-4.0.0/.github/workflows/python-publish.yml +39 -0
  13. deebot-client-4.0.0/.github/workflows/release-drafter.yml +16 -0
  14. deebot-client-4.0.0/.gitignore +23 -0
  15. deebot-client-4.0.0/.pre-commit-config.yaml +85 -0
  16. deebot-client-4.0.0/.prettierrc.js +5 -0
  17. deebot-client-4.0.0/.yamllint +59 -0
  18. {deebot-client-3.0.2 → deebot-client-4.0.0}/PKG-INFO +19 -11
  19. {deebot-client-3.0.2 → deebot-client-4.0.0}/README.md +3 -3
  20. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/api_client.py +11 -9
  21. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/authentication.py +26 -32
  22. deebot-client-4.0.0/deebot_client/capabilities.py +209 -0
  23. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/command.py +142 -29
  24. deebot-client-4.0.0/deebot_client/commands/__init__.py +14 -0
  25. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/__init__.py +76 -8
  26. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/advanced_mode.py +2 -1
  27. deebot-client-4.0.0/deebot_client/commands/json/battery.py +14 -0
  28. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/carpet.py +2 -1
  29. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/charge.py +9 -7
  30. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/charge_state.py +15 -13
  31. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/clean.py +20 -39
  32. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/clean_count.py +12 -9
  33. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/clean_logs.py +11 -9
  34. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/clean_preference.py +2 -1
  35. deebot-client-4.0.0/deebot_client/commands/json/common.py +105 -0
  36. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/continuous_cleaning.py +2 -1
  37. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/custom.py +11 -7
  38. deebot-client-4.0.0/deebot_client/commands/json/efficiency.py +40 -0
  39. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/error.py +9 -6
  40. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/fan_speed.py +12 -13
  41. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/life_span.py +18 -21
  42. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/map.py +45 -42
  43. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/multimap_state.py +2 -1
  44. deebot-client-4.0.0/deebot_client/commands/json/network.py +32 -0
  45. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/pos.py +11 -7
  46. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/stats.py +7 -5
  47. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/true_detect.py +2 -1
  48. deebot-client-4.0.0/deebot_client/commands/json/voice_assistant_state.py +19 -0
  49. deebot-client-4.0.0/deebot_client/commands/json/volume.py +46 -0
  50. deebot-client-4.0.0/deebot_client/commands/json/water_info.py +51 -0
  51. deebot-client-4.0.0/deebot_client/commands/json/work_mode.py +40 -0
  52. deebot-client-4.0.0/deebot_client/commands/xml/__init__.py +1 -0
  53. deebot-client-4.0.0/deebot_client/commands/xml/common.py +31 -0
  54. deebot-client-4.0.0/deebot_client/const.py +28 -0
  55. deebot-client-3.0.2/deebot_client/vacuum_bot.py → deebot-client-4.0.0/deebot_client/device.py +41 -24
  56. {deebot-client-3.0.2/deebot_client/events → deebot-client-4.0.0/deebot_client}/event_bus.py +27 -26
  57. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/events/__init__.py +46 -7
  58. deebot-client-4.0.0/deebot_client/events/efficiency_mode.py +20 -0
  59. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/events/fan_speed.py +2 -1
  60. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/events/map.py +4 -5
  61. deebot-client-4.0.0/deebot_client/events/network.py +16 -0
  62. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/events/water_info.py +5 -4
  63. deebot-client-4.0.0/deebot_client/events/work_mode.py +22 -0
  64. deebot-client-4.0.0/deebot_client/hardware/__init__.py +6 -0
  65. deebot-client-4.0.0/deebot_client/hardware/deebot/85nbtp.py +193 -0
  66. deebot-client-4.0.0/deebot_client/hardware/deebot/__init__.py +34 -0
  67. deebot-client-4.0.0/deebot_client/hardware/deebot/fallback.py +179 -0
  68. deebot-client-4.0.0/deebot_client/hardware/deebot/p1jij8.py +193 -0
  69. deebot-client-4.0.0/deebot_client/hardware/deebot/p95mgv.py +220 -0
  70. deebot-client-4.0.0/deebot_client/hardware/deebot/vi829v.py +163 -0
  71. deebot-client-4.0.0/deebot_client/hardware/deebot/yna5xi.py +163 -0
  72. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/logging_filter.py +4 -4
  73. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/map.py +28 -27
  74. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/message.py +57 -21
  75. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/messages/__init__.py +20 -20
  76. deebot-client-4.0.0/deebot_client/messages/json/__init__.py +20 -0
  77. {deebot-client-3.0.2/deebot_client/messages → deebot-client-4.0.0/deebot_client/messages/json}/battery.py +3 -3
  78. {deebot-client-3.0.2/deebot_client/messages → deebot-client-4.0.0/deebot_client/messages/json}/stats.py +3 -3
  79. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/models.py +92 -19
  80. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/mqtt_client.py +42 -35
  81. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/util.py +27 -14
  82. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client.egg-info/PKG-INFO +19 -11
  83. deebot-client-4.0.0/deebot_client.egg-info/SOURCES.txt +150 -0
  84. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client.egg-info/requires.txt +2 -1
  85. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client.egg-info/top_level.txt +0 -1
  86. deebot-client-4.0.0/mypy.ini +27 -0
  87. deebot-client-4.0.0/pyproject.toml +166 -0
  88. deebot-client-4.0.0/pytest.ini +5 -0
  89. deebot-client-4.0.0/requirements-dev.txt +2 -0
  90. deebot-client-4.0.0/requirements-test.txt +12 -0
  91. deebot-client-4.0.0/requirements.txt +6 -0
  92. deebot-client-4.0.0/scripts/check_getLogger.sh +18 -0
  93. deebot-client-4.0.0/scripts/run-in-env.sh +21 -0
  94. deebot-client-4.0.0/setup.cfg +4 -0
  95. deebot-client-4.0.0/tests/commands/__init__.py +0 -0
  96. deebot-client-4.0.0/tests/commands/json/__init__.py +146 -0
  97. deebot-client-4.0.0/tests/commands/json/test_advanced_mode.py +20 -0
  98. deebot-client-4.0.0/tests/commands/json/test_battery.py +15 -0
  99. deebot-client-4.0.0/tests/commands/json/test_carpet.py +20 -0
  100. deebot-client-4.0.0/tests/commands/json/test_charge.py +46 -0
  101. {deebot-client-3.0.2/tests/commands → deebot-client-4.0.0/tests/commands/json}/test_charge_state.py +6 -5
  102. {deebot-client-3.0.2/tests/commands → deebot-client-4.0.0/tests/commands/json}/test_clean.py +17 -16
  103. {deebot-client-3.0.2/tests/commands → deebot-client-4.0.0/tests/commands/json}/test_clean_count.py +5 -4
  104. {deebot-client-3.0.2/tests/commands → deebot-client-4.0.0/tests/commands/json}/test_clean_log.py +41 -41
  105. deebot-client-4.0.0/tests/commands/json/test_clean_preference.py +20 -0
  106. deebot-client-4.0.0/tests/commands/json/test_common.py +93 -0
  107. deebot-client-4.0.0/tests/commands/json/test_continuous_cleaning.py +20 -0
  108. deebot-client-4.0.0/tests/commands/json/test_custom.py +34 -0
  109. deebot-client-4.0.0/tests/commands/json/test_efficiency.py +40 -0
  110. deebot-client-4.0.0/tests/commands/json/test_fan_speed.py +35 -0
  111. deebot-client-4.0.0/tests/commands/json/test_life_span.py +89 -0
  112. deebot-client-4.0.0/tests/commands/json/test_map.py +199 -0
  113. deebot-client-4.0.0/tests/commands/json/test_mulitmap_state.py +20 -0
  114. deebot-client-4.0.0/tests/commands/json/test_network.py +28 -0
  115. deebot-client-4.0.0/tests/commands/json/test_true_detect.py +20 -0
  116. deebot-client-4.0.0/tests/commands/json/test_voice_assistant_state.py +22 -0
  117. deebot-client-4.0.0/tests/commands/json/test_volume.py +18 -0
  118. deebot-client-4.0.0/tests/commands/json/test_water_info.py +50 -0
  119. deebot-client-4.0.0/tests/commands/json/test_work_mode.py +43 -0
  120. deebot-client-4.0.0/tests/conftest.py +149 -0
  121. deebot-client-4.0.0/tests/events/__init__.py +0 -0
  122. deebot-client-4.0.0/tests/fixtures/__init__.py +0 -0
  123. deebot-client-4.0.0/tests/fixtures/base.py +216 -0
  124. deebot-client-4.0.0/tests/fixtures/mqtt_server.py +20 -0
  125. deebot-client-4.0.0/tests/hardware/__init__.py +0 -0
  126. deebot-client-4.0.0/tests/hardware/test_init.py +204 -0
  127. deebot-client-4.0.0/tests/helpers/__init__.py +74 -0
  128. deebot-client-4.0.0/tests/helpers/tasks.py +60 -0
  129. {deebot-client-3.0.2 → deebot-client-4.0.0}/tests/messages/__init__.py +1 -1
  130. deebot-client-4.0.0/tests/messages/json/__init__.py +0 -0
  131. {deebot-client-3.0.2/tests/messages → deebot-client-4.0.0/tests/messages/json}/test_battery.py +2 -2
  132. {deebot-client-3.0.2/tests/messages → deebot-client-4.0.0/tests/messages/json}/test_stats.py +2 -2
  133. deebot-client-4.0.0/tests/messages/test_get_messages.py +25 -0
  134. {deebot-client-3.0.2 → deebot-client-4.0.0}/tests/messages/test_messages.py +3 -2
  135. deebot-client-4.0.0/tests/test_authentication.py +47 -0
  136. deebot-client-4.0.0/tests/test_command.py +65 -0
  137. deebot-client-4.0.0/tests/test_device.py +126 -0
  138. {deebot-client-3.0.2/tests/events → deebot-client-4.0.0/tests}/test_event_bus.py +50 -38
  139. deebot-client-4.0.0/tests/test_map.py +71 -0
  140. deebot-client-4.0.0/tests/test_mqtt_client.py +457 -0
  141. deebot-client-4.0.0/tests/test_util.py +35 -0
  142. deebot-client-3.0.2/deebot_client/commands/battery.py +0 -13
  143. deebot-client-3.0.2/deebot_client/commands/common.py +0 -148
  144. deebot-client-3.0.2/deebot_client/commands/volume.py +0 -40
  145. deebot-client-3.0.2/deebot_client/commands/water_info.py +0 -48
  146. deebot-client-3.0.2/deebot_client/const.py +0 -10
  147. deebot-client-3.0.2/deebot_client/events/const.py +0 -92
  148. deebot-client-3.0.2/deebot_client.egg-info/SOURCES.txt +0 -88
  149. deebot-client-3.0.2/pyproject.toml +0 -3
  150. deebot-client-3.0.2/setup.cfg +0 -22
  151. deebot-client-3.0.2/setup.py +0 -38
  152. deebot-client-3.0.2/tests/commands/__init__.py +0 -86
  153. deebot-client-3.0.2/tests/commands/test_advanced_mode.py +0 -18
  154. deebot-client-3.0.2/tests/commands/test_battery.py +0 -12
  155. deebot-client-3.0.2/tests/commands/test_carpet.py +0 -20
  156. deebot-client-3.0.2/tests/commands/test_charge.py +0 -46
  157. deebot-client-3.0.2/tests/commands/test_clean_preference.py +0 -20
  158. deebot-client-3.0.2/tests/commands/test_common.py +0 -97
  159. deebot-client-3.0.2/tests/commands/test_continuous_cleaning.py +0 -20
  160. deebot-client-3.0.2/tests/commands/test_custom.py +0 -25
  161. deebot-client-3.0.2/tests/commands/test_fan_speed.py +0 -25
  162. deebot-client-3.0.2/tests/commands/test_life_span.py +0 -31
  163. deebot-client-3.0.2/tests/commands/test_map.py +0 -187
  164. deebot-client-3.0.2/tests/commands/test_mulitmap_state.py +0 -18
  165. deebot-client-3.0.2/tests/commands/test_true_detect.py +0 -18
  166. deebot-client-3.0.2/tests/commands/test_water_info.py +0 -48
  167. deebot-client-3.0.2/tests/events/test_events.py +0 -11
  168. deebot-client-3.0.2/tests/messages/test_get_messages.py +0 -21
  169. {deebot-client-3.0.2 → deebot-client-4.0.0}/LICENSE.txt +0 -0
  170. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/__init__.py +0 -0
  171. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/const.py +0 -0
  172. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/play_sound.py +0 -0
  173. {deebot-client-3.0.2/deebot_client/commands → deebot-client-4.0.0/deebot_client/commands/json}/relocation.py +0 -0
  174. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/events/base.py +0 -0
  175. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/exceptions.py +0 -0
  176. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client/py.typed +0 -0
  177. {deebot-client-3.0.2 → deebot-client-4.0.0}/deebot_client.egg-info/dependency_links.txt +0 -0
  178. {deebot-client-3.0.2/tests/events → deebot-client-4.0.0/tests}/__init__.py +0 -0
  179. {deebot-client-3.0.2 → deebot-client-4.0.0}/tests/events/test_water_info.py +0 -0
@@ -0,0 +1,5 @@
1
+ coverage:
2
+ status:
3
+ patch:
4
+ default:
5
+ target: 80%
@@ -0,0 +1,11 @@
1
+ [run]
2
+ branch = True
3
+ source = deebot_client
4
+
5
+ omit =
6
+ tests/*
7
+
8
+ [report]
9
+ exclude_lines =
10
+ pragma: no cover
11
+ if TYPE_CHECKING:
@@ -0,0 +1,73 @@
1
+ // For format details, see https://aka.ms/devcontainer.json. For config options, see the README at:
2
+ // https://github.com/microsoft/vscode-dev-containers/tree/v0.177.0/containers/python-3
3
+ {
4
+ "customizations": {
5
+ // Configure properties specific to VS Code.
6
+ "vscode": {
7
+ "extensions": [
8
+ "charliermarsh.ruff",
9
+ "eamodio.gitlens",
10
+ "github.vscode-pull-request-github",
11
+ "ms-python.python",
12
+ "ms-python.vscode-pylance",
13
+ "ms-vscode.makefile-tools",
14
+ "ryanluker.vscode-coverage-gutters",
15
+ "visualstudioexptteam.vscodeintellicode"
16
+ ],
17
+ // Set *default* container specific settings.json values on container create.
18
+ "settings": {
19
+ "[python]": {
20
+ "editor.defaultFormatter": "charliermarsh.ruff"
21
+ },
22
+ "editor.formatOnPaste": false,
23
+ "editor.formatOnSave": true,
24
+ "editor.formatOnType": true,
25
+ "editor.tabSize": 4,
26
+ "files.eol": "\n",
27
+ "files.trimTrailingWhitespace": true,
28
+ "python.analysis.autoImportCompletions": true,
29
+ "python.analysis.autoSearchPaths": false,
30
+ "python.analysis.extraPaths": ["/home/vscode/.local/lib/python3.11/"],
31
+ "python.analysis.typeCheckingMode": "basic",
32
+ "python.defaultInterpreterPath": "/usr/local/bin/python",
33
+ "python.formatting.autopep8Path": "/usr/local/py-utils/bin/autopep8",
34
+ "python.formatting.blackPath": "/usr/local/py-utils/bin/black",
35
+ "python.formatting.provider": "black",
36
+ "python.formatting.yapfPath": "/usr/local/py-utils/bin/yapf",
37
+ "python.languageServer": "Pylance",
38
+ "python.linting.banditPath": "/usr/local/py-utils/bin/bandit",
39
+ "python.linting.enabled": true,
40
+ "python.linting.flake8Path": "/usr/local/py-utils/bin/flake8",
41
+ "python.linting.mypyEnabled": true,
42
+ "python.linting.mypyPath": "/usr/local/py-utils/bin/mypy",
43
+ "python.linting.pycodestylePath": "/usr/local/py-utils/bin/pycodestyle",
44
+ "python.linting.pydocstylePath": "/usr/local/py-utils/bin/pydocstyle",
45
+ "python.linting.pylintArgs": ["--disable", "import-error"],
46
+ "python.linting.pylintEnabled": true,
47
+ "python.linting.pylintPath": "/usr/local/py-utils/bin/pylint",
48
+ "python.pythonPath": "/usr/local/python/bin/python",
49
+ "python.testing.pytestEnabled": true,
50
+ "python.testing.unittestEnabled": false,
51
+ "terminal.integrated.defaultProfile.linux": "zsh",
52
+ "terminal.integrated.profiles.linux": {
53
+ "zsh": {
54
+ "path": "/usr/bin/zsh"
55
+ }
56
+ }
57
+ }
58
+ }
59
+ },
60
+ // Add the IDs of extensions you want installed when the container is created.
61
+ "features": {
62
+ "ghcr.io/devcontainers/features/docker-in-docker:2": {}
63
+ },
64
+ "image": "mcr.microsoft.com/devcontainers/python:3",
65
+ "name": "Deebot client",
66
+ // Use 'forwardPorts' to make a list of ports inside the container available locally.
67
+ // "forwardPorts": [],
68
+ // Use 'postCreateCommand' to run commands after the container is created.
69
+ "postStartCommand": "pip install -r requirements-dev.txt && pre-commit install && pip install -e .",
70
+ // Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
71
+ "remoteUser": "vscode",
72
+ "runArgs": ["-e", "GIT_EDITOR=code --wait"]
73
+ }
@@ -0,0 +1,2 @@
1
+ # Auto detect text files and perform LF normalization
2
+ * text=auto
@@ -0,0 +1 @@
1
+ custom: ["https://www.buymeacoffee.com/edenhaus"]
@@ -0,0 +1,94 @@
1
+ name: Report an issue
2
+ description: Report an issue
3
+ labels: [bug]
4
+ body:
5
+ - type: markdown
6
+ attributes:
7
+ value: |
8
+ This issue form is for reporting bugs only!
9
+
10
+ If you have a feature request or a question, please use discussions.
11
+ - type: checkboxes
12
+ attributes:
13
+ label: Checks
14
+ options:
15
+ - label: I have searched the existing issues and no issue is describing my issue
16
+ required: true
17
+ - label: I have checked the [FAQ](https://deebot.readthedocs.io/home/faq/)
18
+ required: true
19
+ - label: I have checked the [documentation](https://deebot.readthedocs.io/integrations/home-assistant)
20
+ required: true
21
+ - label: I have installed the latest version
22
+ required: true
23
+
24
+ - type: textarea
25
+ validations:
26
+ required: true
27
+ attributes:
28
+ label: The problem
29
+ description: >-
30
+ Describe the issue you are experiencing here to communicate to the
31
+ maintainers. Tell us what you were trying to do and what happened.
32
+
33
+ Provide a clear and concise description of what the problem is.
34
+
35
+ - type: markdown
36
+ attributes:
37
+ value: |
38
+ ## Environment
39
+ - type: input
40
+ id: device
41
+ validations:
42
+ required: true
43
+ attributes:
44
+ label: On which deebot device (vacuum) you have the issue?
45
+ placeholder: Deebot Ozmo 950
46
+ - type: input
47
+ id: version
48
+ validations:
49
+ required: true
50
+ attributes:
51
+ label: Which version of the deebot-client are you using?
52
+ placeholder: X.X.X
53
+ - type: markdown
54
+ attributes:
55
+ value: |
56
+ # Configuration
57
+ - type: input
58
+ id: country
59
+ validations:
60
+ required: true
61
+ attributes:
62
+ label: Country
63
+ placeholder: it
64
+ description: >
65
+ Which country did you input during the setup of the integration?
66
+ - type: input
67
+ id: continent
68
+ validations:
69
+ required: true
70
+ attributes:
71
+ label: Continent
72
+ placeholder: eu
73
+ description: >
74
+ Which continent did you input during the setup of the integration?
75
+
76
+ - type: markdown
77
+ attributes:
78
+ value: |
79
+ # Details
80
+ - type: textarea
81
+ attributes:
82
+ label: Anything in the logs that might be useful for us?
83
+ description: >
84
+ For example, error message, or stack traces.
85
+
86
+ Please refer to the [documentation](https://deebot.readthedocs.io/integrations/home-assistant/issues/).
87
+ render: txt
88
+ - type: textarea
89
+ attributes:
90
+ label: Additional information
91
+ description: >
92
+ If you have any additional information for us, use the field below.
93
+ Please note, you can attach screenshots or screen recordings here, by
94
+ dragging and dropping files in the field below.
@@ -0,0 +1,8 @@
1
+ blank_issues_enabled: false
2
+ contact_links:
3
+ - name: "❓ Ask a Question"
4
+ url: https://github.com/DeebotUniverse/client.py/discussions/new
5
+ about: For asking a question please select the category "Q&A"
6
+ - name: "💡 Suggest an feature/idea"
7
+ url: https://github.com/DeebotUniverse/client.py/discussions/new
8
+ about: For feature request please select the category "Ideas"
@@ -0,0 +1,17 @@
1
+ version: 2
2
+ updates:
3
+ # Maintain dependencies for GitHub Actions
4
+ - package-ecosystem: "github-actions"
5
+ directory: "/"
6
+ labels:
7
+ - "pr: dependency-update"
8
+ schedule:
9
+ interval: "daily"
10
+
11
+ # Maintain dependencies for pip
12
+ - package-ecosystem: "pip"
13
+ directory: "/"
14
+ labels:
15
+ - "pr: dependency-update"
16
+ schedule:
17
+ interval: "daily"
@@ -0,0 +1,53 @@
1
+ name-template: "$RESOLVED_VERSION"
2
+ tag-template: "$RESOLVED_VERSION"
3
+ change-template: "- #$NUMBER $TITLE @$AUTHOR"
4
+ sort-direction: ascending
5
+ filter-by-commitish: true
6
+ categories:
7
+ - title: ":boom: Breaking changes"
8
+ label: "pr: Breaking Change"
9
+
10
+ - title: ":sparkles: New features"
11
+ label: "pr: new-feature"
12
+
13
+ - title: ":zap: Enhancements"
14
+ label: "pr: enhancement"
15
+
16
+ - title: ":recycle: Refactor"
17
+ label: "pr: refactor"
18
+
19
+ - title: ":bug: Bug Fixes"
20
+ label: "pr: bugfix"
21
+
22
+ - title: ":arrow_up: Dependency Updates"
23
+ labels:
24
+ - "pr: dependency-update"
25
+ - "dependencies"
26
+
27
+ include-labels:
28
+ - "pr: Breaking Change"
29
+ - "pr: enhancement"
30
+ - "pr: dependency-update"
31
+ - "pr: new-feature"
32
+ - "pr: bugfix"
33
+ - "pr: refactor"
34
+
35
+ version-resolver:
36
+ major:
37
+ labels:
38
+ - "pr: Breaking Change"
39
+ minor:
40
+ labels:
41
+ - "pr: enhancement"
42
+ - "pr: dependency-update"
43
+ - "pr: new-feature"
44
+ patch:
45
+ labels:
46
+ - "pr: bugfix"
47
+ default: patch
48
+
49
+ template: |
50
+ $CHANGES
51
+
52
+ **Like my work and want to support me?**
53
+ <a href="https://www.buymeacoffee.com/edenhaus" target="_blank"><img src="https://cdn.buymeacoffee.com/buttons/default-black.png" width="150px" height="35px" alt="Buy Me A Coffee" style="height: 35px !important;width: 150px !important;" ></a>
@@ -0,0 +1,60 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+ - dev
8
+ pull_request:
9
+
10
+ env:
11
+ DEFAULT_PYTHON: "3.11"
12
+
13
+ jobs:
14
+ code-quality:
15
+ runs-on: "ubuntu-latest"
16
+ name: Check code quality
17
+ steps:
18
+ - uses: "actions/checkout@v4"
19
+ - name: Set up Python ${{ env.DEFAULT_PYTHON }}
20
+ id: python
21
+ uses: actions/setup-python@v5.0.0
22
+ with:
23
+ python-version: ${{ env.DEFAULT_PYTHON }}
24
+ cache: "pip"
25
+ cache-dependency-path: "requirements*"
26
+ - name: Install dependencies
27
+ run: |
28
+ pip install -r requirements.txt
29
+ pip install -r requirements-test.txt
30
+ # Following steps cannot run by pre-commit.ci as repo = local
31
+ - name: Run mypy
32
+ run: mypy deebot_client/
33
+ - name: Pylint review
34
+ run: pylint deebot_client/
35
+ - name: Verify no getLogger usages
36
+ run: scripts/check_getLogger.sh
37
+
38
+ tests:
39
+ runs-on: "ubuntu-latest"
40
+ name: Run tests
41
+ steps:
42
+ - uses: "actions/checkout@v4"
43
+ - name: Set up Python ${{ env.DEFAULT_PYTHON }}
44
+ id: python
45
+ uses: actions/setup-python@v5.0.0
46
+ with:
47
+ python-version: ${{ env.DEFAULT_PYTHON }}
48
+ cache: "pip"
49
+ cache-dependency-path: "requirements*"
50
+ - name: Install dependencies
51
+ run: |
52
+ pip install -r requirements.txt
53
+ pip install -r requirements-test.txt
54
+ - name: Run pytest
55
+ run: pytest --cov=./ --cov-report=xml
56
+ - name: Upload coverage to Codecov
57
+ uses: codecov/codecov-action@v3
58
+ with:
59
+ token: ${{ secrets.CODECOV_TOKEN }}
60
+ fail_ci_if_error: true
@@ -0,0 +1,71 @@
1
+ # For most projects, this workflow file will not need changing; you simply need
2
+ # to commit it to your repository.
3
+ #
4
+ # You may wish to alter this file to override the set of languages analyzed,
5
+ # or to provide custom queries or build logic.
6
+ #
7
+ # ******** NOTE ********
8
+ # We have attempted to detect the languages in your repository. Please check
9
+ # the `language` matrix defined below to confirm you have the correct set of
10
+ # supported CodeQL languages.
11
+ #
12
+ name: "CodeQL"
13
+
14
+ on:
15
+ push:
16
+ branches:
17
+ - main
18
+ - dev
19
+ pull_request:
20
+ schedule:
21
+ - cron: "20 10 * * 0"
22
+
23
+ jobs:
24
+ analyze:
25
+ name: Analyze
26
+ runs-on: ubuntu-latest
27
+ permissions:
28
+ actions: read
29
+ contents: read
30
+ security-events: write
31
+
32
+ strategy:
33
+ fail-fast: false
34
+ matrix:
35
+ language: ["python"]
36
+ # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
37
+ # Learn more:
38
+ # https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
39
+
40
+ steps:
41
+ - name: Checkout repository
42
+ uses: actions/checkout@v4
43
+
44
+ # Initializes the CodeQL tools for scanning.
45
+ - name: Initialize CodeQL
46
+ uses: github/codeql-action/init@v2
47
+ with:
48
+ languages: ${{ matrix.language }}
49
+ # If you wish to specify custom queries, you can do so here or in a config file.
50
+ # By default, queries listed here will override any specified in a config file.
51
+ # Prefix the list here with "+" to use these queries and those in the config file.
52
+ # queries: ./path/to/local/query, your-org/your-repo/queries@main
53
+
54
+ # Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
55
+ # If this step fails, then you should remove it and run the build manually (see below)
56
+ - name: Autobuild
57
+ uses: github/codeql-action/autobuild@v2
58
+
59
+ # ℹ️ Command-line programs to run using the OS shell.
60
+ # 📚 https://git.io/JvXDl
61
+
62
+ # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
63
+ # and modify them (or add more) to build your code if your project
64
+ # uses a compiled language
65
+
66
+ # - run: |
67
+ # make bootstrap
68
+ # make release
69
+
70
+ - name: Perform CodeQL Analysis
71
+ uses: github/codeql-action/analyze@v2
@@ -0,0 +1,39 @@
1
+ # This workflow will upload a Python Package using Twine when a release is created
2
+ # For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
3
+
4
+ # This workflow uses actions that are not certified by GitHub.
5
+ # They are provided by a third-party and are governed by
6
+ # separate terms of service, privacy policy, and support
7
+ # documentation.
8
+
9
+ name: Upload Python Package
10
+
11
+ on:
12
+ release:
13
+ types: [published]
14
+
15
+ jobs:
16
+ deploy:
17
+ runs-on: ubuntu-latest
18
+ environment: release
19
+ permissions:
20
+ id-token: write
21
+ steps:
22
+ - name: 📥 Checkout the repository
23
+ uses: actions/checkout@v4
24
+
25
+ - name: Set up Python
26
+ uses: actions/setup-python@v5.0.0
27
+ with:
28
+ python-version: "3.11"
29
+
30
+ - name: Install dependencies
31
+ run: |
32
+ python -m pip install --upgrade pip
33
+ pip install -q build
34
+
35
+ - name: 📦 Build package
36
+ run: python -m build
37
+
38
+ - name: 📤 Publish package
39
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,16 @@
1
+ name: Release Drafter
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+
8
+ jobs:
9
+ update_release_draft:
10
+ runs-on: ubuntu-latest
11
+ permissions:
12
+ contents: write
13
+ steps:
14
+ - uses: release-drafter/release-drafter@v5
15
+ env:
16
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -0,0 +1,23 @@
1
+ __pycache__
2
+ Pipfile
3
+ Pipfile.lock
4
+ scratch*
5
+ .idea
6
+ build
7
+ dist
8
+ venv
9
+
10
+ # Nosetests files
11
+ cover/
12
+ .coverage
13
+
14
+ # Ignore Vscode files
15
+ .vscode
16
+
17
+ *.egg-info/
18
+ .noseids
19
+ nosetests.xml
20
+
21
+ .*_cache
22
+
23
+ test.py
@@ -0,0 +1,85 @@
1
+ ci:
2
+ autofix_prs: false
3
+ skip:
4
+ # This steps run in the ci workflow. Keep in sync
5
+ - mypy
6
+ - pylint
7
+ - verifyNoGetLogger
8
+
9
+ default_language_version:
10
+ python: python3.11
11
+
12
+ repos:
13
+ - repo: https://github.com/astral-sh/ruff-pre-commit
14
+ rev: v0.1.6
15
+ hooks:
16
+ - id: ruff
17
+ args:
18
+ - --fix
19
+ # - --unsafe-fixes
20
+ - id: ruff-format
21
+ - repo: https://github.com/asottile/pyupgrade
22
+ rev: v3.15.0
23
+ hooks:
24
+ - id: pyupgrade
25
+ args:
26
+ - --py311-plus
27
+ - repo: https://github.com/codespell-project/codespell
28
+ rev: v2.2.6
29
+ hooks:
30
+ - id: codespell
31
+ args:
32
+ - --ignore-words-list=hass,deebot
33
+ - --skip="./.*,*.csv,*.json"
34
+ - --quiet-level=2
35
+ exclude_types:
36
+ - csv
37
+ - json
38
+ - repo: https://github.com/pre-commit/pre-commit-hooks
39
+ rev: v4.5.0
40
+ hooks:
41
+ - id: check-executables-have-shebangs
42
+ - id: check-merge-conflict
43
+ - id: detect-private-key
44
+ - id: no-commit-to-branch
45
+ args: [--branch, main, --branch, dev]
46
+ - id: requirements-txt-fixer
47
+ - repo: https://github.com/pre-commit/mirrors-prettier
48
+ rev: v3.1.0
49
+ hooks:
50
+ - id: prettier
51
+ additional_dependencies:
52
+ - prettier@3.1.0
53
+ - prettier-plugin-sort-json@3.1.0
54
+ exclude_types:
55
+ - python
56
+ - repo: https://github.com/adrienverge/yamllint.git
57
+ rev: v1.33.0
58
+ hooks:
59
+ - id: yamllint
60
+ - repo: local
61
+ hooks:
62
+ # Run mypy through our wrapper script in order to get the possible
63
+ # pyenv and/or virtualenv activated; it may not have been e.g. if
64
+ # committing from a GUI tool that was not launched from an activated
65
+ # shell.
66
+ - id: mypy
67
+ name: Check with mypy
68
+ entry: scripts/run-in-env.sh mypy
69
+ language: script
70
+ types:
71
+ - python
72
+ require_serial: true
73
+ - id: pylint
74
+ name: Check with pylint
75
+ entry: scripts/run-in-env.sh pylint
76
+ language: script
77
+ types:
78
+ - python
79
+ require_serial: true
80
+ exclude: ^tests/.+
81
+ - id: verifyNoGetLogger
82
+ name: Verify no getLogger usages
83
+ entry: scripts/check_getLogger.sh
84
+ language: script
85
+ require_serial: true
@@ -0,0 +1,5 @@
1
+ /** @type {import("prettier").Config} */
2
+ module.exports = {
3
+ plugins: [require.resolve("prettier-plugin-sort-json")],
4
+ jsonRecursiveSort: true,
5
+ };
@@ -0,0 +1,59 @@
1
+ rules:
2
+ braces:
3
+ level: error
4
+ min-spaces-inside: 0
5
+ max-spaces-inside: 1
6
+ min-spaces-inside-empty: -1
7
+ max-spaces-inside-empty: -1
8
+ brackets:
9
+ level: error
10
+ min-spaces-inside: 0
11
+ max-spaces-inside: 0
12
+ min-spaces-inside-empty: -1
13
+ max-spaces-inside-empty: -1
14
+ colons:
15
+ level: error
16
+ max-spaces-before: 0
17
+ max-spaces-after: 1
18
+ commas:
19
+ level: error
20
+ max-spaces-before: 0
21
+ min-spaces-after: 1
22
+ max-spaces-after: 1
23
+ comments:
24
+ level: error
25
+ require-starting-space: true
26
+ min-spaces-from-content: 2
27
+ comments-indentation:
28
+ level: error
29
+ document-end:
30
+ level: error
31
+ present: false
32
+ document-start:
33
+ level: error
34
+ present: false
35
+ empty-lines:
36
+ level: error
37
+ max: 1
38
+ max-start: 0
39
+ max-end: 1
40
+ hyphens:
41
+ level: error
42
+ max-spaces-after: 1
43
+ indentation:
44
+ level: error
45
+ spaces: 2
46
+ indent-sequences: true
47
+ check-multi-line-strings: false
48
+ key-duplicates:
49
+ level: error
50
+ line-length: disable
51
+ new-line-at-end-of-file:
52
+ level: error
53
+ new-lines:
54
+ level: error
55
+ type: unix
56
+ trailing-spaces:
57
+ level: error
58
+ truthy:
59
+ disable