Log the User Agent when a websocket is opened.
When a websocket is closed log the close code, close Reason, and
time elapsed since the last pong was recieved from the client.
When Moonraker shuts down send a 1001 Code with Server Shutdown
as the reason.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
Adds support for GPIO buttons. Each button is configured to render
a template when pressed and/or released. The button event
templates recieve a context with a "call_method" field, allowing
them to call nearly all Moonraker APIs.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
Allow base modules to register themselves as components during
initialization. This makes them accessible via lookup_component()
across the entire application.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
This commit will add parsing of optional filament name metadata for:
- PrusaSlicer and it's derivatives
- Simplify3D
- Cura
- IdeaMaker
For Cura and IdeaMaker it is necessary to add a custom start g-code comment.
Cura:
;Filament name = {material_name}
IdeaMaker:
;Filament name = {filament_name1}
Signed-off-by: Dominik Willner <th33xitus@gmail.com>
This commit will add parsing of optional filament type metadata for:
- PrusaSlicer and it's derivatives
- Cura
- IdeaMaker
For Cura and IdeaMaker it is necessary to add a custom start g-code comment.
Cura:
;Filament type = {material_type}
IdeaMaker:
;Filament type = {filament_name_abbreviation1}
Signed-off-by: Dominik Willner <th33xitus@gmail.com>
This commit will add parsing of optional nozzle diameter metadata for:
- PrusaSlicer and it's derivatives
- Simplify3D
- Cura
- IdeaMaker
For Cura and IdeaMaker it is necessary to add a custom start g-code comment.
Cura:
;Nozzle diameter = {machine_nozzle_size}
IdeaMaker:
;Nozzle diameter = {machine_nozzle_diameter1}
Signed-off-by: Dominik Willner <th33xitus@gmail.com>
The "user", "password", and "token" options are templates
that can resolve items stored in the secrets file.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
Add the secrets module as a Jinja2 Environment global.
All templates will be able to access secrets as if it were
a dictionary.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
Add support for an external "secrets" file that may contain
usernames, passwords, and tokens. This file may be in
"ini" or "json" format.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
Check for "Prusa" style embedded thumbnails by default for
all slicers. This is becoming a standard, as it is now available
in Cura, Ideamaker, and Simplify3D via plugins.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
Don't require that gcode files embed two thumbnails. When
a single large thumbnail is parsed use pillow to create a
small one.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
Cura's Octoprint plugin expects an "axes" field for each profile.
Report these values to match the default values used by the
plugin.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
Cura's Octoprint plugin does not set the 'start' flag on uploads
when UFP is enabled. Instead it waits for the upload to
finish then issues Octoprint's "file command" request. Add
limited support for this API, mimicing how uploads are normally
handled.
Singed-off-by: Eric Callahan <arksine.code@gmail.com>
If a dynamic request handler returns None with "wrap_result"
disabled, set the return status to 204.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
Move upload handler registration out of the file manager.
Register the primary hander in the app module, and the
Octoprint Comptaiblity handler in octoprint_compat.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>