[Calendar and Contacts Server] #358: Error running carddav server in Linux
#358: Error running carddav server in Linux -----------------------------+---------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | -----------------------------+---------------------------------------------- When trying to launch the carddav server on a Debian Etch machine with ./run, I get the error: ImportError: No module named opendirectory I've tried commenting out all opendirectory-related resources in carddavd- dev.plist, but still get the error. I understand that there is no opendirectory on Linux, but there doesn't seem to be a way of keeping the server from trying to load that module. Full traceback below. exec python /home/dave/Twisted/bin/twistd -n carddav -f /home/dave/ContactsServer/conf/carddavd-dev.plist -o ProcessType=Combined Traceback (most recent call last): File "/home/dave/Twisted/bin/twistd", line 21, in <module> run() File "/home/dave/Twisted/twisted/scripts/twistd.py", line 27, in run app.run(runApp, ServerOptions) File "/home/dave/Twisted/twisted/application/app.py", line 374, in run config.parseOptions() File "/home/dave/Twisted/twisted/application/app.py", line 354, in parseOptions usage.Options.parseOptions(self, options) File "/home/dave/Twisted/twisted/python/usage.py", line 184, in parseOptions for (cmd, short, parser, doc) in self.subCommands: File "/home/dave/Twisted/twisted/application/app.py", line 365, in subCommands self.loadedPlugins[plug.tapname] = plug File "/home/dave/ContactsServer/twisted/plugins/carddav.py", line 13, in getProperty return getattr(reflect.namedClass(self.serviceMakerClass), propname) File "/home/dave/Twisted/twisted/python/reflect.py", line 347, in namedObject module = namedModule(string.join(classSplit[:-1], '.')) File "/home/dave/Twisted/twisted/python/reflect.py", line 335, in namedModule topLevel = __import__(name) File "/home/dave/ContactsServer/addressbookserver/tap/carddav.py", line 84, in <module> from twistedcaldav.static import AddressBookHomeProvisioningFile, DirectoryBackedAddressBookFile File "/home/dave/ContactsServer/twistedcaldav/static.py", line 78, in <module> from twistedcaldav.directory.addressbook import uidsResourceName as uidsResourceNameAddressBook File "/home/dave/ContactsServer/twistedcaldav/directory/addressbook.py", line 45, in <module> from twistedcaldav.report_addressbook_findshared import getReadWriteSharedAddressBookGroups, getReadOnlySharedAddressBookGroups, getWritersGroupForSharedAddressBookGroup File "/home/dave/ContactsServer/twistedcaldav/report_addressbook_findshared.py", line 30, in <module> import opendirectory ImportError: No module named opendirectory -- Ticket URL: <http://trac.calendarserver.org/ticket/358> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#358: Error running carddav server in Linux -----------------------------+---------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | -----------------------------+---------------------------------------------- Comment(by dennis@…): By enabling the build of PyOpenDirectory on linux, I was enable to get the server up. -- Ticket URL: <http://trac.calendarserver.org/ticket/358#comment:2> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#358: Error running carddav server in Linux -----------------------------+---------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | -----------------------------+---------------------------------------------- Comment(by guy@…): Replying to [comment:2 dennis@…]:
By enabling the build of PyOpenDirectory on linux, I was enable to get the server up.
Please can you provide some simple steps for this? -- Ticket URL: <http://trac.calendarserver.org/ticket/358#comment:3> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#358: Error running carddav server in Linux -----------------------------+---------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | -----------------------------+---------------------------------------------- Comment(by dennis@…): By editing the run script and comment out the check on darwin where PyOpenDirectory is fetched and build. This makes the server start, but I haven't been able to connect to it using a Address Book client. But this could be a configuration error on my side. -- Ticket URL: <http://trac.calendarserver.org/ticket/358#comment:4> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#358: Error running carddav server in Linux -----------------------------+---------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | -----------------------------+---------------------------------------------- Comment(by guy@…): which revision did you have checked out? I'm still not getting this work complete. I've checked out the latest: http://svn.calendarserver.org/repository/calendarserver/ContactsServer Revision: 5050 -- Ticket URL: <http://trac.calendarserver.org/ticket/358#comment:5> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#358: Error running carddav server in Linux -----------------------------+---------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | -----------------------------+---------------------------------------------- Comment(by dennis@…): I checked out trunk, which seems to be revision 4952. But I had no problem doing it with revision 5050 either. My changes in run is: [ContactServer]$ svn diff run Index: run =================================================================== --- run (revision 5050) +++ run (working copy) @@ -30,7 +30,7 @@ ## set -e -set -u +#set -u wd="$(cd "$(dirname "$0")" && pwd)"; @@ -558,7 +558,7 @@ # PyOpenDirectory # -if [ "$(uname -s)" == "Darwin" ]; then +#if [ "$(uname -s)" == "Darwin" ]; then # if ! py_have_module opendirectory; then opendirectory="${top}/PyOpenDirectory"; @@ -568,7 +568,7 @@ export PYTHONPATH="${PYTHONPATH}:${opendirectory}/build/${py_platform_libdir}"; # fi; -fi; +#fi; # # xattr -- Ticket URL: <http://trac.calendarserver.org/ticket/358#comment:6> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#358: Error running carddav server in Linux -----------------------------+---------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | -----------------------------+---------------------------------------------- Comment(by dennis@…): Trying again with code block: {{{ [dennis@blackbox3 ContactServer]$ svn diff run Index: run =================================================================== --- run (revision 5050) +++ run (working copy) @@ -30,7 +30,7 @@ ## set -e -set -u +#set -u wd="$(cd "$(dirname "$0")" && pwd)"; @@ -558,7 +558,7 @@ # PyOpenDirectory # -if [ "$(uname -s)" == "Darwin" ]; then +#if [ "$(uname -s)" == "Darwin" ]; then # if ! py_have_module opendirectory; then opendirectory="${top}/PyOpenDirectory"; @@ -568,7 +568,7 @@ export PYTHONPATH="${PYTHONPATH}:${opendirectory}/build/${py_platform_libdir}"; # fi; -fi; +#fi; # # xattr }}} -- Ticket URL: <http://trac.calendarserver.org/ticket/358#comment:7> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#358: Error running carddav server in Linux -----------------------------+---------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | -----------------------------+---------------------------------------------- Comment(by guy@…): ok well it seems to compile now... however when it starts the server: Starting server... exec python /root/Twisted/bin/twistd -n carddav -f /root/ContactServer2/conf/carddavd-dev.plist -o ProcessType=Combined Traceback (most recent call last): File "/root/Twisted/bin/twistd", line 21, in <module> run() File "/root/Twisted/twisted/scripts/twistd.py", line 27, in run app.run(runApp, ServerOptions) File "/root/Twisted/twisted/application/app.py", line 374, in run config.parseOptions() File "/root/Twisted/twisted/application/app.py", line 354, in parseOptions usage.Options.parseOptions(self, options) File "/root/Twisted/twisted/python/usage.py", line 184, in parseOptions for (cmd, short, parser, doc) in self.subCommands: File "/root/Twisted/twisted/application/app.py", line 365, in subCommands self.loadedPlugins[plug.tapname] = plug File "/root/ContactServer2/twisted/plugins/carddav.py", line 13, in getProperty return getattr(reflect.namedClass(self.serviceMakerClass), propname) File "/root/Twisted/twisted/python/reflect.py", line 347, in namedObject module = namedModule(string.join(classSplit[:-1], '.')) File "/root/Twisted/twisted/python/reflect.py", line 335, in namedModule topLevel = __import__(name) File "/root/ContactServer2/addressbookserver/tap/carddav.py", line 71, in <module> from twistedcaldav.resource import CalDAVResource File "/root/ContactServer2/twistedcaldav/resource.py", line 42, in <module> from twisted.web2.dav.idav import IDAVPrincipalCollectionResource ImportError: cannot import name IDAVPrincipalCollectionResource -- Ticket URL: <http://trac.calendarserver.org/ticket/358#comment:8> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#358: Error running carddav server in Linux -----------------------------+---------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | -----------------------------+---------------------------------------------- Comment(by rene@…): I can confirm the error, and also the workaround. -- Ticket URL: <http://trac.calendarserver.org/ticket/358#comment:10> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#358: Error running carddav server in Linux -----------------------------+---------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | Radar: -----------------------------+---------------------------------------------- Description changed by wsanchez@…: Old description:
When trying to launch the carddav server on a Debian Etch machine with ./run, I get the error:
ImportError: No module named opendirectory
I've tried commenting out all opendirectory-related resources in carddavd-dev.plist, but still get the error. I understand that there is no opendirectory on Linux, but there doesn't seem to be a way of keeping the server from trying to load that module.
Full traceback below.
exec python /home/dave/Twisted/bin/twistd -n carddav -f /home/dave/ContactsServer/conf/carddavd-dev.plist -o ProcessType=Combined Traceback (most recent call last): File "/home/dave/Twisted/bin/twistd", line 21, in <module> run() File "/home/dave/Twisted/twisted/scripts/twistd.py", line 27, in run app.run(runApp, ServerOptions) File "/home/dave/Twisted/twisted/application/app.py", line 374, in run config.parseOptions() File "/home/dave/Twisted/twisted/application/app.py", line 354, in parseOptions usage.Options.parseOptions(self, options) File "/home/dave/Twisted/twisted/python/usage.py", line 184, in parseOptions for (cmd, short, parser, doc) in self.subCommands: File "/home/dave/Twisted/twisted/application/app.py", line 365, in subCommands self.loadedPlugins[plug.tapname] = plug File "/home/dave/ContactsServer/twisted/plugins/carddav.py", line 13, in getProperty return getattr(reflect.namedClass(self.serviceMakerClass), propname) File "/home/dave/Twisted/twisted/python/reflect.py", line 347, in namedObject module = namedModule(string.join(classSplit[:-1], '.')) File "/home/dave/Twisted/twisted/python/reflect.py", line 335, in namedModule topLevel = __import__(name) File "/home/dave/ContactsServer/addressbookserver/tap/carddav.py", line 84, in <module> from twistedcaldav.static import AddressBookHomeProvisioningFile, DirectoryBackedAddressBookFile File "/home/dave/ContactsServer/twistedcaldav/static.py", line 78, in <module> from twistedcaldav.directory.addressbook import uidsResourceName as uidsResourceNameAddressBook File "/home/dave/ContactsServer/twistedcaldav/directory/addressbook.py", line 45, in <module> from twistedcaldav.report_addressbook_findshared import getReadWriteSharedAddressBookGroups, getReadOnlySharedAddressBookGroups, getWritersGroupForSharedAddressBookGroup File "/home/dave/ContactsServer/twistedcaldav/report_addressbook_findshared.py", line 30, in <module> import opendirectory ImportError: No module named opendirectory
New description: When trying to launch the carddav server on a Debian Etch machine with ./run, I get the error: {{{ ImportError: No module named open directory }}} I've tried commenting out all opendirectory-related resources in carddavd- dev.plist, but still get the error. I understand that there is no opendirectory on Linux, but there doesn't seem to be a way of keeping the server from trying to load that module. Full traceback below. {{{ exec python /home/dave/Twisted/bin/twistd -n carddav -f /home/dave/ContactsServer/conf/carddavd-dev.plist -o ProcessType=Combined Traceback (most recent call last): File "/home/dave/Twisted/bin/twistd", line 21, in <module> run() File "/home/dave/Twisted/twisted/scripts/twistd.py", line 27, in run app.run(runApp, ServerOptions) File "/home/dave/Twisted/twisted/application/app.py", line 374, in run config.parseOptions() File "/home/dave/Twisted/twisted/application/app.py", line 354, in parseOptions usage.Options.parseOptions(self, options) File "/home/dave/Twisted/twisted/python/usage.py", line 184, in parseOptions for (cmd, short, parser, doc) in self.subCommands: File "/home/dave/Twisted/twisted/application/app.py", line 365, in subCommands self.loadedPlugins[plug.tapname] = plug File "/home/dave/ContactsServer/twisted/plugins/carddav.py", line 13, in getProperty return getattr(reflect.namedClass(self.serviceMakerClass), propname) File "/home/dave/Twisted/twisted/python/reflect.py", line 347, in namedObject module = namedModule(string.join(classSplit[:-1], '.')) File "/home/dave/Twisted/twisted/python/reflect.py", line 335, in namedModule topLevel = __import__(name) File "/home/dave/ContactsServer/addressbookserver/tap/carddav.py", line 84, in <module> from twistedcaldav.static import AddressBookHomeProvisioningFile, DirectoryBackedAddressBookFile File "/home/dave/ContactsServer/twistedcaldav/static.py", line 78, in <module> from twistedcaldav.directory.addressbook import uidsResourceName as uidsResourceNameAddressBook File "/home/dave/ContactsServer/twistedcaldav/directory/addressbook.py", line 45, in <module> from twistedcaldav.report_addressbook_findshared import getReadWriteSharedAddressBookGroups, getReadOnlySharedAddressBookGroups, getWritersGroupForSharedAddressBookGroup File "/home/dave/ContactsServer/twistedcaldav/report_addressbook_findshared.py", line 30, in <module> import opendirectory ImportError: No module named open directory }}} -- -- Ticket URL: <http://trac.calendarserver.org/ticket/358#comment:12> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#358: Error running carddav server in Linux -------------------------------+-------------------------------------------- Reporter: dave@… | Owner: wsanchez@… Type: Defect | Status: closed Priority: 5: Not set | Milestone: CalendarServer-3.1 Component: Calendar Server | Severity: Other Resolution: Software changed | Keywords: Radar: | -------------------------------+-------------------------------------------- Changes (by wsanchez@…): * status: new => closed * resolution: => Software changed * milestone: => CalendarServer-3.1 Comment: It should no longer be necessary to try to force build `PyOpenDirectory`. Try again with trunk. -- Ticket URL: <http://trac.calendarserver.org/ticket/358#comment:13> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
participants (1)
-
Calendar and Contacts Server