Commit Graph

122 Commits

Author SHA1 Message Date
eb9218354c Always use readers-writer lock in storage locking 2016-05-22 10:29:56 +02:00
bca6cec6b3 Use context manager for locking 2016-05-22 10:29:50 +02:00
b810d61ce3 Don't sanitize local paths using posixpath
This doesn't work as expected on Windows.
2016-05-21 01:41:00 +02:00
2c45b1998c Implement locking of whole storage 2016-05-21 01:26:45 +02:00
2dee66133d Flake8 fixes 2016-05-04 19:25:58 +02:00
2f97d7d1e1 Remove global state about configuration and logs
Many things have been changed to make this possible, probably leading to
many hidden bugs waiting to be found.

Related to #122.
2016-04-22 11:37:02 +09:00
303a53eede Return Items in upload and update methods
Related to #380
2016-04-20 08:09:00 +09:00
3a9bcc7555 Add etag property to items
Related to #380.
2016-04-20 07:49:03 +09:00
6adc7f5fed Enhance collection discovering
When the request path leads to a non-existing item, try to create the
Collection object according to an existing collection at request path's
parent.

This change means that the requests whose path leads to a collection
that doesn't exist (at least MKCOL, MKCALENDAR and PUT) need to rely on
the request path more than on the Collection path. It was already done
for PUT, it's been fixed for MKCOL and MKCALENDAR.

Fix #378.
2016-04-19 10:39:52 +09:00
65659fc909 Improve WebDAV compatibility
Add getlastmodified and getcontentlength properties, and fix nested
collections support. Fix #321.
2016-04-18 09:11:00 +09:00
e8c1defe6a Update PROPPATCH to new storage API 2016-04-13 23:02:00 +02:00
f169f2f19b Don't crash if collection doesn't exist yet 2016-04-13 22:09:00 +02:00
a1cdcf2fba Don't crash if propsfile doesn't exist 2016-04-12 22:43:10 +02:00
e586569b31 Fix a lot of details 2016-04-12 18:21:18 +02:00
406027f3c9 Change the Collection API
The new API used comes from vdirsyncer, as proposed by @untitaker in
issue #130.

The code has been tested and works with the (too simple) unit tests, and
with Lightning and DAVdroid. Many things are broken and a good part of
the code has not be ported to the new API yet. TODOs have been added
where the application is known to be broken.
2016-04-11 20:11:35 +02:00
2408097ab9 Clean the storage module 2016-04-10 02:37:43 +02:00
41e319a8b8 Merge ical and storage modules 2016-04-10 02:08:07 +02:00
73d39ea572 Use vobject 2016-04-10 01:36:45 +02:00
12ddd64884 Fix the management of paths 2016-04-09 22:44:34 +02:00
7a0e267f19 Better collection discovery 2016-04-09 15:11:47 +02:00
54dee0c7c4 Clean tests 2016-04-07 19:25:10 +02:00
1001bcb676 Remove extra auth, rights and storage modules 2016-04-07 19:02:52 +02:00