When autoscroll was disabled, terminal could run on endlessly, eating
memory until the browser crashes. Now a hard upper limit ensures
that not more than 3000 lines are ever stored in the terminal. If autoscroll
is disabled and the limit is reached, no more log lines will be added. That
ensures that the log will not scroll and the current log excerpt will stay put.
This way we create separate caches for URLs access via different schemes/prefixes/etc.
Otherwise our generated page might not work when accessing OctoPrint from external
after accessing it from internal once.
Otherwise the GCODE Viewer will get stuck "half way through" if
"sync with progress" is enabled but the tab/browser tab loses focus
during printing and only regains it after the print has finished.
This might help with #1065 if indeed is related to background tab suspending behaviours in
browsers, but is a completely blind guess at this point since I still have not been able to
reproduce that issue myself.
Backported.
(cherry picked from commit 720cdad)
This change should make sure that only those settings actually make it into config.yaml
per plugin that do differ from the default settings. Up until now the full dictionary as received
e.g. from the REST API was saved, regardless whether it contained (only) default values or not.
That led to a lot of "null" entries in the config.yaml file, which for one looked horrible and also
led to problems when a plugin actually wanted to change its default values.
With this commit, two things are done. One, upon saving a configuration the default
implementation of the save routine in the settings plugin now first diffs the new data against
the defaults and only saves what is different. Two, upon server startup a cleanup method is
now called on settings plugins whose default implementation fetches the current data stored
in config.yaml, diffs that against the defaults and only writes back the diff result. If that is empty
the entry is completely deleted from config.yaml.
(cherry picked from commit d70fe32)
When doing 'git checkout <rev>' or 'git checkout <tag>' there will be no
branch info:
$ git branch
* (detached from 96fc70b)
After whitelisting '\(detached.*' we get:
$ python setup.py version
running version
got version from git {'version': '1.2.5-1-gfd73e02', 'branch': 'HEAD',
'full': 'fd73e02f4fa9f286407ad688feeeee3ebaffea60'}
Version is currently: 1.2.5-1-gfd73e02
The '-1-gfd73e02' is this commit on top of the 1.2.5 tag.
While detached checkouts should be discouraged some buildsystems (e.g.
OpenEmbedded) have no real way to avoid it, which is what this patch
fixes. Actual people doing a checkout should use a branch.
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
(cherry picked from commit 987e637)
That was a tiny detail missing in 8bef18c2a8 that
caused issues with detecting which file was currently selected on the printer's
SD card (for "do not delete that" checks on the API).