Merge branch 'maintenance' into devel

# Conflicts:
#	.versioneer-lookup
This commit is contained in:
Gina Häußge committed 2020-08-06 12:43:11 +02:00
commit 99293b9ccf
12 files changed
+122 -55

No files matched your search

+33
View File
@@ -0,0 +1,33 @@
name: "Issue Labeler"
on:
issues:
types: [opened, edited]
jobs:
apply-label:
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
let labels = [];
if (context.payload.issue.title.match(/\[request\]|feature request/i)) {
labels.push('type:request');
}
if (context.payload.issue.title.match(/\[brainstorming\]/i)) {
labels.push('type:brainstorming');
}
if (context.payload.issue.title.match(/\[rc feedback\]/i)) {
labels.push('type:rc feedback');
}
if (labels.length > 0) {
github.issues.addLabels({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
labels: labels
})
}
+8 -5
View File
@@ -18,11 +18,14 @@ prerelease
HEAD
\(detached.*
# maintenance is currently the branch for preparation of maintenance release 1.4.2
# maintenance is currently the branch for preparation of maintenance release 1.4.3
# so are any fix/... and improve/... branches
maintenance 1.4.2 42769dad7dda3bc0c6c94e0e8ce832af9b14a565 pep440-dev
fix/.* 1.4.2 42769dad7dda3bc0c6c94e0e8ce832af9b14a565 pep440-dev
improve/.* 1.4.2 42769dad7dda3bc0c6c94e0e8ce832af9b14a565 pep440-dev
maintenance 1.4.3 42769dad7dda3bc0c6c94e0e8ce832af9b14a565 pep440-dev
fix/.* 1.4.3 42769dad7dda3bc0c6c94e0e8ce832af9b14a565 pep440-dev
improve/.* 1.4.3 42769dad7dda3bc0c6c94e0e8ce832af9b14a565 pep440-dev
# staging/hotfix is the branch for preparation of the 1.4.2 hotfix release
staging/hotfix 1.4.2 3ab84ed7e4c3aaaf71fe0f184b465f25d689f929 pep440-dev
# staging/maintenance is currently the branch for preparation of 1.4.1rc5
# so is regressionfix/...
@@ -32,5 +35,5 @@ regressionfix/.* 1.4.1rc5 458ab91f915307857941f839a1b743430b8786a4 pep440-dev
# staging/devel is currently inactive (but has the 1.4.1rc4 namespace)
staging/devel 1.4.1rc4 650d54d1885409fa1d411eb54b9e8c7ff428910f pep440-dev
# every other branch is a development branch and thus gets resolved to 2.0.0-dev for now
# every other branch is a development branch and thus gets resolved to 2.0.0.dev for now
.* 2.0.0 2da7aa358d950b4567aaab8f18d6b5779193e077 pep440-dev
+1 -5
View File
@@ -35,7 +35,6 @@ thanks to everyone who contributed!
* Kaile Riser
* Kale Stedman
* Kazuhiro Ogura
* Kelly C McNiece
* Kenneth Jiang
* Kurt Wubbels
* Kyle Menigoz
@@ -43,19 +42,16 @@ thanks to everyone who contributed!
* Lee Dohm
* Makespace Madrid
* Mark Walker
* Marvin Nahmias
* Michael Aumock
* Miles Flavel
* Mosaic Manufacturing
* Neil R. Goldberg
* Patrick Glyré
* Patrick McGinnis
* Prof Yuh Wen Chen
* Raise3D
* Randy C. Will
* Ranjib Dey
* Richard Michaud
* Rigid3D
* Robert Gusek
* Ronald Griehsler
* Sacha Telgenhof
@@ -66,4 +62,4 @@ thanks to everyone who contributed!
* Sven Mueller
* Ulrich Kempken
and 1932 more wonderful people pledging on the [Patreon campaign](https://patreon.com/foosel) or via [Github Sponsors](https://github.com/users/foosel/sponsorship)!
and 1943 more wonderful people pledging on the [Patreon campaign](https://patreon.com/foosel) or via [Github Sponsors](https://github.com/users/foosel/sponsorship)!
+2 -1
View File
@@ -153,7 +153,8 @@ class DiscoveryPlugin(octoprint.plugin.StartupPlugin,
##~~ ShutdownPlugin API -- used for unregistering OctoPrint's Zeroconf and SSDP service upon application shutdown
def on_shutdown(self):
for key in self._zeroconf_registrations:
registrations = list(self._zeroconf_registrations.keys())
for key in registrations:
reg_type, port = key
self.zeroconf_unregister(reg_type, port)
@@ -13,8 +13,8 @@ from octoprint.util.version import get_octoprint_version_string, is_released_oct
from flask import jsonify
from flask_babel import gettext
SENTRY_URL_SERVER = "https://9a2cb386ed8640e8a7fa0276f613be69@o118517.ingest.sentry.io/1373987"
SENTRY_URL_COREUI = "https://2350156be0954d299dd07a4cef2650b2@o118517.ingest.sentry.io/1374096"
SENTRY_URL_SERVER = "https://d479a74f172d4ac2b959a9a7d0536a82@o118517.ingest.sentry.io/1373987"
SENTRY_URL_COREUI = "https://040577fb88b241ff985e408c11775720@o118517.ingest.sentry.io/1374096"
SETTINGS_DEFAULTS = dict(enabled=False,
enabled_unreleased=False,
@@ -157,7 +157,7 @@ class PluginManagerPlugin(octoprint.plugin.SimpleApiPlugin,
def increase_upload_bodysize(self, current_max_body_sizes, *args, **kwargs):
# set a maximum body size of 50 MB for plugin archive uploads
return [("POST", r"/upload_archive", 50 * 1024 * 1024)]
return [("POST", r"/upload_file", 50 * 1024 * 1024)]
# Additional permissions hook
+16 -11
View File
@@ -283,6 +283,7 @@ class Server(object):
util.tornado.fix_json_encode()
util.tornado.fix_websocket_check_origin()
util.flask.fix_flask_jsonify()
util.watchdog.fix_scandir()
self._setup_mimetypes()
@@ -818,18 +819,22 @@ class Server(object):
self._logger.exception("Something went wrong while attempting to automatically connect to the printer")
# start up watchdogs
watched = self._settings.getBaseFolder("watched")
watchdog_handler = util.watchdog.GcodeWatchdogHandler(fileManager, printer)
watchdog_handler.initial_scan(watched)
try:
watched = self._settings.getBaseFolder("watched")
watchdog_handler = util.watchdog.GcodeWatchdogHandler(fileManager, printer)
watchdog_handler.initial_scan(watched)
if self._settings.getBoolean(["feature", "pollWatched"]):
# use less performant polling observer if explicitly configured
observer = PollingObserver()
else:
# use os default
observer = Observer()
observer.schedule(watchdog_handler, watched, recursive=True)
observer.start()
if self._settings.getBoolean(["feature", "pollWatched"]):
# use less performant polling observer if explicitly configured
observer = PollingObserver()
else:
# use os default
observer = Observer()
observer.schedule(watchdog_handler, watched, recursive=True)
observer.start()
except Exception:
self._logger.exception("Error starting watched folder observer")
# run our startup plugins
octoprint.plugin.call_plugin(octoprint.plugin.StartupPlugin,
+24
View File
@@ -17,6 +17,30 @@ import octoprint.filemanager.util
import octoprint.util
def fix_scandir():
try:
from os import scandir
# nothing to fix, natively available, return
return
except ImportError:
# not natively available, use backport
from scandir import scandir
import watchdog.utils.dirsnapshot
OriginalDirectorySnapshot = watchdog.utils.dirsnapshot.DirectorySnapshot
class FixedDirectorySnapshot(OriginalDirectorySnapshot):
def __init__(self, listdir=scandir, *args, **kwargs):
OriginalDirectorySnapshot.__init__(self, listdir=listdir, *args, **kwargs)
watchdog.utils.dirsnapshot.DirectorySnapshot = FixedDirectorySnapshot
import watchdog.observers.polling
OriginalPollingEmitter = watchdog.observers.polling.PollingEmitter
class FixedPollingEmitter(OriginalPollingEmitter):
def __init__(self, listdir=scandir, *args, **kwargs):
OriginalPollingEmitter.__init__(self, listdir=listdir, *args, **kwargs)
watchdog.observers.polling.PollingEmitter = FixedPollingEmitter
class GcodeWatchdogHandler(watchdog.events.PatternMatchingEventHandler):
"""
+1
View File
@@ -3587,6 +3587,7 @@ class MachineCom(object):
@property
def _checksum_enabled(self):
return not self._neverSendChecksum and ((self.isPrinting() and self._currentFile and self._currentFile.checksum) or
self._manualStreaming or
self._alwaysSendChecksum or
not self._firmware_info_received)
+6 -2
View File
@@ -15,6 +15,7 @@ import re
import netifaces
import requests
import werkzeug.http
_cached_check_v6 = None
def check_v6():
@@ -201,9 +202,12 @@ def resolve_host(host):
def download_file(url, folder, max_length=None):
with requests.get(url, stream=True) as r:
r.raise_for_status()
filename = None
if "Content-Disposition" in r.headers.keys():
filename = re.findall("filename=(.+)", r.headers["Content-Disposition"])[0]
else:
_, options = werkzeug.http.parse_options_header(r.headers["Content-Disposition"])
filename = options.get('filename')
if filename is None:
filename = url.split("/")[-1]
assert len(filename) > 0
+27 -27
View File
@@ -46,7 +46,7 @@
"extend": "3.0.2",
"forever-agent": "0.6.1",
"form-data": "2.3.3",
"har-validator": "5.1.3",
"har-validator": "5.1.5",
"http-signature": "1.2.0",
"is-typedarray": "1.0.0",
"isstream": "0.1.2",
@@ -104,9 +104,9 @@
"integrity": "sha512-7EJYyKTL7tFR8+gDbB6Wwz/arpGa0Mywk1TJbNzKzHtzbwVmY4HR9WqS5VV7dsBUKQmPNr192jHr/VpBluj/hg=="
},
"ajv": {
"version": "6.12.2",
"resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.2.tgz",
"integrity": "sha512-k+V+hzjm5q/Mr8ef/1Y9goCmlsK4I6Sm74teeyGvFk1XrOsbsKLjEdrvny42CZ+a8sXbk8KWpY/bDwS+FLL2UQ==",
"version": "6.12.3",
"resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.3.tgz",
"integrity": "sha512-4K0cK3L1hsqk9xIb2z9vs/XU+PGJZ9PNpJRDS9YLzmNdX6jmVPfamLvTJr0aDAusnHyCHO6MjzlkAsgtqp9teA==",
"requires": {
"fast-deep-equal": "3.1.3",
"fast-json-stable-stringify": "2.1.0",
@@ -380,9 +380,9 @@
}
},
"cypress": {
"version": "4.9.0",
"resolved": "https://registry.npmjs.org/cypress/-/cypress-4.9.0.tgz",
"integrity": "sha512-qGxT5E0j21FPryzhb0OBjCdhoR/n1jXtumpFFSBPYWsaZZhNaBvc3XlBUDEZKkkXPsqUFYiyhWdHN/zo0t5FcA==",
"version": "4.12.0",
"resolved": "https://registry.npmjs.org/cypress/-/cypress-4.12.0.tgz",
"integrity": "sha512-ZDngKMwoQ2UYmeSUJikLMZG6t2N7lTHHlzBzh5W0MbPfXSMv36YUgL2ZVD+t4ZLA63WWkvhwxIkDG+WJknBgHw==",
"requires": {
"@cypress/listr-verbose-renderer": "0.4.1",
"@cypress/request": "2.88.5",
@@ -398,7 +398,7 @@
"commander": "4.1.1",
"common-tags": "1.8.0",
"debug": "4.1.1",
"eventemitter2": "6.4.2",
"eventemitter2": "6.4.3",
"execa": "1.0.0",
"executable": "4.1.1",
"extract-zip": "1.7.0",
@@ -408,10 +408,10 @@
"is-installed-globally": "0.3.2",
"lazy-ass": "1.6.0",
"listr": "0.14.3",
"lodash": "4.17.15",
"lodash": "4.17.19",
"log-symbols": "3.0.0",
"minimist": "1.2.5",
"moment": "2.26.0",
"moment": "2.27.0",
"ospath": "1.2.2",
"pretty-bytes": "5.3.0",
"ramda": "0.26.1",
@@ -578,9 +578,9 @@
"integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ="
},
"eventemitter2": {
"version": "6.4.2",
"resolved": "https://registry.npmjs.org/eventemitter2/-/eventemitter2-6.4.2.tgz",
"integrity": "sha512-r/Pwupa5RIzxIHbEKCkNXqpEQIIT4uQDxmP4G/Lug/NokVUWj0joz/WzWl3OxRpC5kDrH/WdiUJoR+IrwvXJEw=="
"version": "6.4.3",
"resolved": "https://registry.npmjs.org/eventemitter2/-/eventemitter2-6.4.3.tgz",
"integrity": "sha512-t0A2msp6BzOf+QAcI6z9XMktLj52OjGQg+8SJH6v5+3uxNpWYRR3wQmfA+6xtMU9kOC59qk9licus5dYcrYkMQ=="
},
"execa": {
"version": "1.0.0",
@@ -758,11 +758,11 @@
"integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI="
},
"har-validator": {
"version": "5.1.3",
"resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz",
"integrity": "sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g==",
"version": "5.1.5",
"resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.5.tgz",
"integrity": "sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w==",
"requires": {
"ajv": "6.12.2",
"ajv": "6.12.3",
"har-schema": "2.0.0"
}
},
@@ -935,7 +935,7 @@
"listr-update-renderer": "0.5.0",
"listr-verbose-renderer": "0.5.0",
"p-map": "2.1.0",
"rxjs": "6.6.0"
"rxjs": "6.6.2"
}
},
"listr-silent-renderer": {
@@ -1032,9 +1032,9 @@
}
},
"lodash": {
"version": "4.17.15",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.15.tgz",
"integrity": "sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A=="
"version": "4.17.19",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz",
"integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ=="
},
"lodash.once": {
"version": "4.1.1",
@@ -1136,9 +1136,9 @@
}
},
"moment": {
"version": "2.26.0",
"resolved": "https://registry.npmjs.org/moment/-/moment-2.26.0.tgz",
"integrity": "sha512-oIixUO+OamkUkwjhAVE18rAMfRJNsNe/Stid/gwHSOfHrOtw9EhAY2AHvdKZ/k/MggcYELFCJz/Sn2pL8b8JMw=="
"version": "2.27.0",
"resolved": "https://registry.npmjs.org/moment/-/moment-2.27.0.tgz",
"integrity": "sha512-al0MUK7cpIcglMv3YF13qSgdAIqxHTO7brRtaz3DlSULbqfazqkc5kEjNrLDOM7fsjshoFIihnU8snrP7zUvhQ=="
},
"ms": {
"version": "2.1.2",
@@ -1317,9 +1317,9 @@
}
},
"rxjs": {
"version": "6.6.0",
"resolved": "https://registry.npmjs.org/rxjs/-/rxjs-6.6.0.tgz",
"integrity": "sha512-3HMA8z/Oz61DUHe+SdOiQyzIf4tOx5oQHmMir7IZEu6TMqCLHT4LRcmNaUS0NwOz8VLvmmBduMsoaUvMaIiqzg==",
"version": "6.6.2",
"resolved": "https://registry.npmjs.org/rxjs/-/rxjs-6.6.2.tgz",
"integrity": "sha512-BHdBMVoWC2sL26w//BCu3YzKT4s2jip/WhwsGEDmeKYBhKDZeYezVUnHatYB7L85v5xs0BAQmg6BEYJEKxBabg==",
"requires": {
"tslib": "1.13.0"
}
+1 -1
View File
@@ -17,7 +17,7 @@
},
"homepage": "https://octoprint.org",
"dependencies": {
"cypress": "^4.9.0",
"cypress": "^4.12.0",
"cypress-commands": "^1.1.0",
"cypress-file-upload": "^4.0.7",
"cypress-plugin-retries": "^1.5.2",