Commit graph

114 commits

Author SHA1 Message Date
6f8816d23d Prevent a potential recursion error in wait_for_either.
We shouldn't overwrite `event._set` and `event._clear` if those values
have already been set.

Those attributes hold the original references to `Event.set` and
`Event.clear` respectively, and the `OrEvent` logic overwrites them with
a callback-based logic.

This shouldn't happen if those attributes are already present.
2024-05-02 00:51:09 +00:00
921025be0c picovoice -> assistant.picovoice 2024-05-02 00:51:09 +00:00
a9498ea191 [WIP] Added initial hotword integration. 2024-05-02 00:51:09 +00:00
89d618b35f [WIP] music.mopidy refactor, initial backend rewrite. 2024-04-03 23:01:22 +00:00
9cf95125a6 [WIP] Added streaming support to camera.pi using new picamera2 API 2024-02-22 22:52:52 +01:00
eb47f9ded0 [#351] Merged google.pubsub plugin and backend.
Closes: #351
2024-01-19 02:14:49 +00:00
6e1ab92298
New components cache management.
The cache is no longer generated at runtime when the application runs -
which may take quite a while, especially on fresh installations.

A `components.json.gz` file is instead generated by the CI/CD process on
every commit to the main branch, and distributed with the package.

The application will read this file when the `inspect` plugin is first
initialized.

This also means that we can no longer cache the `install_cmds`, as they
change depending on the target OS. A new
`application.get_install_commands` action has now been made available to
the UI, so it can get the correct installation commands at runtime.
2024-01-06 22:21:59 +01:00
e6e4396e49
Enhanced get_default_media_plugin to filter by video/audio plugins. 2023-12-10 21:50:53 +01:00
2670d40094
Added get_default_media_plugin utility. 2023-12-06 01:31:05 +01:00
a0d8c522a2
[#308] Finalized weather integrations migration.
- Migrated `weather.buienradar` integration.
- Removed last leftovers of the previous weather backends and responses.

Closes: #308
2023-11-20 03:10:00 +01:00
8817581061
Removed -U option from pip command when installing deps.
We don't need to forcefully upgrade packages that don't need to be
upgraded.
2023-11-18 16:07:16 +01:00
1f321c32dc
[media.chromecast] Full plugin rewrite. 2023-11-12 03:08:54 +01:00
f6cb1fa4a7 Added utils.get_default_downloads_dir. 2023-11-03 20:54:46 +00:00
d5514d7f27 Added utils.is_debug_enabled. 2023-10-31 00:44:05 +00:00
a909dc5f0f
[Fix] The base per-OS requirements filename is always lowercase. 2023-10-22 01:45:23 +02:00
02049030d0
paho module added to automocks. 2023-10-21 19:55:50 +02:00
0eae6fd48d
Misc dependencies and mock fixes.
- `iputils` should be an explicit system dependency for `ping`.
  Some minimal systems (like some Docker images) may not have the `ping`
  command installed out of the box.

- `hid` and `marshmallow_dataclass` should be among the auto-mocked
  modules.
2023-10-20 01:02:35 +02:00
ed2a56de42
paho.mqtt should also be added to the mock modules 2023-10-20 00:00:07 +02:00
c7acc03c8f
[inspect] Added get_enabled_plugins and get_enabled_backends actions. 2023-10-18 22:10:32 +02:00
e40a74f11c
Added install_cmds to the JSON representation of a manifest. 2023-10-18 03:00:50 +02:00
d1afb88b80
[Reflection] Expand RST extensions from object docstrings too. 2023-10-16 00:21:49 +02:00
5726c6985f
Added utility function to get the defining class of a method. 2023-10-10 01:35:01 +02:00
52e353dc14
Expose the wrapped function in @action.
Added a `wrapped` "hidden" parameter to the function returned by the
`@action` decorator.

We need this to access the underlying decorated function when e.g. we
need to access its specs or decorators.
2023-10-09 22:35:08 +02:00
608844ca0c
[WIP] Large refactor of the inspection plugin and models. 2023-10-09 01:33:44 +02:00
40557f5d5d
Replaced one more occurrence of <type> | None syntax. 2023-10-09 01:33:44 +02:00
966a6ce29e
httplib2 should be an explicit dependency for Google integrations.
Plus, some misc LINT/Black chores.
2023-10-01 00:52:59 +02:00
a7bb81553c
Regex fix. 2023-09-30 15:11:09 +02:00
9e489bb5cf
Propagate the default/required properties of a parameter upon merge. 2023-09-30 14:57:11 +02:00
1732bfa82c
Fixed _default_docstring regex. 2023-09-30 14:36:08 +02:00
ecffbf29bf
Skip vararg/varkw parameters from the config snippet. 2023-09-30 13:53:33 +02:00
c82f7bbfbe
Ignore the default docstring text for __init__.
If no docstring is specified for a constructor, Python usually pre-fills
a standard text - "Initialize self. See help(type(self))".

We don't need this default text in our plugins documentation.
2023-09-30 13:29:49 +02:00
15d06fa5c2
Improved docstring parser logic. 2023-09-30 12:35:31 +02:00
343972b520
New IntegrationMetadata generic util class.
This object is in charge of parsing all the metadata of a
plugin/backend.
2023-09-30 02:28:20 +02:00
a872d6f554
Added Fedora to the available Docker base images. 2023-09-22 19:02:13 +02:00
3e8d6bb01e Removed typing-extensions dependency.
The package isn't present on older versions of Debian.
2023-09-18 14:05:39 +02:00
b746d0b402
Moved get_message_response to platypush.utils.
It is general-purpose enough to be used by all the integrations, not
only by the HTTP backend.
2023-09-05 13:03:30 +02:00
9aaf2559fa
Added utils.is_root method. 2023-08-31 23:21:32 +02:00
429658e7c8
Refactored PackageManager classes.
Instead of having a custom `get_installed` callable field, with
replicated code for each package manager, the field has now been
promoted to a class method containing the common logic, and the
instances now expect a `list` field (base command to list the installed
packages using the specified package manager) and a `parse_list_line`
callback field (to extract the base package name given a raw line from
the command above).

Also, we shouldn't run the list command if we're running within a Docker
context - the host and container environments will be different.
2023-08-28 01:26:19 +02:00
f230fa79bb
to_pkg_install_commands should skip already installed sys packages. 2023-08-23 11:51:53 +02:00
449821673c
Added PackageManager.get_installed. 2023-08-23 10:50:29 +02:00
b10ccdb313
Added get_src_root utility function. 2023-08-23 02:53:31 +02:00
1ef0d804db
Added full_command argument to to_pip_install_commands.
This is useful if we just want to get the list of pip dependencies and
create our own pip command.
2023-08-23 02:19:54 +02:00
2bff4c9cf1
Exclude python-* system packages when installing in a venv. 2023-08-23 02:17:19 +02:00
cddf318fa7
Dependencies.from_config should include the base system deps. 2023-08-23 02:16:33 +02:00
8f39231d31
Added new utility methods to the Dependencies class. 2023-08-23 02:15:50 +02:00
10c0e5fcad
Added default_os field to PackageManagers enum elements.
This is useful to determine which is the default set of scripts that
should be used by the installer depending on the detected installed
package manager.
2023-08-20 21:21:37 +02:00
a6f8021150
PackageManager has both install and uninstall. 2023-08-20 13:33:49 +02:00
28ba042810
If no configuration file is passed to platydock generate a minimal Dockerfile. 2023-08-20 03:36:34 +02:00
71c5291190
Refactored the interface of Platydock and manifest utils. 2023-08-19 22:46:37 +02:00
9002f3034a
Tweaked package managers install command arguments. 2023-08-19 13:46:08 +02:00