Open douglm opened 11 years ago
I'm the maintainer of the python caldav library. I'm currently working on running the test suite towards as many server implementations as possible.
With bedwork, most of the tests concerning the correct handling of VTODOs failed - in asserts. I haven't looked much into it, but I believe it's the server that doesn't properly handle todo items.
Also, when trying to insert a VJOURNAL, I got a 403, apparently complaining about a wrong resource type.
I'll skip those tests for bedework, and attribute it to this issue ticket. Please advise if it's deemed fixed or if you want more details on why/how things are failing.
More details would be useful. Bedework is passing a lot of the vtodo tests in the caldav test suite so I'd like to get some idea of what you're seeing.
Also which version of bedework?
Thanks.
On 1/3/17 20:51, Tobias Brox wrote:
I'm the maintainer of the python caldav library. I'm currently working on running the test suite towards as many server implementations as possible.
With bedwork, most of the tests concerning the correct handling of VTODOs failed - in asserts. I haven't looked much into it, but I believe it's the server that doesn't properly handle todo items.
Also, when trying to insert a VJOURNAL, I got a 403, apparently complaining about a wrong resource type.
I'll skip those tests for bedework, and attribute it to this issue ticket. Please advise if it's deemed fixed or if you want more details on why/how things are failing.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Bedework/bedework/issues/5#issuecomment-270276260, or mute the thread https://github.com/notifications/unsubscribe-auth/AC2mBgHydxnBfpcilgRZMARYBu4pkVaYks5rOvsRgaJpZM4BCBSD.
Here are my steps of reproduction (obviously some tons of dependencies needs to be installed for this to work, and it's needed to pause for a while between launching the docker instance and running the tests):
sudo docker run -dp 8080:8080 ioggstream/bedework
cd /tmp ; hg clone https://bitbucket.org/cyrilrbt/caldav
cd caldav
hg checkout v0.5.0.dev
echo 'caldav_servers=[{"url": "http://localhost:8080/ucaldav/", "username": "vbede", "password": "bedework", "nojournal": True, "nopropfind": True}]' >> tests/conf.py
nosetests
The Dockerfile that this docker image is supposed to be built from is referencing http://dev.bedework.org/downloads/3.10.3/quickstart-3.10.3.zip. I didn't really verify that, started playing with Docker only yesterday.
The first test that breaks simply attempts to add a vtodo to the calendar and pull it out again, but apparently it finds nothing. Here is the vtodo insertion:
sending request - method=PUT, url=http://localhost:8081/ucaldav/user/vbede/pythoncaldav-test/20070313T123432Z-456553@example.com.ics, headers={'Depth': '0', 'User-Agent': 'Mozilla/5.0', 'Content-Type': 'text/calendar; charset="utf-8"', 'Accept': 'text/xml'}
body:
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Example Corp.//CalDAV Client//EN
BEGIN:VTODO
CATEGORIES:FAMILY,FINANCE
CLASS:CONFIDENTIAL
DTSTAMP:20070313T123432Z
DUE;VALUE=DATE:20070501
STATUS:NEEDS-ACTION
SUMMARY:Submit Quebec Income Tax Return for 2006
UID:20070313T123432Z-456553@example.com
END:VTODO
END:VCALENDAR
Response looks fine:
response headers: {'Cache-Control': 'no-cache', 'Expires': 'Thu, 01 Jan 1970 00:00:00 UTC', 'X-Powered-By': 'Servlet 2.5; JBoss-5.0/JBossWeb-2.1', 'Date': 'Wed, 04 Jan 2017 11:30:12 GMT', 'Set-Cookie': 'JSESSIONID=10DA3F4028C03AEF2D4DA6726183CA1F; Path=/ucaldav', 'Server': 'Apache-Coyote/1.1', 'Content-Length': '0', 'Pragma': 'No-cache'}
response status: 201
raw response: ''
Now, fetching the full list of todo items (should be one):
sending request - method=REPORT, url=http://localhost:8081/ucaldav/user/vbede/pythoncaldav-test/, headers={'User-Agent': 'Mozilla/5.0', 'Content-Type': 'application/xml; charset="utf-8"', 'Accept': 'text/xml', 'Depth': '1'}
body:
<?xml version='1.0' encoding='utf-8'?>
<C:calendar-query xmlns:C="urn:ietf:params:xml:ns:caldav" xmlns:D="DAV"><ns0:prop xmlns:ns0="DAV:"><C:calendar-data/></ns0:prop><C:filter><C:comp-filter name="VCALENDAR"><C:comp-filter name="VTODO"><C:prop-filter name="COMPLETED"><C:is-not-defined/></C:prop-filter><C:prop-filter name="STATUS"><C:text-match collation="i;octet" negate-condition="yes">COMPLETED</C:text-match></C:prop-filter><C:prop-filter name="STATUS"><C:text-match collation="i;octet" negate-condition="yes">CANCELLED</C:text-match></C:prop-filter></C:comp-filter></C:comp-filter></C:filter></C:calendar-query>
I haven't looked carefully into the calendar-query above, it may be that there is some mistake there, but the idea is to fetch all VTODOs where COMPLETED attribute is not defined and STATUS is neither set to COMPLETED nor CANCELLED.
Here is the response:
response headers: {'Cache-Control': 'no-cache', 'Expires': 'Thu, 01 Jan 1970 00:00:00 UTC', 'X-Powered-By': 'Servlet 2.5; JBoss-5.0/JBossWeb-2.1', 'Date': 'Wed, 04 Jan 2017 11:30:12 GMT', 'Set-Cookie': 'JSESSIONID=F8415127332156190FD5747A9A3F9A83; Path=/ucaldav', 'Server': 'Apache-Coyote/1.1', 'Content-Length': '375', 'Pragma': 'No-cache', 'Content-Type': 'text/xml;charset=UTF-8'}
response status: 207
raw response:
<?xml version="1.0" encoding="UTF-8" ?>
<DAV:multistatus xmlns="urn:ietf:params:xml:ns:caldav"
xmlns:AI="http://apple.com/ns/ical/"
xmlns:ical="http://www.w3.org/2002/12/cal/ical#"
xmlns:BSS="http://bedeworkcalserver.org/ns/"
xmlns:CS="http://calendarserver.org/ns/"
xmlns:DAV="DAV:">\n</DAV:multistatus>
Current practice is to put different kinds of components, vevent, vtodo etc into separate collections.
/user/x/calendar is for events, /user/x/tasks for todos etc.
We need support for this in the client as well as the back end. Mostly it's a matter of adjusting how we select the appropriate collection.