Yves Dorfsman wrote:
> There are minor errors in the doc string of dsm.py, such as:
>
> | input_file
> | File-object to read the LDIF input from
>
> Which obviously has been copied from the ldif.py.
Uuumh, thanks. Checked in corrected version in CVS HEAD.
Ciao, Michael.
-
Yves Dorfsman wrote:
> Is there a simple example for dsml.DSMLParser() somewhere ?
No, this module is rather unmaintained.
IIRC it mainly works like module ldif: You should sub-class
dsml.DSMLParser implementing a custom method .handle(). Note that it
only supports DMSLv1 which is not what you wa
Michael Ströder wrote:
> Yves Dorfsman wrote:
>> Is there a simple example for dsml.DSMLParser() somewhere ?
>
> No, this module is rather unmaintained.
>
> IIRC it mainly works like module ldif: You should sub-class
> dsml.DSMLParser implementing a custom method .handle(). Note that it
> only su
Yves Dorfsman wrote:
> Michael Ströder wrote:
>> Yves Dorfsman wrote:
>>> But eventually it fails with an HTTP 404 error...
>> ???
>
> Yes I was confused too.
> [..]
>File "/usr/lib/python2.5/urllib2.py", line 506, in http_error_default
> raise HTTPError(req.get_full_url(), code, msg, hdr
Michael: Can you confirm this is the way it was supposed to be used, I mean,
is this class the sort of argument that should be used for ContentHandler ?
> Yves Dorfsman wrote:
>
>> I have tried:
>> x = dsml.DSMLParser(input_file, dsml.DSMLv1Handler)
I have noted your observation about dsml v1,
I'd like to propose:
1) adding the ldif.LDIFWriter.writeFooter(self) method
which would simply write:
version: x
with x the version number of the LDIF format (1 for now).
2) Add a variable 'version' to the ldif.LDIFParser, ldif.LDIFWriter classes
as well as an option in the constructor of th