Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 204278 - dev-python/tlslite-0.3.8 - XMLRPCTransport doesn't work with python 2.5
Summary: dev-python/tlslite-0.3.8 - XMLRPCTransport doesn't work with python 2.5
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Stefan Briesenick (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: python-2.5
  Show dependency tree
 
Reported: 2008-01-04 14:19 UTC by Åsmund Grammeltvedt
Modified: 2008-01-05 22:01 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
proposed patch (tlslite-0.3.8-python2.5.patch,1.30 KB, patch)
2008-01-04 14:19 UTC, Åsmund Grammeltvedt
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Åsmund Grammeltvedt 2008-01-04 14:19:12 UTC
As of python 2.5, tlslite-0.3.8's XMLRPCTransport doesn't set xmlrpclib.Transport._use_datetime and overrides the __init__ which sets this attribute. This causes a crash at least in xmlrpclib.Transport.getparser, where the attribute is used.

Reproducible: Always

Steps to Reproduce:
1.>>> from tlslite.api import XMLRPCTransport
2.>>> XMLRPCTransport().getparser()

Actual Results:  
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib64/python2.5/xmlrpclib.py", line 1210, in getparser
    return getparser(use_datetime=self._use_datetime)
AttributeError: XMLRPCTransport instance has no attribute '_use_datetime'

Expected Results:  
>>> from xmlrpclib import Transport
>>> Transport().getparser()
(<xmlrpclib.ExpatParser instance at 0xdb0d40>, <xmlrpclib.Unmarshaller instance at 0xdb0cf8>)
Comment 1 Åsmund Grammeltvedt 2008-01-04 14:19:56 UTC
Created attachment 140062 [details, diff]
proposed patch
Comment 2 Stefan Briesenick (RETIRED) gentoo-dev 2008-01-04 21:34:31 UTC
one question: does this patch works also for older python versions?
Comment 3 Åsmund Grammeltvedt 2008-01-05 13:55:25 UTC
It should, and I've used it with python 2.4 without any problems. _use_datetime doesn't exist in earlier versions, and I can't see any crazy introspection that could have caused problems. Setting it should have no effect in <2.5.
Comment 4 Stefan Briesenick (RETIRED) gentoo-dev 2008-01-05 21:46:21 UTC
ok, then I include the patch, though I will revbump for testing.

but please send this patch also upstream. thanks!
Comment 5 Stefan Briesenick (RETIRED) gentoo-dev 2008-01-05 22:01:30 UTC
ok, new revision in portage. please test!