Commit graph

2668 commits

Author SHA1 Message Date
Gina Häußge
3da54be6ea Merge branch 'test/pollingObserver' into devel 2015-07-06 08:40:31 +02:00
Gina Häußge
b8cf5ef83d Added "pollWatched" setting to UI 2015-07-06 08:40:13 +02:00
Gina Häußge
6600d246b7 Better resilience against senseless polling intervals 2015-07-05 16:49:35 +02:00
Gina Häußge
8722cdadcd Merge branch 'maintenance' into devel
Conflicts:
	src/octoprint/plugins/softwareupdate/updaters/pip.py
	src/octoprint/util/pip.py
2015-07-05 10:15:14 +02:00
Gina Häußge
29d49179a9 SWU Fix: properly sanitize version strings for comparison 2015-07-05 10:04:06 +02:00
Gina Häußge
f2df1748ef Allow polling for changes in watched folder
Some underlying file systems might not trigger change events (e.g.
mounted remote file systems). Added a feature flag to allow for
switching to a (less performant) polling method.
2015-07-05 09:38:09 +02:00
Gina Häußge
19b4a0f403 Fix: Always delete files from watched folder
Wasn't ensure previously when using file preprocessors.
2015-07-05 09:35:49 +02:00
Gina Häußge
d854b41ffb Migrated access control docs from wiki 2015-07-05 00:09:13 +02:00
Gina Häußge
329a575031 Merge branch 'master' into maintenance 2015-07-04 23:51:58 +02:00
Gina Häußge
85ad85bdfa Also refer to wiki from docs until everything "official" is migrated 2015-07-04 23:51:29 +02:00
Gina Häußge
f0530eff8f SWU: always send displayName to frontend
Spares us having to map on the client side which might not work
in all cases.
2015-07-03 15:25:36 +02:00
Gina Häußge
a1735190d5 OctoPrint update script now logs asynchronously
stdout and stderr of executed commands was previously only logged at
the very end, now gets logged when it is received.
2015-07-03 14:00:01 +02:00
Gina Häußge
be8827b67c SWU: plugin now logs stdout/stderr during updating
Only if logged in as Admin though. Working dialog is as verbose as
Plugin install dialog.
2015-07-03 13:59:22 +02:00
Gina Häußge
ae73ebdcb3 PMGR: console_logger was not properly defined in init 2015-07-03 13:57:15 +02:00
Gina Häußge
6f24a2b6c5 New helper CommandlineCaller
Wraps sarge and allows asynchronous execution of commands incl. logging
to provided logging methods for stdout, stderr and command calls.

Refactored PipCaller to utilized that.
2015-07-03 13:56:31 +02:00
Gina Häußge
5674de9c2f Fix: Do not auto-close SWU plugin notifications 2015-07-03 13:53:59 +02:00
Gina Häußge
95c26a7850 Fix: Don't automatically persist or return _config_version
Should only ever be read or written by the plugin system itself, not
by on_settings_save or on_settings_load
(cherry picked from commit 77f7d59)
2015-07-02 15:27:35 +02:00
Gina Häußge
885e6f916c Fix: Don't persists checks when saving SWUpdate settings
(cherry picked from commit 8d10be6)
2015-07-02 15:27:27 +02:00
Gina Häußge
d7a86a4d28 Use UTF-8 for _all_ output from sarge
Lines taking from the asynchronous processing of stdout/stderr where
left as str, leading to encoding problems when utf8 characters showed
up in the stream and were being interpreted as ascii encoding.
(cherry picked from commit 9373be3)
2015-07-02 15:27:17 +02:00
Gina Häußge
7b3e0563cc SWUpdate: Only use version cache from same version of OP
When using the version cache only use the version cache if the OctoPrint
version stored within it matches the one of the currently running
instance. Otherwise we might report false positives with regards to
available updates under some circumstances.
(cherry picked from commit bb7b0cb)
2015-07-02 15:26:02 +02:00
Gina Häußge
77f7d59c53 Fix: Don't automatically persist or return _config_version
Should only ever be read or written by the plugin system itself, not
by on_settings_save or on_settings_load
2015-07-02 15:21:05 +02:00
Gina Häußge
8d10be6ac4 Fix: Don't persists checks when saving SWUpdate settings 2015-07-02 15:20:07 +02:00
Gina Häußge
1ab0a00700 Fix for deriving base version for old setuptools
Old versions of setuptools return a tuple for their
pkg_resources.parse_version method instead of a Version object with
a base_version attribute that we can use to retrieve the base version.

So some manually parsing is needed instead.
2015-07-02 10:48:46 +02:00
Gina Häußge
fe35086ad7 PMGR: Make sure we use OP's base version for compatibility
OctoPrint's version might be a prerelease version ("...dev<n>"), we
want that to still be able to pass plugin compatibility checks like the
final release version would, so always use the base version of
OctoPrint's current version for comparison during compatibility checks.
2015-07-01 10:20:09 +02:00
Gina Häußge
bb7b0cbcbd SWUpdate: Only use version cache from same version of OP
When using the version cache only use the version cache if the OctoPrint
version stored within it matches the one of the currently running
instance. Otherwise we might report false positives with regards to
available updates under some circumstances.
2015-07-01 09:19:51 +02:00
Gina Häußge
33bd1acd47 We want to use pep440-post as default version scheme 2015-07-01 08:59:37 +02:00
Gina Häußge
e2343024e9 Merge branch 'maintenance' into devel
Conflicts:
	.versioneer-lookup
2015-06-30 21:52:50 +02:00
Gina Häußge
50a62bf00a maintenance branch is now 1.2.3-dev 2015-06-30 21:49:37 +02:00
Gina Häußge
1c6b0554c7 Preparing release of 1.2.2 2015-06-30 21:19:50 +02:00
Gina Häußge
537c205757 Use lowercase when matching extensions
(cherry picked from commit 29cee16)
2015-06-30 19:12:58 +02:00
Gina Häußge
f07b2477f5 Fixed some comments that were outdated
(cherry picked from commit 18816b6)
2015-06-30 19:12:52 +02:00
Gina Häußge
5e5531f6d8 Verify extension of uploaded language packs & plugins
Should be valid zip archives/tarballs. Also use only the extension
of an uploaded plugin archive as suffix for the temporary file that's
used for installing it.
(cherry picked from commit a1ff698)
2015-06-30 19:12:45 +02:00
Gina Häußge
eadc9ee795 Fix: We don't need the shell for pip
(cherry picked from commit 2db3228)
2015-06-30 19:12:37 +02:00
Gina Häußge
29cee16d3e Use lowercase when matching extensions 2015-06-30 19:04:14 +02:00
Gina Häußge
18816b6ea8 Fixed some comments that were outdated 2015-06-30 19:00:56 +02:00
Gina Häußge
a1ff6986ca Verify extension of uploaded language packs & plugins
Should be valid zip archives/tarballs. Also use only the extension
of an uploaded plugin archive as suffix for the temporary file that's
used for installing it.
2015-06-30 18:59:45 +02:00
Gina Häußge
2db32289f3 Fix: We don't need the shell for pip 2015-06-30 18:52:23 +02:00
Gina Häußge
7cd0adb922 Refreshed versioneer again 2015-06-30 15:15:49 +02:00
Gina Häußge
44561dae15 Fixed some indentation 2015-06-30 15:04:22 +02:00
Gina Häußge
70eb490e02 Merge branch 'dev/versioneerUpdate' into devel
Conflicts:
	.versioneer-lookup
2015-06-30 15:03:04 +02:00
Gina Häußge
711810d18b Switched to new version of versioneer
Versions should now be PEP440 compatible.
2015-06-30 14:57:39 +02:00
Gina Häußge
e98dc59c94 Merge branch 'maintenance' into devel
Conflicts:
	CHANGELOG.md
2015-06-30 10:13:05 +02:00
Gina Häußge
0b3f94b6bd maintenance branch is now 1.2.2-dev 2015-06-30 10:12:14 +02:00
Gina Häußge
9f8d30a66c Preparing release of 1.2.1 2015-06-30 08:42:16 +02:00
Gina Häußge
2a8eea086c Only print command of event handler to log when debug flag is present
(cherry picked from commit 49d28c5)
2015-06-30 08:28:16 +02:00
Gina Häußge
49d28c58b3 Only print command of event handler to log when debug flag is present 2015-06-29 21:08:20 +02:00
Gina Häußge
bb0bfaee56 Fix: Increase max body size for plugin archives
Closes #957
(cherry picked from commit af89097)
2015-06-29 21:01:21 +02:00
Gina Häußge
af89097204 Fix: Increase max body size for plugin archives
Closes #957
2015-06-29 20:59:46 +02:00
Gina Häußge
b8209e8e09 Switch to pkg_resources for compatibility check
Plugin Manager now internally uses pkg_resources.parse_version and
pkg_resources.parse_requirements to check for version compatibility
with plugins from the repository. That will allow to directly use
the OctoPrint version string once it's PEP440 compatible.
(cherry picked from commit 8eb61a9)
2015-06-29 18:24:23 +02:00
Gina Häußge
8eb61a9926 Switch to pkg_resources for compatibility check
Plugin Manager now internally uses pkg_resources.parse_version and
pkg_resources.parse_requirements to check for version compatibility
with plugins from the repository. That will allow to directly use
the OctoPrint version string once it's PEP440 compatible.
2015-06-29 18:08:34 +02:00