On Wednesday 27 January 2016 03:15 AM, Rahul Amaram wrote:

Ok. I have included this as a patch. I am almost done with everything, except for the following bug while ugrading. After upgarding from 5.2.2 as per the instructions in READE.Debian (which I have updated), I am seeing the following errors in error.log whenever I try to connect via Icedove:

===============================================================

2016-01-27 02:54:58+0530 [BinaryBoxProtocol,1,] Unhandled Error
        Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/twisted/protocols/amp.py", line 954, in _commandReceived
            deferred = self.dispatchCommand(box)
File "/usr/lib/python2.7/dist-packages/twisted/protocols/amp.py", line 1011, in dispatchCommand
            return maybeDeferred(responder, box)
File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 150, in maybeDeferred
            result = f(*args, **kw)
File "/usr/lib/python2.7/dist-packages/twisted/protocols/amp.py", line 1100, in doit
            return maybeDeferred(aCallable, **kw).addCallback(
        --- <exception caught here> ---
File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 150, in maybeDeferred
            result = f(*args, **kw)
File "/usr/lib/python2.7/dist-packages/calendarserver/accesslog.py", line 685, in logStats
            self.observer.logStats(stats)
File "/usr/lib/python2.7/dist-packages/calendarserver/accesslog.py", line 378, in logStats
            self.systemStats = SystemMonitor()
File "/usr/lib/python2.7/dist-packages/calendarserver/accesslog.py", line 587, in __init__ "cpu count" : psutil.NUM_CPUS if psutil is not None else -1, exceptions.AttributeError: 'module' object has no attribute 'NUM_CPUS'

2016-01-27 02:54:58+0530 [BinaryBoxProtocol,1,] Amp server or network failure unhandled by client application. Dropping connection! To avoid, add errbacks to ALL remote commands!
        Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/twisted/protocols/amp.py", line 978, in ampBoxReceived
            self._commandReceived(box)
File "/usr/lib/python2.7/dist-packages/twisted/protocols/amp.py", line 957, in _commandReceived
            deferred.addCallback(self._safeEmit)
File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 317, in addCallback
            callbackKeywords=kw)
File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 306, in addCallbacks
            self._runCallbacks()
        --- <exception caught here> ---
File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 588, in _runCallbacks
            current.result = callback(current.result, *args, **kw)
File "/usr/lib/python2.7/dist-packages/twisted/protocols/amp.py", line 989, in _safeEmit
            aBox._sendTo(self.boxSender)
File "/usr/lib/python2.7/dist-packages/twisted/protocols/amp.py", line 667, in _sendTo
            proto.transport.loseConnection()
exceptions.AttributeError: 'DispatchingSender' object has no attribute 'transport'

2016-01-27 02:54:58+0530 [-] [caldav-1] [BinaryBoxProtocol,client] [calendarserver.accesslog#error] Unable to format event {'log_level': <LogLevel=error>, 'log_logger': <Logger 'calendarserver.accesslog'>, 'log_source': None, 'log_legacy': <twext.python.log.LegacyFormatStub object at 0xb4fccdcc>, 'format': '[calendarserver.accesslog#error] %(log_legacy)s', 'log_time': 1453843498.495608, 'log_namespace': 'calendarserver.accesslog', 'logLevel': 40, 'log_format': <twisted.python.failure.Failure twisted.protocols.amp.UnknownRemoteError: Code<UNKNOWN>: Unknown Error>}: Log format must be unicode or bytes, not <twisted.python.failure.Failure twisted.protocols.amp.UnknownRemoteError: Code<UNKNOWN>: Unknown Error> 2016-01-27 02:55:55+0530 [-] [calendarserver.tap.util#error] Unable to determine memory usage of PID: 2447 ('Process' object has no attribute 'get_memory_info')

========================================================================

1. Are you facing the same problem after upgrading? Would it possible for you to debug this? You can also run through the Upgrade section in README.Debian and let me know of anything that I have missed (or maybe just update it yourself).
So, this error seems to be because of a newer version of python-psutil that we are using in sid. Downgrading it to 2.2.1 fixed the problem. We need to figure out what in the neweer version of psutil is cuasing this error.

2. Also, after upgrade, I am unable to create any tasks. As a matter of fact, the calendar itself is not shown in the available calendars for adding tasks.
Problem Persists. Strange thing is if I upgrade from calendarserver 3.x, I am able to create tasks. Are you able to create tasks after upgrading from 5.x?

3. Upgrade from 3.x files is not working. I tried to migrate from files backend to db within 3.x on wheezy but even that is broken. Which means the only way to upgrade from 3.x to 7.x is to ask 3.x users to upgrade to 5.x, and then from 5.x to 7.x. With this in mind, do you think we should make 5.2.2 available in jessie backports (given that jessie does not have calendarserver anyway)?
Ok. Figured out the problem for this. We need python-xattr (>= 0.7.5) for performing migration from files backend in 3.x to db backend in 7.x. I will contact the upstream author reg. this.

It has been quite an effort this time to get calendarserver packaged. The upstream keep changing their codebase considerably and do not have proper upgrade process. I guess I'll have to get involved in calendarserver development so that I get more familiar with the codebase :).

Also, you can go ahead and upload the two new packages twext and pg8000. I don't anticipate any more changes.
Let me know when the packages are upgraded. Or do you to wait till all calendarserver issues are resolved?


Thanks,
Rahul.


--
http://rahul.amaram.name

Reply via email to