Commit graph

1571 commits

Author SHA1 Message Date
Gina Häußge
e5217813bd Merge branch 'fix/sdcardTimelapseWarning' into devel
Conflicts:
	src/octoprint/server/views.py
	src/octoprint/templates/initscript.jinja2
2015-10-08 10:25:18 +02:00
Gina Häußge
bbbdb3dde6 Note that z-based timelapses don't work when printing from SD 2015-10-08 10:22:09 +02:00
Gina Häußge
b9460b4890 Merge branch 'fix/uiEscaping' into maintenance 2015-10-08 09:52:08 +02:00
Gina Häußge
db05632677 Updated compiled CSS file 2015-10-07 18:58:42 +02:00
Gina Häußge
b7973e4256 Merge branch 'fix/gcodeViewerUpdateOnFileUpdate' into devel 2015-10-07 18:54:21 +02:00
Gina Häußge
947f4c89cc Fixed a win-only issue causing the gcode view not to reload on file modification 2015-10-07 18:52:18 +02:00
Gina Häußge
5f982ec6c8 Merge branch 'fix/atomicWrites' into maintenance 2015-10-07 17:53:43 +02:00
Gina Häußge
4017f96ed5 Merge branch 'fix/contentTypeForDownloads' into devel 2015-10-07 17:22:21 +02:00
Gina Häußge
859ea0d0e4 Added mime type guessing for downloads to Tornado 2015-10-07 17:19:18 +02:00
Gina Häußge
236f87ca23 Merge remote-tracking branch 'origin/devel' into devel 2015-10-07 12:29:11 +02:00
Gina Häußge
b458759159 Merge branch 'fix/wrongEtagForDownloads' into devel 2015-10-07 12:25:52 +02:00
Gina Häußge
9cf21aa036 Also set caching headers for downloads to discourage client-side caching
At least if necessary (added new boolean flag to the constructor of
LargeResponseHandler for that). While at it also rename UrlForwardHandler
to UrlProxyHandler (it does not forward, it proxies) and make it aware of
ETag and Expires headers.
2015-10-07 12:25:25 +02:00
Mark Walker
3aa4c8f6c6 Add S255 parameter to M106 for "Fan On"
Bit of a debate with some gcode purists. RepRapPro demands an S
parameter.  Adding S255 should be backward compatible with the firmwares
that recognize M106 as full on. As with other issues, it'd be nice to
have something more to go on here than the reprap wiki and firmware
source code.
2015-10-06 14:07:08 -07:00
Gina Häußge
60ce959909 Merge branch 'fix/atomicWrites' into devel 2015-10-06 18:41:04 +02:00
Gina Häußge
78d8c18a82 Merge branch 'fix/wrongEtagForDownloads' into devel 2015-10-06 18:40:55 +02:00
Gina Häußge
637adc3095 Fix: LargeResponseHandler was wrongly caching ETag value
ETag values returned with download responses were cached internally within
the LargeResponseHandler class, with the file's path as key. That let to
problems once the content changed and hence the ETag value actually
becoming invalid. Since the path however stayed the same, the same ETag
value for the modified file was assumed and a 304 Not Modified response
was generated.

This patch changes the behaviour of LargeResponseHandler to use
the last modified date of the file as the ETag value and alternatively allowing
an etag generator function to be provided as constructor parameter as well
to use for calculating (or disabling) the ETag header dependant on the
situation.
2015-10-06 18:19:53 +02:00
Gina Häußge
548f976d35 Some more defensive escaping for various settings in the UI
Entering HTML fragments into the webcam stream URL could cause
issues, anything injected via Jinja should now be escaped properly.
2015-10-06 13:41:54 +02:00
Gina Häußge
a6c21c4985 Merge branch 'fix/utf8BomResilience' into devel
Conflicts:
	src/octoprint/static/js/app/dataupdater.js
	src/octoprint/util/comm.py
2015-10-05 19:58:01 +02:00
Gina Häußge
45c92cb1f4 Fix: Open GCODE files als utf-8, replacing encoding errors
Also detect files that contain a BOM and strip it.
Internal handling of GCODE file contents switched to unicode.

 Should take care of #1077
2015-10-05 19:43:40 +02:00
Gina Häußge
f83d5aa89f Fix: Use atomic writes for all save processes
That includes uploaded files, profiles, caching files, settings and user
directories.
2015-10-05 18:07:43 +02:00
Nicanor Romero Venier
c050f6a467 Merge branch 'dev/dynamicMaxTemp' into devel 2015-10-05 16:04:08 +02:00
Salandora
2530e9b710 Fixed merge and moved some functions into library 2015-10-04 02:42:18 +02:00
Salandora
59cb448913 Merge remote-tracking branch 'remotes/upstream/devel' into dev/folderSupport
Conflicts:
	src/octoprint/static/js/app/viewmodels/files.js
2015-10-03 12:33:11 +02:00
Gina Häußge
abf073340f Fixed reporting of duration needed for capturing timelapse postroll
Needs to be calculated differently for time based and z-triggered. Capture interval
was not taken properly into account.
(cherry picked from commit 9284ff4)
2015-10-02 18:22:44 +02:00
Gina Häußge
918ffa2557 Refactored timelapse core
Capturing is now queue based, rendering will not start until all images have been captured,
and timed postroll does not depend on system time anymore.

Also refactored some of the names to be python naming compliant while at it.
(cherry picked from commit 4f5dc70)
2015-10-02 18:18:31 +02:00
Gina Häußge
9284ff4086 Fixed reporting of duration needed for capturing timelapse postroll
Needs to be calculated differently for time based and z-triggered. Capture interval
was not taken properly into account.
2015-10-02 15:14:05 +02:00
Gina Häußge
5644b5dc01 clientlib: Fixed some refactoring errors still referring to exports var
Closes #1079
2015-10-02 14:26:51 +02:00
Gina Häußge
a28198edef Timelapse API couldn't yet cope with JSON requests 2015-10-02 13:16:58 +02:00
Gina Häußge
874ebde069 Fix: make a deep copy of temp profiles and terminal filters
Otherwise changes to the observable will write into the last received values,
making the changes undetectable.
2015-10-02 10:18:30 +02:00
Salandora
ac6cfbc0ea Stopped GCodeViewer from rendering if GCode Viewer tab is not active
Anything else is normally processed
(cherry picked from commit 426e9f3)
2015-10-01 17:31:46 +02:00
Gina Häußge
6a11f4a4d8 Fixed API key reset after reconnect 2015-10-01 16:03:16 +02:00
Gina Häußge
085ab77c57 Added system API to client lib and migrated users to it 2015-10-01 14:57:41 +02:00
Gina Häußge
8875f257ea Merge branch 'devel' into dev/clientlib
Conflicts:
	src/octoprint/server/api/__init__.py
	src/octoprint/static/js/app/viewmodels/navigation.js
2015-10-01 14:22:15 +02:00
Gina Häußge
1837c74e8e PMGR: Show restart button on notification if restart command is configured
This will directly offer a "Restart Now" button on the "a restart is required" notification
for plugins which cannot be directly enabled/disabled without a restart, but only if
the restart command is configured on the server.

On click a confirmation dialog will be shown.
2015-10-01 14:20:37 +02:00
Gina Häußge
950b1c2355 Only show divider between core & custom commands if there are core commands 2015-10-01 14:19:00 +02:00
Gina Häußge
97e8326768 Only try to rewrite PNotify confirm buttons if buttons are actually configured 2015-10-01 14:16:24 +02:00
Gina Häußge
6ab44849cd Extracted system commands into their own proper API & ViewModel 2015-10-01 14:05:23 +02:00
Gina Häußge
31bc7c1f3e Helper method for creating notifications with only one confirm button
PNotify always merges the default buttons and the ones provided. Just settings the default
to containing no buttons was no option since plugins might already depend on the so far
obligatory Cancel button being present. The helper allows to create one buttoned
notifications without touching the defaults.
2015-10-01 10:08:24 +02:00
Salandora
579c8f6748 Merge remote-tracking branch 'upstream/devel' into dev/folderSupport 2015-10-01 01:56:37 +02:00
Gina Häußge
be79cf289e Merge branch 'maintenance' into devel 2015-09-30 16:00:56 +02:00
Gina Häußge
5cc8ec5cc3 Better wording for plugin system startup & sorted plugin list of ALL plugins 2015-09-30 16:00:32 +02:00
Gina Häußge
982f24fe31 PMGR: Better wording of "pip unavailable" message 2015-09-30 15:59:08 +02:00
Gina Häußge
0a1816e52f Better error reporting in PipUtil for errors during pip setup detection 2015-09-30 15:58:38 +02:00
Gina Häußge
b432496b7f Merge branch 'devel' into dev/clientlib 2015-09-30 14:40:46 +02:00
Gina Häußge
2926b5c8d5 PMGR: only mark as pending (un)installed if restart is needed 2015-09-30 14:30:10 +02:00
Gina Häußge
fdcc6ac367 PMGR: Only add --user flag if not running in a virtual env 2015-09-30 14:25:06 +02:00
Gina Häußge
2eb80c550f PMGR: Disable plugin remove button if plugin is not managable 2015-09-30 13:44:58 +02:00
Gina Häußge
ca587454df PMGR: Fixed marking of plugins
Plugins can now (again) show if they are pending installation,
uninstallation and also if they are managable at all.
2015-09-30 13:37:27 +02:00
Gina Häußge
e64975c85c PMGR: Debug output in frontend to indicate venv 2015-09-30 13:36:45 +02:00
Gina Häußge
4a97864e01 PMGR: Added option to force use of --user flag 2015-09-30 13:36:00 +02:00
Gina Häußge
28fc7d74f4 Made plugin marking in PluginManager more flexible
Now supports arbitrary markers for plugins. Also added a method
to check if a plugin was marked with a specified marker.
2015-09-30 13:33:25 +02:00
Gina Häußge
fbfac4b569 PluginManager also scans user site packages
In case the user site packages are not yet part of the used
working set OR the sys path and ENABLE_USER_SITE is true, the
manager will now make sure that the folder is searched for plugins
as well upon plugin reload.

This is necessary since Python will not automatically include the
user site directory upon firing up the program in case there's
nothing installed to it/it doesn't exist. If a plugin is installed
during run time with --user that will lead to it not being found,
which is undesirable. Hence run time manipulation of sys.path and
the workingset becomes necessary.
2015-09-30 13:30:39 +02:00
Gina Häußge
10db8c9577 PluginManager now marks plugins as managable
Managable currently pretty much only means "uninstallable".

Plugins are managable if their installation location is writable
and - if they are installed from an entry point and OctoPrint is
running in a virtual environment - within the bounds of the virtual
environment (because otherwise pip will not allow to uninstall).
2015-09-30 13:28:58 +02:00
Gina Häußge
7c5fe46f4a More intelligence for PipUtil to determine when to use --user
Includes a force_user (and a force_sudo) parameter.
2015-09-30 13:27:24 +02:00
Salandora
38a0f383ae Merge remote-tracking branch 'upstream/devel' into dev/folderSupport
Conflicts:
	src/octoprint/static/js/app/viewmodels/files.js
2015-09-30 11:10:59 +02:00
Salandora
6eeb3546c0 Further implemented the move and copy commands 2015-09-30 10:56:52 +02:00
Nicanor Romero Venier
4a7c81d1c6 Added offset to max Y in temperature chart 2015-09-30 09:20:40 +02:00
Nicanor Romero Venier
2674741797 Change the max temp of chart dynamically 2015-09-29 19:08:22 +02:00
Gina Häußge
6ed96764e1 Merge branch 'devel' into dev/pipUserParameter 2015-09-29 16:41:11 +02:00
Gina Häußge
79b8639135 Fix: Use adjusted pip arguments in execute method 2015-09-29 16:38:26 +02:00
Gina Häußge
62478fd98f More pip data in plugin manager front end 2015-09-29 14:51:58 +02:00
Gina Häußge
cae73c1ee5 Cache for pip setup and version information
Can take a bit of time to collect that data since it needs some invocations of
pip, so we cache that data unless told otherwise.
2015-09-29 14:22:29 +02:00
Gina Häußge
5df576b73e Install testballoon using pip install . in testballoon folder 2015-09-29 13:53:48 +02:00
Gina Häußge
000f8e9310 Debug logging for testballoon install 2015-09-29 13:47:35 +02:00
Gina Häußge
7d38d66489 PipUtil now uses --user argument with pip install if detected as necessary 2015-09-29 13:39:08 +02:00
Gina Häußge
705f0706fd Merge branch 'fix/pmgrPipWithSudo' into devel
Conflicts:
	src/octoprint/util/pip.py
2015-09-28 20:21:40 +02:00
Gina Häußge
fce7b40b51 pip: Use string representation of version for display in UI 2015-09-28 20:20:56 +02:00
Gina Häußge
697affc62d Merge branch 'fix/pmgrPipWithSudo' into devel
Conflicts:
	src/octoprint/plugins/pluginmanager/__init__.py
	src/octoprint/util/pip.py
2015-09-28 19:57:05 +02:00
Gina Häußge
1178fe9e95 Support sudo for installing plugins, but warn about it 2015-09-28 19:53:30 +02:00
Gina Häußge
bdc5d72613 Fixes OctoPrint.files.download method 2015-09-28 18:41:40 +02:00
Gina Häußge
e57ed92294 Less repetitious code 2015-09-28 18:24:56 +02:00
Gina Häußge
73c235d67f Migrate SettingsViewModel.requestData to using promises
Fallback implementation for old callback parameter is still present,
logs warning about deprecation.
2015-09-28 18:17:43 +02:00
Gina Häußge
7a06f496de Let's get rid of another callback 2015-09-28 17:08:40 +02:00
Gina Häußge
7b7f21d126 Migrate to new utility methods for testing URLs & executable paths 2015-09-28 17:08:25 +02:00
Gina Häußge
c5f0ccdb94 Migrated client to module factory pattern
This should _hopefully_ also make it compatible to AMD implementations,
but I have to admit that I haven't tried that yet...
2015-09-28 17:07:37 +02:00
Gina Häußge
1a469e1c97 Take login data from data, not request.values
That was a left-over from the previous implementation...
2015-09-28 17:06:08 +02:00
Gina Häußge
6bc8bca99c Merge branch 'devel' into dev/clientlib 2015-09-28 13:09:58 +02:00
Gina Häußge
f3e242d3a0 Merge remote-tracking branch 'origin/devel' into devel 2015-09-28 13:02:38 +02:00
Gina Häußge
0b4e590a5b Refactored drop zone processing in GcodeFilesViewModel 2015-09-28 13:01:47 +02:00
Gina Häußge
96d479bd67 Merge branch 'fix/noDropFileuploads' into devel 2015-09-28 12:55:54 +02:00
Gina Häußge
1b4ea75466 Fix: Don't have file upload widgets listen to drop events by default
That way they won't be triggered by gcode uploads when all they are interested in
are uploads via a single file input.
2015-09-28 12:55:32 +02:00
Gina Häußge
eafca5d77a Some bug fixing of client migration 2015-09-25 17:09:07 +02:00
Gina Häußge
e5f12ae4c0 Merge branch 'devel' into dev/clientlib 2015-09-25 13:53:51 +02:00
Gina Häußge
bbd728c51b Migrated existing javascript application files to use client lib
TODO: Testing & Debugging
2015-09-25 13:53:42 +02:00
Gina Häußge
1678951d84 Client library should now cover all APIs
TODO: Testing & Debugging
2015-09-25 13:52:31 +02:00
Mark Walker
2411b4260e Update css for change 42d754 to the less 2015-09-23 11:51:36 -07:00
Gina Häußge
055a5d06f6 Fix: Correctly persist all changes to gcode scripts 2015-09-23 13:40:41 +02:00
Gina Häußge
5f8c3d967c Added files and connection API and socket library 2015-09-22 18:33:27 +02:00
Gina Häußge
0a30438040 Merge branch 'fix/contentTypeHeaderCheck' into devel 2015-09-22 15:43:57 +02:00
Gina Häußge
b4b5689bc4 Fix: Correctly handle unset Content-Type header for command requests 2015-09-22 15:23:50 +02:00
Gina Häußge
b38b38e359 Merge branch 'fix/pmgrPipConfig' into devel 2015-09-22 11:39:55 +02:00
Gina Häußge
fd4271a962 PipCaller: Added back missing member variable 2015-09-22 11:39:45 +02:00
Gina Häußge
2a4ee5072c Merge branch 'fix/pmgrPipConfig' into devel
Conflicts:
	src/octoprint/plugins/pluginmanager/__init__.py
	src/octoprint/util/pip.py
2015-09-22 11:39:02 +02:00
Gina Häußge
65bc28a03e PMGR: Added configuration dialog and info re used pip binary & version 2015-09-22 11:36:57 +02:00
Gina Häußge
c26515c13d PipCaller: Allow update of used pip command 2015-09-22 11:35:47 +02:00
Gina Häußge
25a4d4b79b SWU: Track check origins, ignore if from unavailable plugin
There was a problem with software update checks configurations stored in
config.yaml for which the providing plugin was then removed, since those
check definitions then lacked their default values to be merged on whatever
was stored in config.yaml, causing incomplete check configurations as a
consequence over which the plugin tripped.

This patch fixes that in that it tracks which check config keys are provided
by plugins and only returns those as the active check configurations that
belong to plugins that are still in the system.

TODO: This is only half of the solution. Check configurations of plugins
that are being uninstalled should be removed from the config if the
user decides to remove any settings by the plugin too. We need some
adjustments in the lifecycle tracking in order to make this possible
however, so for now this must suffice to at least prevent any errors from
occuring when incomplete configs are encountered.
(cherry picked from commit 8af8b8f)
2015-09-21 16:46:44 +02:00
Gina Häußge
43ca4d8252 SWU: Do not overwrite check information again
Current version information of OctoPrint from a check definition
could be overwritten for checks under certain circumstances.
2015-09-21 16:42:11 +02:00
Salandora
3e3a0b905f Merge branch 'devel' into dev/folderSupport 2015-09-21 14:58:38 +02:00
Gina Häußge
d2e2cb814f M400 and proper M114 in virtual printer 2015-09-21 08:41:28 +02:00
Marcel Hellwig
e46e7b3ee2 changed magic line from python->python2
Since python is sometimes (and for me on arch linux) a symlink to the
python3 utils, you should be more explicit with that.
2015-09-17 18:04:14 +02:00
Bryan Mayland
0253f525b0 Include a time estimate for gcode which uses firmware retract, if retract settings are seen in gcode 2015-09-12 11:32:52 -04:00
Gina Häußge
8232126684 WIP 2015-09-12 11:21:42 +02:00
Gina Häußge
8af8b8f79a SWU: Track check origins, ignore if from unavailable plugin
There was a problem with software update checks configurations stored in
config.yaml for which the providing plugin was then removed, since those
check definitions then lacked their default values to be merged on whatever
was stored in config.yaml, causing incomplete check configurations as a
consequence over which the plugin tripped.

This patch fixes that in that it tracks which check config keys are provided
by plugins and only returns those as the active check configurations that
belong to plugins that are still in the system.

TODO: This is only half of the solution. Check configurations of plugins
that are being uninstalled should be removed from the config if the
user decides to remove any settings by the plugin too. We need some
adjustments in the lifecycle tracking in order to make this possible
however, so for now this must suffice to at least prevent any errors from
occuring when incomplete configs are encountered.
2015-09-12 11:09:28 +02:00
Gina Häußge
2c0eed266c Fixed some wrong indentation that somehow made it through editorconfig 2015-09-11 11:48:38 +02:00
Gina Häußge
e4ae150457 Merge remote-tracking branch 'origin/devel' into devel 2015-09-11 11:31:35 +02:00
Marcel Hellwig
b6053c14f9 add errorhandler decorator to blueprintplugin
This will allow you to add an errorhandler for your blueprint easily.
2015-09-11 11:20:41 +02:00
Gina Häußge
b56ba6589c Ignore update definitions that are lacking the type
Caused a KeyError so far, update definitions that are broken like that
will now just be ignored instead.

Closes #1057
(cherry picked from commit 2efc5c4)
2015-09-11 08:36:02 +02:00
Gina Häußge
5c9b507cb7 User user id, not user name, for all user operations
(cherry picked from commit 7021b9f)
2015-09-11 08:35:08 +02:00
Gina Häußge
7021b9fe89 User user id, not user name, for all user operations 2015-09-11 08:34:05 +02:00
Gina Häußge
cd7ac032f4 Fixed an issue that cause user sessions to not be properly associated
Sessions could get duplicated, wrongly saved etc. The reason was not
persisting the actual user object to the internal session map (but the
LocalProxy instead). That could lead to multiple sessions being
created for one login, or the session user being set to an
anonymous user, or various other odd effects depending on timing.
(cherry picked from commit 8aeac51)
2015-09-11 08:20:16 +02:00
Gina Häußge
2efc5c4fdb Ignore update definitions that are lacking the type
Caused a KeyError so far, update definitions that are broken like that
will now just be ignored instead.

Closes #1057
2015-09-11 08:15:15 +02:00
Gina Häußge
f0ab517857 Merge branch 'dev/uiPlugin' into devel 2015-09-10 16:25:34 +02:00
Gina Häußge
19c8b8e905 Documented UiPlugin type and enhanced existing docs 2015-09-10 15:43:30 +02:00
Gina Häußge
93da761918 Divided Core UI specific render_kwargs and general kwargs
Also refactored version kwarg into dictionary with all three version
information pieces.
2015-09-10 15:43:08 +02:00
Gina Häußge
ff956ca4c4 Merge remote-tracking branch 'origin/devel' into devel 2015-09-09 16:13:59 +02:00
Gina Häußge
8aeac51124 Fixed an issue that cause user sessions to not be properly associated
Sessions could get duplicated, wrongly saved etc. The reason was not
persisting the actual user object to the internal session map (but the
LocalProxy instead). That could lead to multiple sessions being
created for one login, or the session user being set to an
anonymous user, or various other odd effects depending on timing.
2015-09-09 16:13:10 +02:00
Mark Bastiaans
b7c9949caf Fixed checks with os.path.realpath() for systems with symlinked paths 2015-09-08 11:35:53 +02:00
Mark Walker
42d7654009 Fix issue #1047 rotate 90 degrees on iOS Safari
The iOS version of webkit still requires the browser prefixes for
transform, see http://stackoverflow.com/a/27304061/4414220
2015-09-07 11:51:54 -07:00
Gina Häußge
d5b0bd2518 Merge branch 'dev/hook_recieved_line' into devel 2015-09-07 15:42:56 +02:00
Gina Häußge
c1880a7006 New UiPlugin for serving custom UIs on / depending on request 2015-09-07 13:57:10 +02:00
Gina Häußge
38dabfc1c0 Only try to convert sorting_value to int if it's not None 2015-09-07 11:34:09 +02:00
Salandora
2d5bfca9fd Started work on move and rename commands in API and FileManager/StorageInterface 2015-09-07 10:59:46 +02:00
Salandora
5f3ee7dfda Changes to the WebUI to support folders 2015-09-07 10:59:43 +02:00
Salandora
fb2b44f3c1 Changes to the API to enchance folder support 2015-09-07 10:59:40 +02:00
Nicanor Romero Venier
fa95507177 Included an early return if ret is None
Also corrected typos, received instead of recieved.
2015-09-07 10:04:06 +02:00
Gina Häußge
b326b6bd33 Merge branch 'dev/tabCycleLogin' into devel 2015-09-07 09:35:35 +02:00
Gina Häußge
9f49e39333 We do that tab cycling slightly differently
Moving from the button to the username field probably makes even more
sense and while we are at it we can also extract the element access into
proper variables.
2015-09-07 09:35:28 +02:00
Gina Häußge
8abf152d40 SorteablePlugin => SortablePlugin 2015-09-04 16:42:49 +02:00
Gina Häußge
e4dd4483d4 Sanity checking of the order data returned by plugins 2015-09-04 16:08:57 +02:00
Gina Häußge
89ccfae919 Fixed get_filtered_implementation again
Apparently, *args and named but optional arguments in combination are
more tricky to get right than they first appear.
2015-09-04 15:54:48 +02:00
Gina Häußge
5863f99b75 Always sort plugins by their identifier by default 2015-09-04 15:38:15 +02:00
Gina Häußge
2a52b6d1a2 Allow sorting of Startup and ShutdownPlugins 2015-09-04 15:01:35 +02:00
Gina Häußge
44c76fa70b Made hooks and templates sortable 2015-09-04 11:25:27 +02:00
Nicanor Romero Venier
c2c5d96f8f Modified tab cycle in Login dialog
The cycle now includes the 'remember' checkbox.
2015-09-04 10:05:20 +02:00
Gina Häußge
aa6998ec5e Merge branch 'dev/increase_temp_polling' into devel 2015-09-03 19:01:16 +02:00
Gina Häußge
f6acca5db2 Set default value for temperature polling when target is set to 2s
1s might be a bit fast as a default for certain boards, so better leave it at
something less spammy.
2015-09-03 18:57:11 +02:00
Gina Häußge
24f769ff80 Moved both temperature intervals into the same "section" 2015-09-03 17:46:03 +02:00
Gina Häußge
f2c07e8f96 First throw at an "About" dialog 2015-09-03 17:08:15 +02:00
Nicanor Romero Venier
d1612e426a Added hook for recieved lines 2015-09-03 17:07:33 +02:00
Nicanor Romero Venier
1e93638794 Changed UI layout for the temperature interval 2015-09-03 15:52:43 +02:00
Nicanor Romero Venier
558465fdcd Added a new timeout for polling when a target temperature is set 2015-09-03 15:23:44 +02:00
Gina Häußge
50bff32cd5 Merge branch 'devel' of https://github.com/Mikk36/OctoPrint into pr/Mikk36/devel 2015-09-02 15:09:36 +02:00
Mikk Kiilaspää
2692044c13 Associate Z-lift moves with the layer they were made on 2015-09-02 15:50:36 +03:00
Mikk Kiilaspää
783fbd9c1e Fix formatting 2015-09-02 15:49:02 +03:00
Gina Häußge
628a9f43e9 Let's up the restart-detection-timeout a bit
Just for experimental purposes.
2015-09-02 11:34:32 +02:00
Gina Häußge
b52422db2e Simplifier comm _monitor thread a bit
Should now also trigger comm timeouts when not printing
2015-09-02 09:36:34 +02:00
Gina Häußge
a79e38a350 Settings saving now supports callbacks, SWU plugin utilizes those 2015-09-01 17:18:08 +02:00
Gina Häußge
8294082652 Fix: properly save terminal filters 2015-09-01 16:26:57 +02:00
Gina Häußge
098c169ca5 SWU: Do not show "settings refreshed" dialog when saving plugin settings 2015-09-01 10:43:52 +02:00
Gina Häußge
42e11acb44 Fixed a merge error 2015-09-01 09:42:44 +02:00
Gina Häußge
4f3e2d7f49 Merge branch 'maintenance' into devel
Conflicts:
	.versioneer-lookup
	CHANGELOG.md
	src/octoprint/plugins/softwareupdate/__init__.py
	src/octoprint/plugins/softwareupdate/static/js/softwareupdate.js
	src/octoprint/plugins/softwareupdate/updaters/pip.py
	src/octoprint/plugins/softwareupdate/updaters/update_script.py
	src/octoprint/plugins/virtual_printer/virtual.py
	src/octoprint/server/util/sockjs.py
	src/octoprint/server/views.py
	src/octoprint/static/css/octoprint.css
	src/octoprint/static/js/app/helpers.js
	src/octoprint/static/js/app/viewmodels/settings.js
	src/octoprint/templates/dialogs/settings.jinja2
	src/octoprint/templates/dialogs/settings/features.jinja2
	src/octoprint/templates/dialogs/settings/server.jinja2
	src/octoprint/translations/de/LC_MESSAGES/messages.mo
	src/octoprint/translations/de/LC_MESSAGES/messages.po
	src/octoprint/util/comm.py
	translations/de/LC_MESSAGES/messages.mo
	translations/de/LC_MESSAGES/messages.po
	translations/messages.pot
2015-09-01 08:34:24 +02:00
Gina Häußge
96fc70bdb2 Preparing release of 1.2.5 2015-08-31 10:28:52 +02:00
Gina Häußge
8ed0befd62 Fixed bug that made browser crash when trying to log in
Trying to serialize view models or browser events as username/password probably was not the best of ideas ;)
(cherry picked from commit c7fd480)
2015-08-31 09:44:52 +02:00
Salandora
7d50563666 Custom Control fix in less file
(cherry picked from commit 10ad8dd)
2015-08-31 09:26:20 +02:00
Gina Häußge
8fddd8dd87 Updated CSS 2015-08-31 09:19:39 +02:00
Salandora
10ad8dd953 Custom Control fix in less file 2015-08-31 08:54:03 +02:00
Gina Häußge
9b9ecfe9be Two new callbacks for RepeatedTimer when cancelled or condition untrue 2015-08-28 16:53:22 +02:00
Salandora
4011f60ff9 Edge Fix
Thanks @foosel for the Informations

Conflicts:
	src/octoprint/server/views.py
2015-08-28 09:36:47 +02:00
Gina Häußge
37950cb466 Fixing some more merge errors 2015-08-28 08:58:12 +02:00
Gina Häußge
5df088cfee Merge pull request #1035 from Salandora/edgeFix
Edge Fix
2015-08-28 08:57:38 +02:00
Gina Häußge
2824b967ff Fixed a merge error 2015-08-28 08:20:20 +02:00
Gina Häußge
7b8bf2cf5c M112 support or the virtual printer
(cherry picked from commit 22a6604)
2015-08-28 08:19:03 +02:00
Gina Häußge
9299cb54a4 Improved M112 handling
Use new synchronized sending method and also make sure that heaters
will get disabled in case M112 is NOT understood by the firmware
before disconnecting. That's about all we can do for now.
(cherry picked from commit 5406b2b)
2015-08-28 08:12:12 +02:00
Gina Häußge
b965d4cbde comm: Synchronized write access to line number
New method wraps line sending and incrementing
(cherry picked from commit f8e72c9)
2015-08-28 08:11:56 +02:00
Mark Walker
7d922f3c77 Clean up the comment
(cherry picked from commit f519070)
2015-08-28 08:09:16 +02:00
Mark Walker
7e894d2ac2 ClearableQueue redundant with self.close
Closing the printer connection and then reopening (when the users clicks
connect) will create a new fresh MachineCom object so the queues will
start out empty.  Plus ClearableQueue was even more tied to the Queue
implementation that the current _get/_put overrides.
(cherry picked from commit e7584cd)
2015-08-28 08:09:02 +02:00
Mark Walker
948e20b269 Send M112 to printer immediately
Address #1031 with an immediate send of M112 followed by closing the
serial connection to reset the host state
(cherry picked from commit 3d1d745)
2015-08-28 08:08:26 +02:00
Salandora
5c257758ad Edge Fix
Thanks @foosel for the Informations
2015-08-28 06:31:25 +02:00
Gina Häußge
0e863ad776 Made diskspace running low a bit more obvious
* Added "total" space to "free" in file list
  * Added configurable space thresholds. If free space is below "warning"
    threshold, exclamation sign will be added to report. If free space is below
    "critical" threshold, report will be styled bold and red.
(cherry picked from commit 097800a)
2015-08-27 17:14:10 +02:00
Gina Häußge
a42b65eca0 Merge branch 'devel' into test/immediateM112 2015-08-27 16:44:09 +02:00
Gina Häußge
51b1535a29 Make sure stdout is a string when we try to treat it as such... 2015-08-27 16:43:58 +02:00
Gina Häußge
5406b2bab1 Improved M112 handling
Use new synchronized sending method and also make sure that heaters
will get disabled in case M112 is NOT understood by the firmware
before disconnecting. That's about all we can do for now.
2015-08-27 16:27:26 +02:00
Gina Häußge
f8e72c9233 comm: Synchronized write access to line number
New method wraps line sending and incrementing
2015-08-27 16:26:51 +02:00
Gina Häußge
22a660404b M112 support or the virtual printer 2015-08-27 16:22:38 +02:00
Gina Häußge
f1a812a2c4 Merge branch 'dev/disableChecksums' into devel 2015-08-27 13:12:14 +02:00
Gina Häußge
a7f5e07271 Merge branch 'devel' into test/immediateM112 2015-08-27 11:00:06 +02:00
Gina Häußge
097800ae9c Made diskspace running low a bit more obvious
* Added "total" space to "free" in file list
  * Added configurable space thresholds. If free space is below "warning"
    threshold, exclamation sign will be added to report. If free space is below
    "critical" threshold, report will be styled bold and red.
2015-08-27 10:29:11 +02:00
Nicanor Romero Venier
6d3b1b7f13 Added possibility of never sending checksums
Within the settings/features there is now a block of radio buttons
where the user can select whether to send checksums only when printing,
always or never.

In order to maintain backward compatibility in the settings, this is stored
in two variables, alwaysSendChecksum and neverSendChecksum. If both are False,
it is assumed that checksums are sent only when printing, being this the default value.
2015-08-26 17:55:34 +02:00
Gina Häußge
13d7d5f2f6 SWU: Various improvements for better usability
* Allow configuration of checkout folder and version tracking type
    via Plugin Configuration
  * Display message to use if checkout folder is not configured or a
    non-release version is running and version tracking against releases
    is enabled
  * Clear version cache when a change in the check configuration is
    detected
  * Mark check configurations for which an update is not possible with
    a little exclamation mark
(cherry picked from commit 8666a28)
2015-08-26 16:03:11 +02:00
Gina Häußge
ac8faf7910 Also provide branch info to UI/on socket
(cherry picked from commit cc8dcef)
2015-08-26 16:02:29 +02:00
Gina Häußge
bf049ddee4 Fixed two swapped vars
(cherry picked from commit 14c1069)
2015-08-26 15:56:50 +02:00
Gina Häußge
2c50237699 Reordered and tooltipped new server commands
(cherry picked from commit e2e6318)
2015-08-26 15:56:24 +02:00
Gina Häußge
93763a5563 Remove left over observables that are no longer needed
(cherry picked from commit 7986a2f)
2015-08-26 15:56:09 +02:00
Gina Häußge
7a74f5348d Only migrate server commands when not already set
Also migrate for any config version < 4 (incl. None) and make sure
the other migrations may happen on top of that if necessary. Added
some comments to explain necessary migrations.
(cherry picked from commit f1075f6)
2015-08-26 15:55:32 +02:00
Gina Häußge
b25c2220d1 Allow deletion of a key from settings that is no longer in defaults
(cherry picked from commit b04da70)
2015-08-26 15:55:14 +02:00
Nicanor Romero Venier
57161dd9c3 Added migration step for new settings.
(cherry picked from commit 1cdd61f)
2015-08-26 15:54:17 +02:00
Nicanor Romero Venier
1343a4a253 Added settings to specify server commands.
Added commands for system shutdown and restart and
for server restart.
(cherry picked from commit dab3285)
2015-08-26 15:53:30 +02:00
Gina Häußge
8666a28f64 SWU: Various improvements for better usability
* Allow configuration of checkout folder and version tracking type
    via Plugin Configuration
  * Display message to use if checkout folder is not configured or a
    non-release version is running and version tracking against releases
    is enabled
  * Clear version cache when a change in the check configuration is
    detected
  * Mark check configurations for which an update is not possible with
    a little exclamation mark
2015-08-26 15:50:57 +02:00
Gina Häußge
cc8dcef8a1 Also provide branch info to UI/on socket 2015-08-26 15:25:16 +02:00
Gina Häußge
c7fd4809fd Fixed bug that made browser crash when trying to log in
Trying to serialize view models or browser events as username/password probably was not the best of ideas ;)
2015-08-24 16:57:08 +02:00
Gina Häußge
6de7eabca2 Fixed another merge error 2015-08-24 15:59:49 +02:00
Gina Häußge
2247f30c87 Fixed indentation after a merge error 2015-08-24 15:30:26 +02:00
Gina Häußge
ba6a6723a6 Settings dialog for new resend setting
(cherry picked from commit 4525a3a)
2015-08-24 14:59:51 +02:00
Gina Häußge
f9a0cb94f7 Moved new resend setting into feature section
That's where all other protocol specific settings are currently located.
Will be migrated at a later date into the printer profile instead (that
makes way more sense).
(cherry picked from commit d0f61e5)
2015-08-24 14:59:44 +02:00
Gina Häußge
e689a2c733 Handle Repetier resend repetitions
Repetier might resend the same resend request to make sure it arrives.
This commit makes OctoPrint not react to such a repeated request and
instead ignore up to a configurable amount of repeated requests for
the same (current) line.
(cherry picked from commit 6f83695)
2015-08-24 14:59:11 +02:00
Gina Häußge
d07c81f312 Fixed regex groups for GCODE parameters
(cherry picked from commit 168d32e)
2015-08-24 14:56:40 +02:00
Gina Häußge
32f4f8d95b Added warning to UI regarding Z timelapses and spiralized objects
(cherry picked from commit d956773)
2015-08-24 14:56:18 +02:00
Gina Häußge
7f2e0161a8 atomic_write context to save configs first to temp file, then move
Should prevent corruption of files
(cherry picked from commit c6d0290)
2015-08-24 14:56:12 +02:00
Gina Häußge
59993bfca4 Fixed & refactored temperature parsing
T-only lines were not properly parsed. Should now be fixed to
be associated to currently selected extruder. Also added unit
tests for the temperature parsing.

While at it also extracted regexes and added unit tests for command
parsing (gcode & parameters)
(cherry picked from commit f6a259f)
2015-08-24 14:55:42 +02:00
Salandora
0782dda20f Add Repetier's Format Error to exception whitelist
(cherry picked from commit d037379)
2015-08-24 14:54:28 +02:00
Gina Häußge
8c1a79558b Always include timelapse view model in bundled js files
Even if the webcam URLs and the FFMPEG path is not yet configured. Otherwise
setting those URLs and the path will require a restart of OctoPrint to enable properly -
that's overkill.
(cherry picked from commit 1425b20)
2015-08-24 14:52:50 +02:00
Mark Walker
0705a7054c Hint about why timelapse configuration is disabled
while printing.

Fixes #1028
(cherry picked from commit 8496827)
2015-08-24 14:51:55 +02:00
Gina Häußge
54bd7766b9 SWU: Don't use display versions for "current" in github_commit configs
(cherry picked from commit 58c6abc)
2015-08-24 14:51:25 +02:00
Gina Häußge
ed215fc5fa FileMgr: Only remove callback if it exists.
(cherry picked from commit 4a49948)
2015-08-24 14:45:14 +02:00
Gina Häußge
5f53b704dd Use connection closing flag only for exception handling
Otherwise we kill the beforePrinterDisconnected gcode script...

See #1021
(cherry picked from commit 2fe956e)
2015-08-24 14:44:56 +02:00
Gina Häußge
e8ef0ba8a4 Properly handle serial close on Macs
Readline could still be stuck in a read loop, leading to an exception on Mac
when closing the connection from another thread. This should now be captured
correctly.

Fixes #1021
(cherry picked from commit c829b27)
2015-08-24 14:44:31 +02:00
Salandora
49f62bc655 Fix positioning of ContextMenu
(cherry picked from commit 2bf5624)
2015-08-24 14:40:52 +02:00
Gina Häußge
4525a3a805 Settings dialog for new resend setting 2015-08-24 14:30:32 +02:00
Gina Häußge
d0f61e5073 Moved new resend setting into feature section
That's where all other protocol specific settings are currently located.
Will be migrated at a later date into the printer profile instead (that
makes way more sense).
2015-08-24 14:28:42 +02:00
Gina Häußge
168d32eb63 Fixed regex groups for GCODE parameters 2015-08-24 13:44:09 +02:00
Gina Häußge
6271bcfe05 Virtual printer now supports resend repetitions
If a new config setting is set, the virtual printer will now
resend the same resend request twice to allow testing the
comm layer behaviour in OctoPrint for being able to cope with
these possible repetitions like they can happen with Repetier.
2015-08-24 13:41:56 +02:00
Gina Häußge
6f836951b5 Handle Repetier resend repetitions
Repetier might resend the same resend request to make sure it arrives.
This commit makes OctoPrint not react to such a repeated request and
instead ignore up to a configurable amount of repeated requests for
the same (current) line.
2015-08-24 13:40:00 +02:00
Mark Walker
f519070d9c Clean up the comment 2015-08-22 18:38:01 -07:00
Mark Walker
e7584cdaac ClearableQueue redundant with self.close
Closing the printer connection and then reopening (when the users clicks
connect) will create a new fresh MachineCom object so the queues will
start out empty.  Plus ClearableQueue was even more tied to the Queue
implementation that the current _get/_put overrides.
2015-08-22 18:20:37 -07:00
Mark Walker
3d1d745581 Send M112 to printer immediately
Address #1031 with an immediate send of M112 followed by closing the
serial connection to reset the host state
2015-08-22 18:03:55 -07:00
Gina Häußge
d956773f04 Added warning to UI regarding Z timelapses and spiralized objects 2015-08-21 19:58:32 +02:00
Gina Häußge
c6d02903fa atomic_write context to save configs first to temp file, then move
Should prevent corruption of files
2015-08-21 19:52:31 +02:00
Gina Häußge
8dfb0cadd7 Forgot the contents of the ffmpegThreads template... 2015-08-21 19:10:17 +02:00
Gina Häußge
f1b2c43286 Merge branch 'devel' into dev/firstRunWizard 2015-08-21 18:40:21 +02:00
Gina Häußge
08c14e2e45 Wizard templates can now indicate they are mandatory
This will only style them in a special way and influence sorting. Plugins still need
to ensure that a step is not skipped through the use of the onWizardTabChange callback
in the view model.
2015-08-21 18:24:25 +02:00
Gina Häußge
990a44c7c9 Refactored cura settings dialog & fixed path check bug 2015-08-21 16:57:32 +02:00
Gina Häußge
9f591cbebe Merge pull request #1032 from Salandora/fixResend1
Fix Repetier Resend Request v2
2015-08-21 16:11:15 +02:00
Gina Häußge
d90c03377c Merge branch 'fixContextMenu' of https://github.com/Salandora/OctoPrint into pr/Salandora/fixContextMenu 2015-08-21 16:02:46 +02:00
Gina Häußge
f6a259fde3 Fixed & refactored temperature parsing
T-only lines were not properly parsed. Should now be fixed to
be associated to currently selected extruder. Also added unit
tests for the temperature parsing.

While at it also extracted regexes and added unit tests for command
parsing (gcode & parameters)
2015-08-21 15:47:03 +02:00
Salandora
d0373799ae Add Repetier's Format Error to exception whitelist 2015-08-21 12:51:09 +02:00
Gina Häußge
c5cc3d0394 DRY - let's use some snippets in the webcam settings
Makes the dialog components reusable for our wizard. Should probably
be done throughout...
2015-08-21 10:50:33 +02:00
Gina Häußge
b8fb16a074 flipH, flipV and rotate90 might be useful not only for the webcam_container 2015-08-21 10:44:30 +02:00
Gina Häußge
1007d18fd0 Reorganization of the webcam settings dialog 2015-08-21 10:32:11 +02:00
Gina Häußge
74e33cef01 Final touches to the core wizards and the cura wizard 2015-08-21 10:31:53 +02:00
Gina Häußge
1425b20bd6 Always include timelapse view model in bundled js files
Even if the webcam URLs and the FFMPEG path is not yet configured. Otherwise
setting those URLs and the path will require a restart of OctoPrint to enable properly -
that's overkill.
2015-08-21 10:30:03 +02:00
Gina Häußge
6691cc00a5 Documentation of the wizard plugins & slight refactoring 2015-08-20 12:50:45 +02:00
Gina Häußge
92c666400b If firstRun is true, ignore any seen wizards 2015-08-20 10:27:48 +02:00
Gina Häußge
9aa51d4f74 The settings enqueuing stuff for wizards was a stupid idea
Always save all settings from the client instead. Otherwise EVERY wizard needs its
own view model just to call that method...
2015-08-20 10:27:25 +02:00
Gina Häußge
3a6d577924 Fixed acl status handling & ffmpeg path in corewizard 2015-08-19 17:30:41 +02:00
Gina Häußge
3d5eb18530 Less verbose logging for view model calling helper 2015-08-19 17:30:07 +02:00
Gina Häußge
370231e128 Moved some things around and fixed a bug 2015-08-19 17:29:46 +02:00
Gina Häußge
b6b1bfd33b Allow programmatic login in the UI 2015-08-19 17:29:25 +02:00
Gina Häußge
c33fcdb124 Track already seen wizards 2015-08-19 17:28:23 +02:00
Gina Häußge
f4a952ebe6 Use new view model calling helper where possible 2015-08-19 11:48:22 +02:00
Gina Häußge
f7117900e6 New helper methods to call methods on view models 2015-08-19 11:46:33 +02:00
Mark Walker
84968272aa Hint about why timelapse configuration is disabled
while printing.

Fixes #1028
2015-08-18 22:49:50 -07:00
Gina Häußge
b1e4a1d9dc New corewizard plugin taking care of first run setup
Also introduced wizard finish backend method and remove old
firstrun dialog remnants.

TODO: bound check won't work this way, needs to be redone
differently. Goal is to only call onWizardFinish for wizards which
are actually involved...
2015-08-18 17:08:51 +02:00
Gina Häußge
1bba5ca788 Refactored settings save API methods to make actual saving reusable 2015-08-18 17:06:49 +02:00
Gina Häußge
d5a083b0b5 Extracted FFMPEG path config into reusable snippet & added test button 2015-08-18 17:06:16 +02:00
Gina Häußge
bc97241eef Callback method for wizard plugins for when the wizard is finished 2015-08-18 17:03:31 +02:00
Gina Häußge
58c6abc644 SWU: Don't use display versions for "current" in github_commit configs 2015-08-18 16:07:07 +02:00
Gina Häußge
c5b355705a Inject user manager into plugins 2015-08-18 13:30:23 +02:00
Gina Häußge
36d07532fb Fix: Don't hiccup on non-HTML-strings for message dialogs 2015-08-18 13:17:17 +02:00
Gina Häußge
a64a0545f3 Display dialog on settings update if wizard is active 2015-08-17 16:49:20 +02:00
Gina Häußge
edbbc49edd Test buttons for webcam URLs & extraction into snippet 2015-08-17 16:47:40 +02:00