GNOME Bugzilla – Bug 535572
"NoneType' object is not callable" warning on console
Last modified: 2012-10-04 07:37:43 UTC
postr causes no problem, but when closing, show line below in terminal. Exception exceptions.TypeError: "'NoneType' object is not callable" in ignored
I get this error too (and about 10 small windows appear and then disappear too) if I run the program from the command line, while in the directory where the executable is. However, if I run the program from a menu shortcut, I don't get the windows. No idea if the exception is thrown though. Answers are suggested here: http://mail.python.org/pipermail/python-list/2003-March/192239.html
Here is the output for postr.stable (0.12.3) ~/postr.stable$ ./postr /home/gpoo/code/bzr/postr.stable/src/flickrest.py:18: DeprecationWarning: the md5 module is deprecated; use hashlib instead import logging, md5, os, mimetools, urllib Unhandled error in Deferred: Traceback (most recent call last):
+ Trace 218799
self.factory.noPage(reason)
self.deferred.errback(reason)
self._startRunCallbacks(fail)
self._runCallbacks() --- <exception caught here> ---
self.result = callback(self.result, *args, **kw)
dialog = ErrorDialog(self.get_toplevel())
message_format="An error occurred")
Exception TypeError: "'NoneType' object is not callable" in ignored And here is the output for postr.dev (rev 279): ~/code/bzr/postr.dev$ ./postr /home/gpoo/code/bzr/postr.dev/src/flickrest.py:18: DeprecationWarning: the md5 module is deprecated; use hashlib instead import logging, md5, os, mimetools, urllib [Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionLost'>: Connection to the other side was lost in a non-clean fashion: Connection lost. ] Exception TypeError: "'NoneType' object is not callable" in ignored
This was odd. The issue was triggered by importing the module bsddb3 inside a function. Now it is fixed in master. Here is the fix: diff --git a/src/util.py b/src/util.py index bf58995..5974ae1 100644 @@ -17,7 +17,7 @@ import os from gi.repository import Gtk, GdkPixbuf - +import bsddb3 def greek(size): """Take a quantity (like 1873627) and display it in a human-readable rounded @@ -73,7 +73,6 @@ def get_buddyicon(flickr, data, size=48): """Lookup the buddyicon from the data in @data using @flickr and resize it to @size pixels.""" from twisted.web.client import getPage - import bsddb3 global __buddy_cache if __buddy_cache is None: