Commit graph

1371 commits

Author SHA1 Message Date
e947cb1e67
Updated web dist files 2023-09-15 16:22:40 +02:00
4223576016
We should always update the entities cache on addEntity.
Updating the entity cache only when we receive an event from a root
entity means that we lose events sent by individual child entities.
2023-09-15 00:45:38 +02:00
1020b63da7
All EntityMixin components should be allowed to emit loading events. 2023-09-15 00:34:29 +02:00
8ab7b6bebc
Removed deprecated zigbee.mqtt backend.
Closes: #322
2023-09-06 02:54:48 +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
2c46b6fe14
Added git a required manifest dependency when needed.
It is needed for packages that install pip packages via git.
2023-08-20 21:19:15 +02:00
a6752ed034
Fixed wrong event path in a manifest file. 2023-08-20 14:08:22 +02:00
043f303761
s/HttpBackend._DEFAULT_HTTP_PORT/HttpBackend.DEFAULT_HTTP_PORT/g 2023-08-19 13:30:51 +02:00
c2b3ec8ce3
Fixed manifest files with outdated formats. 2023-08-19 12:54:33 +02:00
ec2b8da983
Ignore Redis errors when a backend sends an unregister notify event.
When that happens, it's most likely that the application is already
stopping and the Redis service has already been terminated.
2023-08-17 01:49:41 +02:00
98e9abde18
Extended manifest files with Python system packages (if available).
- If a Python optional dependency is available as a system package on
  the target system, try and install it that route rather than pip. It's
  usually faster and it decreases the risk of breaking system packages.

- Added support for apk dependencies in manifest files. This brings the
  number of distros officially supported by all the extensions to four:

  - Alpine
  - Arch
  - Debian
  - Ubuntu
2023-08-16 22:43:51 +02:00
46245e851f
Synchronize with the currently running stop thread (if any) in Backend.wait_stop. 2023-08-15 02:08:47 +02:00
a8a7ceb2ac
Implemented HttpBackend._stop_workers.
The Tornado WSGI container won't guarantee the termination of the
spawned workers upon termination, so the code of the backend has to take
care of it and terminate all the children processes of the server
process when it terminates.

This also means that `psutil` is now a required base dependency, as we
need to expand the process subtree under the webserver launcher.
2023-08-15 00:13:34 +02:00
ceb9d6d1ba
Removed redundant Backend._get_redis() method.
It was used only once, and it could easily be replaced by
`platypush.utils.get_redis()`.
2023-08-14 23:37:38 +02:00
827b564006
Using a single constant for DEFAULT_REDIS_QUEUE.
Also, catch `AttributeError` on `self._proc.terminate` in the
`HttpBackend`, since the process may already have been terminated and
set to null by another worker process.
2023-08-13 22:20:16 +02:00
1474685cc0
[Automatic] Updated UI files 2023-08-06 22:51:57 +00:00
26b4dcba46
Reduced padding of ConfirmDialog body element. 2023-08-07 00:50:10 +02:00
5184543a3e
Normalize the size of the camera frame container from window size.
If the window is smaller than the camera resolution, then we should
scale down the container size accordingly.
2023-08-07 00:38:19 +02:00
dd313c6371
[Automatic] Updated UI files 2023-08-06 21:50:25 +00:00
2f007888fc
[Automatic] Updated UI files 2023-08-06 21:48:33 +00:00
609a8c6052
[Automatic] Updated UI files 2023-08-06 21:46:44 +00:00
276a9a7421
[Automatic] Updated UI files 2023-08-06 21:44:51 +00:00
715cdcfcff
More consistent style for the buttons on the tokens settings page. 2023-08-06 23:42:50 +02:00
bd49e460d5
More style improvements for the user settings panel. 2023-08-06 23:36:06 +02:00
6eed558342
More improvements on the users settings panel. 2023-08-06 23:14:54 +02:00
1d47b35219
Updated UI dependencies 2023-08-06 20:38:46 +02:00
237e0c47cb
Redesigned config panel UI. 2023-08-06 18:49:03 +02:00
e4756eb639
Replaced deprecated flask.escape with markupsafe.escape. 2023-07-25 00:26:15 +02:00
91cd08cdff
Adapted tests to use a locally started Redis instance. 2023-07-24 10:37:07 +02:00
e9a568fdd2
Unified interface to retrieve the Redis bus configuration.
A common `utils.get_redis_conf` has been created to handle the cascade
fallback logic used to retrive the default Redis configuration.
2023-07-24 01:04:13 +02:00
dd862db29a
[chore] LINT fixes 2023-07-24 00:35:03 +02:00
0dc380fa94
Removed dependency from prctl.
Also, black'd and LINT-fixed some files that hadn't been touched in a
while.
2023-07-23 19:17:30 +02:00
cfdecd5703
[#267] Don't show the PWA popup again after the user dismisses it.
Plus, upgraded a bunch of frontend libraries.

Closes: #267
2023-07-23 02:44:17 +02:00
454228c56e
Upgraded UI dependencies 2023-07-23 02:42:14 +02:00
dependabot[bot]
33699fcac8
Bump word-wrap from 1.2.3 to 1.2.5 in /platypush/backend/http/webapp
Bumps [word-wrap](https://github.com/jonschlinkert/word-wrap) from 1.2.3 to 1.2.5.
- [Release notes](https://github.com/jonschlinkert/word-wrap/releases)
- [Commits](https://github.com/jonschlinkert/word-wrap/compare/1.2.3...1.2.5)

---
updated-dependencies:
- dependency-name: word-wrap
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-22 21:48:53 +00:00
dependabot[bot]
505cba44b8
Bump webpack from 5.70.0 to 5.88.2 in /platypush/backend/http/webapp
Bumps [webpack](https://github.com/webpack/webpack) from 5.70.0 to 5.88.2.
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.70.0...v5.88.2)

---
updated-dependencies:
- dependency-name: webpack
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-22 21:46:59 +00:00
66981bd00b
Updated email addresses and black'd some old source files. 2023-07-22 23:02:44 +02:00
fa1364d854
Improved logging for requests, responses and events.
- The following logging namespaces are now used, to make it easier to
  filter only log lines related to the logged application message:

  - `platypush:events`
  - `platypush:requests`
  - `platypush:responses`

- Those messages are always logged as JSON, with no prefixes nor
  suffixes.

- Requests are always logged when executed - no more delegation to the
  upstream backend.

- Responses are always logged when fully populated (including `id`,
  `origin`, `target` etc.), instead of being logged when still partially
  populated. This makes it particularly easy to link request/response
  IDs directly from the logs.
2023-07-15 01:11:45 +02:00
27cf1bec52
Removed some optional top-level imports.
Optional top-level imports in Tornado route declarations will trigger
`ImportError`. While this will just mean that those routes will be
skipped, it will also generate a lot of noise on the logs.
2023-07-01 03:13:38 +02:00
2fb6e4d7d0
Updated webapp dist files 2023-06-16 15:48:23 +02:00
9aa8e4538a
Better termination logic for the ffmpeg audio converter. 2023-06-16 11:47:37 +02:00
da93f1b3b0
[Chore] pylint 2023-06-14 01:44:36 +02:00
be794316a8
Merged sound.stream_recording and sound.record. 2023-06-12 13:06:02 +02:00
e238fcb6e4
Refactoring the sound plugin to use ffmpeg as a stream converter. 2023-06-11 12:48:49 +02:00
4587b262b0
Stream camera frames over HTTP using a Redis pub/sub mechanism. 2023-06-05 20:40:12 +02:00
d7208c6bbc
Refactored Tornado routes for native pub/sub support.
The Redis pub/sub mechanism is now a native feature for Tornado routes
through the `PubSubMixin`.

(Plus, lint/black chore for the sound plugin)
2023-05-30 21:58:27 +02:00
4bf9c01ac9
Moved camera routes.
Camera routes migrated from Flask blueprints to Tornado handlers.
2023-05-27 22:24:45 +02:00
a2f8e2f0d2
Fixed bottom margin for ConfirmDialog buttons 2023-05-22 16:44:53 +02:00
aaac6488d6
Updated webapp dist files 2023-05-22 02:24:24 +02:00
d7405ad05d
Added multiple parsers for the entities referenced in docstrings.
The `inspect` plugin can now detect references to plugins, backends,
events, responses and schemas in docstrings and replace them either with
links to the documentation or auto-generated examples.
2023-05-22 02:20:58 +02:00