radicale's listing multiple calendars under a single user doesn't work
when radicale runs using apache for configuration,
IF radicale is not at the root of a virtual server.
(e.g., if it is at www.example.com/caldav/ instead of
caldav.example.com/).
What happens?
giving www.example.com/caldav/user/
to acal (on android) checks out as caldav,
but it doesn't list any sub-calendars,
even if
www.example.com/caldav/user/foo.ics/
and
www.example.com/caldav/user/bar.ics/
exist.
What should happen?
In acal, "list calendars" should find foo.ics and bar.ics.
why? apache strips off the /caldav/ base prefix.
Radicale then returns entries with short href's
(/user/, /user/foo.ics/, /user/bar.ics/)
in response to the PROPFIND Depth: 1 query during discovery.
But these hrefs are wrong... they're missing /caldav/.
One might think fixing this by putting
base_prefix=/caldav/
in /etc/radicale/config
would do the trick, but no:
because Apache strips that off, this config fails
the check "Path not starting with prefix"
in radicale.init.
Suggested fix:
add a new config parameter:
can_skip_base_prefix
that avoids this check. It all then works, provided this goes in the
config:
base_prefix=/caldav/
can_skip_base_prefix=True
the statement: "The [server] part of the configuration is ignored."
is not true. Giving a base_prefix is enforced.
The statement "You should use the root of the (sub)domain
(WSGIScriptAlias /), else some CalDAV features may not work." is true
and is the limitation I hit.
With the patch, this statement should change to :
"If you have a non-empty base_prefix, then you MUST set
"can_skip_base_prefix=True" in your config or some CalDAV features
(like discovering calendars) will not work.
radicale's listing multiple calendars under a single user doesn't work when radicale runs using apache for configuration, IF radicale is not at the root of a virtual server. (e.g., if it is at www.example.com/caldav/ instead of caldav.example.com/).
What happens? giving www.example.com/caldav/user/ to acal (on android) checks out as caldav, but it doesn't list any sub-calendars, even if www.example.com/caldav/user/foo.ics/ and www.example.com/caldav/user/bar.ics/ exist.
What should happen? In acal, "list calendars" should find foo.ics and bar.ics.
why? apache strips off the /caldav/ base prefix. Radicale then returns entries with short href's (/user/, /user/foo.ics/, /user/bar.ics/) in response to the PROPFIND Depth: 1 query during discovery.
But these hrefs are wrong... they're missing /caldav/.
One might think fixing this by putting base_prefix=/caldav/ in /etc/radicale/config would do the trick, but no: because Apache strips that off, this config fails the check "Path not starting with prefix" in radicale.init.
Suggested fix:
add a new config parameter: can_skip_base_prefix that avoids this check. It all then works, provided this goes in the config: base_prefix=/caldav/ can_skip_base_prefix=True
Patch:
against radicale-0.8-7.fc20.noarch Other patches are of course possible and perhaps cleaner; this one works for me.
This fix addresses two issues on http://radicale.org/user_documentation/#idapache-and-mod-wsgi