[Twisted-Python] Confusing traceback from mktap.py

Jp Calderone exarkun at intarweb.us
Tue Mar 11 19:10:11 EST 2003

On Tue, Mar 11, 2003 at 04:46:44PM -0600, Bradley Duane Peters wrote:
> Greetings,
> I have somehow caused my Twisted application to become un-TAPable. 
> Running it through mktap.py (in the same fashion as when it did work) 
> results in the following traceback.
> Traceback (most recent call last):
>   File "mktap.py", line 30, in ?
>     run()
>   File "C:\Python22\Lib\site-packages\twisted\scripts\mktap.py",
>       line 178, in run
>     a.save()
>   File "C:\Python22\Lib\site-packages\twisted\internet\app.py",
>       line 634, in save
>     dumpFunc(self, f)
>   File "C:\Python22\Lib\site-packages\twisted\internet\app.py",
>       line 616, in dumpFunc
>     _dump(obj, file, 1)
> TypeError: 'NoneType' object is not callable

  You shouldn't be able to induce this error with your code.  I can't
actually imagine -how- this might be induced, apparently "cPickle.dump" has
gotten itself to be None.  Perhaps you have "cPickle.py" in your source,
with "dump = None" in it?  Could you try this interactively, preferably
in your package's directory, and/or where you ran mktap from?

    import cPickle
    print cPickle.__file__, cPickle.dump

> Unfortunately, I don't have an old version to go back to, and I don't 
> know enough about Twisted to know where I should look for a problem. 

  Did you upgrade your app, or Twisted?  BTW, random piece of advise, always
develop with some sort of RCS software, be it CVS or something else.  It's
great for situations where you can't track down what has broken something...
you just back out changes until it works again.


A disciple of another sect once came to Drescher as he was eating his
morning meal. "I would like to give you this personality test," said the
outsider, "because I want you to be happy." Drescher took the paper that was
offered him and put it into the toaster: "I wish the toaster to be happy, 
 up 8 days, 15:59, 8 users, load average: 0.22, 0.13, 0.04
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://twistedmatrix.com/pipermail/twisted-python/attachments/20030311/f1de741b/attachment.pgp 

More information about the Twisted-Python mailing list