diff --git a/AUTHORS.md b/AUTHORS.md index ae615647f..d6d0a9971 100644 --- a/AUTHORS.md +++ b/AUTHORS.md @@ -1,6 +1,6 @@ # Authors -The following people have contributed to OctoPrint's code base (ordered by +The following people have contributed to OctoPrint's code base (ordered roughly by date of first contribution): * [Gina Häußge](https://github.com/foosel) @@ -61,10 +61,11 @@ date of first contribution): * [Siim Raud](https://github.com/2ndalpha) * ["geoporalis"](https://github.com/geoporalis) * [Andrew Malota](https://github.com/2bitoperations) - * [Alexander Leisentritt](https://github.com/Alex9779) - * [therealbstern](https://github.com/therealbstern) * [Ishwar Agarwal](https://github.com/agarwali) * [Kye Hoover](https://github.com/eykrevooh) + * [Joseph Carrick](https://github.com/carricktel) + * [Alexander Leisentritt](https://github.com/Alex9779) + * [therealbstern](https://github.com/therealbstern) * [Philipp Baum](https://github.com/philphilphil) * [Kyle Evans](https://github.com/kevans91) * [Javier Martínez Arrieta](https://github.com/Javierma) @@ -80,9 +81,11 @@ date of first contribution): * [Greg Hulands](https://github.com/ghulands) * [Andreas Werner](https://github.com/gallore) * [Shawn Bruce](https://github.com/kantlivelong) - * [Claudiu Ceia] (https://github.com/ClaudiuCeia) + * [Claudiu Ceia](https://github.com/ClaudiuCeia) * [Goswin von Brederlow](https://github.com/mrvn) * [Luke McKechnie](https://github.com/galamdring) + * [Peter Backx](https://github.com/pbackx) + * [Josh Major](https://github.com/astateofblank) OctoPrint started off as a fork of [Cura](https://github.com/daid/Cura) by [Daid Braam](https://github.com/daid). Parts of its communication layer and diff --git a/docs/api/connection.rst b/docs/api/connection.rst index c0bc75377..721e92cac 100644 --- a/docs/api/connection.rst +++ b/docs/api/connection.rst @@ -39,7 +39,7 @@ Get connection settings "options": { "ports": ["/dev/ttyACM0", "VIRTUAL"], "baudrates": [250000, 230400, 115200, 57600, 38400, 19200, 9600], - "printerProfiles": [{"name": "Default", id: "_default"}], + "printerProfiles": [{"name": "Default", "id": "_default"}], "portPreference": "/dev/ttyACM0", "baudratePreference": 250000, "printerProfilePreference": "_default", diff --git a/docs/api/files.rst b/docs/api/files.rst index 76b80132e..188731a40 100644 --- a/docs/api/files.rst +++ b/docs/api/files.rst @@ -192,6 +192,7 @@ Retrieve all files "refs": { "resource": "http://example.com/api/files/local/folderA/subfolder", } + } ], "size": 1334, "refs": { diff --git a/docs/api/languages.rst b/docs/api/languages.rst index ac7b988f2..ecb83102a 100644 --- a/docs/api/languages.rst +++ b/docs/api/languages.rst @@ -39,9 +39,7 @@ Retrieve installed language packs "_core": { "identifier": "_core", "name": "Core", - "languages": [ - ... - ] + "languages": [] }, "some_plugin": { "identifier": "some_plugin", @@ -61,7 +59,6 @@ Retrieve installed language packs "last_update": 1470859680, "author": "The italian Transifex Team" } - ... ] } } @@ -124,9 +121,7 @@ Delete a language pack "_core": { "identifier": "_core", "name": "Core", - "languages": [ - ... - ] + "languages": [] }, "some_plugin": { "identifier": "some_plugin", @@ -138,8 +133,7 @@ Delete a language pack "locale_english": "German", "last_update": 1474574597, "author": "Gina Häußge" - }, - ... + } ] } } diff --git a/docs/api/settings.rst b/docs/api/settings.rst index acc797220..b26b2d25d 100644 --- a/docs/api/settings.rst +++ b/docs/api/settings.rst @@ -62,10 +62,11 @@ Save settings { "api": { - "enabled": true, - // ... + "enabled": true }, - // ... + "appearance": { + "color": "black" + } } .. _sec-api-settings-generateapikey: diff --git a/docs/api/slicing.rst b/docs/api/slicing.rst index 010f1af74..129653171 100644 --- a/docs/api/slicing.rst +++ b/docs/api/slicing.rst @@ -58,11 +58,9 @@ List All Slicers and Slicing Profiles "displayName": "Medium Quality", "default": true, "resource": "http://example.com/api/slicing/cura/profiles/medium_quality" - }, - ... + } } - }, - ... + } } :statuscode 200: No error @@ -104,8 +102,7 @@ List Slicing Profiles of a Specific Slicer "displayName": "Medium Quality", "default": true, "resource": "http://example.com/api/slicing/cura/profiles/medium_quality" - }, - ... + } } :param slicer: The identifying key of the slicer for which to list the available profiles. @@ -147,8 +144,7 @@ Retrieve Specific Profile "brim_line_count": 20, "cool_head_lift": false, "cool_min_feedrate": 10.0, - "cool_min_layer_time": 5.0, - ... + "cool_min_layer_time": 5.0 } } diff --git a/docs/api/system.rst b/docs/api/system.rst index 08968cece..9bf0907ff 100644 --- a/docs/api/system.rst +++ b/docs/api/system.rst @@ -154,7 +154,7 @@ Execute a registered system command .. sourcecode:: http - 204 No Content + HTTP/1.1 204 No Content :param source: The source for which to list commands, currently either ``core`` or ``custom`` :param action: The identifier of the command, ``action`` from its definition diff --git a/docs/bundledplugins/pluginmanager.rst b/docs/bundledplugins/pluginmanager.rst index d2a923e85..dacb3f8ca 100644 --- a/docs/bundledplugins/pluginmanager.rst +++ b/docs/bundledplugins/pluginmanager.rst @@ -104,13 +104,13 @@ octoprint.plugin.pluginmanager.reconnect_hooks .. code-block:: python - def reconnect_hooks_hook(*args, **kwargs): - return ["octoprint.plugin.exampleplugin.some_custom_hook", - "octoprint.plugin.exampleplugin.some_other_custom_hook"] + def reconnect_hooks_hook(*args, **kwargs): + return ["octoprint.plugin.exampleplugin.some_custom_hook", + "octoprint.plugin.exampleplugin.some_other_custom_hook"] - __plugin_hooks__ = { - "octoprint.plugin.pluginmanager.reconnect_hooks": reconnect_hooks_hook - } + __plugin_hooks__ = { + "octoprint.plugin.pluginmanager.reconnect_hooks": reconnect_hooks_hook + } .. _sec-bundledplugins-pluginmanager-sourcecode: diff --git a/docs/bundledplugins/softwareupdate.rst b/docs/bundledplugins/softwareupdate.rst index 763a0de5e..b68a6751b 100644 --- a/docs/bundledplugins/softwareupdate.rst +++ b/docs/bundledplugins/softwareupdate.rst @@ -14,14 +14,14 @@ First Steps Out of the box the Software Update Plugin will be able to notify you of any updates that might be available for your OctoPrint installation or any plugins -that registered themselves with it. In order to also be able to update -your OctoPrint installation, you'll need to configure -at least OctoPrint's checkout folder, and you also should -configure the restart commands for OctoPrint and the whole server. +that registered themselves with it. In order for automatic restarts after updates +to work, you should configure the restart commands for OctoPrint and the whole server. -For configuring the plugin you'll need to go into OctoPrint's Settings Dialog, navigate to the -Software Upda.. _section therein and once you are there click on the little wrench icon in the -upper right corner. +Out of the box the plugin should already be ready to update your OctoPrint installation to current +stable release versions, but you can also switch to one of the available release candidate channels +or outright git commit tracking via the plugin's configuration dialog. To open this dialog, fire up OctoPrint's +Settings Dialog, navigate to the Software Update section therein and once you are there click on the little +wrench icon in the upper right corner. .. _fig-bundledplugins-softwareupdate-plugin-configuration: .. figure:: ../images/bundledplugins-softwareupdate-plugin-configuration.png @@ -32,31 +32,16 @@ upper right corner. There you can adjust the following settings: - * **OctoPrint checkout folder**: This should be the path to OctoPrint's git checkout folder (``/home/pi/OctoPrint`` - for OctoPi or `manual installs following the Raspberry Pi setup guide `_). - This must be set to allow updating from within OctoPrint - - .. note:: - - OctoPi releases 0.12.0 and later ship with this already setup for you. - - .. note:: - - **OctoPi 0.11.0 users**: Please also take a look at - `the note at the very end of this FAQ entry `_. - Due to a little issue in that OctoPi release 0.11.0 you might have to fix - the URL your OctoPrint checkout is using for updating. This can easily be - done by SSHing into your OctoPi instance and doing this:: - - cd ~/OctoPrint - git remote set-url origin https://github.com/foosel/OctoPrint.git - * **OctoPrint version tracking**: Whether you want to track OctoPrint *releases* or every *commit*. Usually you want to select "Release" here which is also the default, unless you are a developer. - * **OctoPrint Release Channel**: The release channel of OctoPrint to track for updates. If you only want stable versions, + * **OctoPrint Release Channel** (if tracking releases): The release channel of OctoPrint to track for updates. If you only want stable versions, select "Stable" here which is also the default. "Maintenance RCs" will also allow you to update to maintenance release candidates, "Devel RCs" will also allow you to update to development release candidates. If in doubt, leave it at "Stable". `Read more about Release Channels here `_. + * **OctoPrint checkout folder** (if tracking git commits): This must be the path to OctoPrint's git checkout folder + (``/home/pi/OctoPrint`` for OctoPi or `manual installs following the Raspberry Pi setup guide `_). + Note that since OctoPrint 1.3.6 you will no longer need to set this to be able to update to releases, only if you + want to be able to update against some bleeding edge git branch. * **Version cache TTL**: The "time to live" of the cache OctoPrint will use to temporarily persist the version information for the various components registered with the plugin, so that they don't have to be queried from the internet every time you load the page. Defaults to 24h, you usually shouldn't need to change that value. @@ -132,30 +117,29 @@ Configuring the Plugin .. code-block:: yaml - plugins: - softwareupdate: - # the time-to-live of the version cache, in minutes - cache_ttl: 60 + plugins: + softwareupdate: + # the time-to-live of the version cache, in minutes + cache_ttl: 60 - # configured version check and update methods - checks: - # "octoprint" is reserved for OctoPrint - octoprint: - # this defines an version check that will check against releases - # published on OctoPrint's Github repository and an update method - # utilizing an (included) update script that will be run on - # OctoPrint's checkout folder - type: github_release - user: foosel - repo: OctoPrint - update_script: '{python} "/path/to/octoprint-update.py" --python="{python}" "{folder}" "{target}"' - update_folder: /path/to/octoprint/checkout/folder + # configured version check and update methods + checks: + # "octoprint" is reserved for OctoPrint + octoprint: + # this defines an version check that will check against releases + # published on OctoPrint's Github repository and pip as update method + # against the release archives on Github - this is the default + type: github_release + user: foosel + repo: OctoPrint + method: pip + pip: 'https://github.com/foosel/OctoPrint/archive/{target_version}.zip' - # further checks may be define here + # further checks may be define here - # pip command, if another one than the automatically detected one should be - # used - should normally NOT be necessary and hence set - pip_command: /path/to/pip + # pip command, if another one than the automatically detected one should be + # used - should normally NOT be necessary and hence set + pip_command: /path/to/pip .. _sec-bundledplugins-softwareupdate-configuration-versionchecks: @@ -249,6 +233,32 @@ Update methods :ref:`hook `. A python callable which performs the update, see below for details. +.. note:: + + To allow default configurations for multiple update methods, if more than one of + the above update method specific settings is set the one to use can be selected + by setting the property ``method`` to the method specific setting in question. + + **Example** + + The following example defines both ``pip`` and ``update_script``. By setting to + ``method`` to ``pip``, the Software Update plugin is instructed to use that as + update method. + + .. code-block:: yaml + + plugins: + softwareupdate: + checks: + octoprint: + type: github_release + user: foosel + repo: OctoPrint + method: pip + pip: 'https://github.com/foosel/OctoPrint/archive/{target_version}.zip' + update_script: '{python} "/path/to/octoprint-update.py" --python="{python}" "{folder}" "{target}"' + checkout_folder: /path/to/octoprint/checkout/folder + .. _sec-bundledplugins-softwareupdate-configuration-patterns: Common configuration patterns @@ -268,6 +278,7 @@ plugin itself): user: foosel repo: OctoPrint branch: devel + method: update_script update_folder: /home/pi/OctoPrint Plugin installed via pip and hosted on Github under diff --git a/docs/configuration/config_yaml.rst b/docs/configuration/config_yaml.rst index 81c147cd5..3465fd5d1 100644 --- a/docs/configuration/config_yaml.rst +++ b/docs/configuration/config_yaml.rst @@ -855,7 +855,12 @@ Use the following settings to configure the serial connection to the printer: # Command to send in order to initiate a handshake with the printer. # Defaults to "M110 N0" which simply resets the line numbers in the firmware and which # should be acknowledged with a simple "ok". - helloCommand: M110 N0 + helloCommand: + - M110 N0 + + # Commands that should never be auto-uppercased when sent to the printer. Defaults to only M117. + autoUppercaseBlacklist: + - M117 # Whether to disconnect on errors or not disconnectOnErrors: true diff --git a/docs/development/environment.rst b/docs/development/environment.rst index 785e90fda..253956c7f 100644 --- a/docs/development/environment.rst +++ b/docs/development/environment.rst @@ -58,7 +58,7 @@ Then: virtualenv venv source ./venv/bin/activate pip install --upgrade pip - pip install -e .[develop] + pip install -e .[develop,plugins] You can then start OctoPrint via ``~/devel/OctoPrint/venv/bin/octoprint`` or just ``octoprint`` if you activated the virtual environment. @@ -89,11 +89,11 @@ Open the Git Bash you just installed and in that: git clone https://github.com/foosel/OctoPrint.git cd OctoPrint virtualenv venv - source ./venv/bin/activate + source ./venv/Scripts/activate pip install --upgrade pip - pip install -e .[develop] + pip install -e .[develop,plugins] -You can then start OctoPrint via ``/c/Devel/OctoPrint/venv/bin/octoprint`` or just ``octoprint`` if you activated the virtual +You can then start OctoPrint via ``/c/Devel/OctoPrint/venv/Scripts/octoprint`` or just ``octoprint`` if you activated the virtual environment. .. _sec-development-environment-mac: @@ -136,7 +136,8 @@ You'll need a user account with administrator privileges. cd OctoPrint virtualenv venv source venv/bin/activate - pip install -e .[develop] + pip install --upgrade pip + pip install -e .[develop,plugins] You can then start OctoPrint via ``~/devel/OctoPrint/venv/bin/octoprint`` or just ``octoprint`` if you activated the virtual environment. @@ -165,10 +166,16 @@ PyCharm * Name: OctoPrint server * Script: path to ``run`` in the OctoPrint checkout folder (e.g. ``~/devel/OctoPrint/run`` or ``C:\Devel\OctoPrint\run``) - * Script parameters: ``--debug`` + * Script parameters: ``serve --debug`` * Project: ``OctoPrint`` * Python interpreter: the ``venv`` local virtual environment * Working directory: the OctoPrint checkout folder (e.g. ``~/devel/OctoPrint`` or ``C:\Devel\OctoPrint``) + * If you want dependencies to auto-update on run if necessary: "Before Launch" > "+" > "Run external tool" > "+" + + * Name: Update OctoPrint dependencies + * Program: ``$PyInterpreterDirectory$/pip`` (or ``$PyInterpreterDirectory$/pip.exe`` on Windows) + * Parameters: ``install -e .[develop,plugins]`` + * Working directory: ``$ProjectFileDir$`` .. note:: diff --git a/docs/images/bundledplugins-softwareupdate-plugin-configuration.png b/docs/images/bundledplugins-softwareupdate-plugin-configuration.png index 7d5a672cb..ba13a9973 100644 Binary files a/docs/images/bundledplugins-softwareupdate-plugin-configuration.png and b/docs/images/bundledplugins-softwareupdate-plugin-configuration.png differ diff --git a/docs/jsclientlib/index.rst b/docs/jsclientlib/index.rst index d97da3bf4..8fcc6ee18 100644 --- a/docs/jsclientlib/index.rst +++ b/docs/jsclientlib/index.rst @@ -14,7 +14,7 @@ If you are using it from a web page hosted on OctoPrint as a Jinja2 template, yo methods to embed it instead of manually entering the URL, in order to have OctoPrint take care of setting the correct URL prefix: -.. code-block:: html +.. code-block:: html+jinja