1416 Commits

Author SHA1 Message Date
Eric Callahan
6c6b7dcff0
power: process bound services when initial_state is set
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-11-15 18:09:56 -05:00
WALDNER Emmanuel
975011d190
metadata : fix extract to work with Ideamaker
Correction of the regex (Replacing the = with one: and adding the filament index for the regex to work).

Signed-off-by: Emmanuel WALDNER emmanuel.waldner@gmail.com
2023-11-07 16:12:58 -05:00
Eric Callahan
27dddd62ac
extensions: support agent method registration
Create a websocket endpoint that allows clients identified as
agents to register remote methods with Klipper.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-11-07 11:27:11 -05:00
Eric Callahan
40011370a3
update_manager: improve Klipper detection
If the Klipper installation is not updatable (ie not a git repo)
abort reinstantion of the deployer.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-11-02 06:19:14 -04:00
Eric Callahan
e03dbe3251
app: raise tornado http exceptions in upload handler
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-30 14:56:33 -04:00
Eric Callahan
4f32f477bd
app: improve upload error handling
Use a lock to guarantee thread safety when parsing data.  If
parsing results an error, save the error and raise it.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-29 20:14:03 -04:00
Eric Callahan
a71c5c159d
spoolman: filter spool_id before setting it active
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-24 19:32:24 -04:00
Eric Callahan
2641fc54d6
proc_stats: fix vcio ioctl logging spam
Use the low level os.open() method to open the vcio device.  This
resolves "unknown ioctl" spamming of the kernel log.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-13 18:07:03 -04:00
Eric Callahan
b676773602
metadata: update deprecated pillow constant
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-10 18:23:26 -04:00
Eric Callahan
4fe99e6ebb
json_wrapper: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:37:42 -04:00
Eric Callahan
d721ec5d9c
update_manager: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:36:49 -04:00
Eric Callahan
6f6f535d6a
file_manager: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:36:16 -04:00
Eric Callahan
b4dfa5a4dd
zeroconf: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:35:58 -04:00
Eric Callahan
d25ddc954a
wled: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:35:29 -04:00
Eric Callahan
0afbefc962
simplyprint: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:33:56 -04:00
Eric Callahan
a28c7c3f93
power: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:33:20 -04:00
Eric Callahan
bfc7ea3635
notifier: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:31:58 -04:00
Eric Callahan
0e7c759bde
machine: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:31:41 -04:00
Eric Callahan
2a7594fc3b
job_state: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:31:15 -04:00
Eric Callahan
7219cc45a5
button: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:30:56 -04:00
Eric Callahan
0eae069666
announcements: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:30:42 -04:00
Eric Callahan
89dbefe46d
websockets: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:30:25 -04:00
Eric Callahan
ddd4a02e9c
server: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:30:08 -04:00
Eric Callahan
282cf1ce03
klippy_connection: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:29:57 -04:00
Eric Callahan
327441fd6b
confighelper: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:29:24 -04:00
Eric Callahan
9b0aec378e
common: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:29:04 -04:00
Eric Callahan
16c407e33c
app: fix linter errors
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 10:28:45 -04:00
Eric Callahan
8d0c8e4033
proc_stats: improve vcgencmd request
Improve the efficiency of "vcgencmd get_throttled" by directly requesting
the status from the user space driver using ioctl.  This should reduce CPU
spikes that result from forking the current process.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 07:40:41 -04:00
Eric Callahan
65644bab8b
utils: add ioctl_macros module
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-10-07 07:40:41 -04:00
Eric Callahan
d4c4b64cd5
loghelper: add newline to stdout header
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 07:10:14 -04:00
Eric Callahan
e073df40b0
zeroconf: detect appropriate ip version
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 07:10:13 -04:00
Eric Callahan
0c23630e87
mqtt: don't instantiate futures directly
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-07 07:10:12 -04:00
Eric Callahan
51f4d4b888
eventloop: add support for uvloop
Signed-off-by:  Eric Callahan <arskine.code@gmail.com>
2023-10-06 18:20:28 -04:00
Eric Callahan
f99e5b0bea
utils: add support for msgspec with stdlib json fallback
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-10-06 18:20:28 -04:00
Eric Callahan
4329241949
confighelper: fix inline comment parsing
Require that inline comments be separated from configuration
data by whitespace.  Unescape comment specifiers that follow
the correct escape sequence.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-06 12:25:26 -04:00
SHID
52ee49eed3
metadata: add support for Moment Slicer
Signed-off-by: Sanghun Jung / Email: sanghun.id@gmail.com
2023-10-05 08:08:22 -04:00
Eric Callahan
0c6b4e0dad
file_manager: fix reserved path handling during runtime
If the user creates or moves a folder that was is reserved
reserved correctly ignore or remove watches as appropriate.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-10-05 07:59:23 -04:00
Eric Callahan
a232260713
webcam: support lookup by UID
Expose the UID assigned to webcams and allow clients to fetch, modify,
and delete items based on the UID.  New additions must not specify a
UID.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-09-28 08:08:37 -04:00
Eric Callahan
ee62d07c68
zeroconf: use route prefix for zeroconf/ssdp servers
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-09-22 07:55:10 -04:00
Eric Callahan
ae1d3b0393
app: implement route prefix option
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-09-15 16:33:05 -04:00
Eric Callahan
3d9052d711
git_deploy: detached head verification fix
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-08-14 08:13:51 -04:00
Eric Callahan
47f0f0c21e
data_store: add support for temp monitors
Temperature Monitors may report null values as temperatures,
thus special handling is needed.  This commit also reworks
temperature store updates to use the subscription cache
rather than perform its own caching of "last temps".

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-08-03 06:13:21 -04:00
Eric Callahan
e433252934
paneldue: use cached subscription data
Now that all subscriptions are cached it is no longer required for
the paneldue component to cache its own printer state.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-07-31 11:19:04 -04:00
Eric Callahan
d3bab5de94
klippy_apis: support subscription callbacks
This callback will only fire after a component has requested
a subscription, preventing early updates while the component
is waiting for the subscription request to complete.  It is still
valid for components to register the "server:status_update"
event handler if this behavior is not a concern.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-07-30 16:30:00 -04:00
Eric Callahan
7e85ac97c9
klippy_connection: cache subscription data
It is possible that a subscripition request can occur between
after Klipper updates a field's status, but before it pushes
a status update to the connection.  The result is a race
condiiton where the response to the subscription request
contains the lastest state but it is not propagated to
currently connected clients.

This is resolved by caching subscripiton data, diffing it
with the response to the subscription request, and
manually pushing the diff.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-07-30 15:35:13 -04:00
Eric Callahan
8ad19e6054
web_deploy: return repo name in status response
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-07-30 15:35:13 -04:00
Eric Callahan
6467cc6b89
klippy_connection: refactor KlippyRequest class
Wrap a Future instead of an Event, as we don't need to notify multiple
waiters. Additionally the future can return responses and raise exceptions
directly.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-07-30 15:35:13 -04:00
Eric Callahan
c3697d0656
klippy_connection: apply a mutex to the subscription request
The subscripition request is reentrant in Klippy.  Sending multiple
requests from the same connection may create a race condition,
so use a lock to prevent reentry.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-07-30 15:35:12 -04:00
Eric Callahan
7c8d68c0a1
components: fix pycodestyle E721 warnings
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-07-30 15:34:56 -04:00
Eric Callahan
f487de77bc
webcam: make sure db values are type correct
A previous bug in the webcam module could have set boolean
values as integers.  Make sure they are type correct when
reading webcams from the db.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-07-28 16:28:04 -04:00