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).
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.
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.
Needs to be calculated differently for time based and z-triggered. Capture interval
was not taken properly into account.
(cherry picked from commit 9284ff4)
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)
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)
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)
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)
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)
Something in the recently released psutil 3.2.0 version causes installations via
python setup.py install to fail that list psutil as requirement.
Pinning to 3.1.1 solves that problem for now.