root/livinglogic.python.xist/NEWS.rst @ 5312:9a98178e4483

Revision 5312:9a98178e4483, 129.7 KB (checked in by Walter Doerwald <walter@…>, 7 years ago)

Merge UL4 templates and functions again.

Templates call be called as functions. All ouput will be ignored in this case.

Executing templates is now done by interpreting the AST directly (via the eval()
method), instead of generating Python source code from it first.

AST nodes can both produce output and return results via enhanced generators.

Constant folding has been removed.

Line 
1Changes in 4.10 (released ??/??/2013)
2--------------------------------------
3
4*   It's now possible to use UL4 templates as functions::
5
6        >>> from ll import ul4c
7        >>> f = ul4c.Template("<?return 2*x?>")
8        >>> f(x=42)
9        84
10
11    Normal output of the template will be ignored if it is used as a function.
12
13*   The builtin UL4 functions are now real objects that can be passed to templates
14    as arguments.
15
16*   The UL4 functions ``vars`` and ``get`` have been removed.
17
18*   The automatic UL4 variable ``stack`` has been removed too.
19
20
21Changes in 4.9.1 (released 01/17/2013)
22--------------------------------------
23
24*   Fixed a bug the ``printx`` tag for UL4 templates.
25
26
27Changes in 4.9 (released 01/17/2013)
28------------------------------------
29
30*   Fixed a bug in UL4 templates when a template called a top-level template
31    which in turn called its own subtemplate.
32
33*   Fixed and enhanced ``repr`` output of UL4 templates and added support
34    for IPythons pretty printing framework.
35
36
37Changes in 4.8 (released 01/15/2013)
38------------------------------------
39
40*   Linefeeds and indentation in the literal text for UL4 templates can now be
41    ignored by specifying ``keepws=False`` in the template constructor.
42
43
44Changes in 4.7 (released 01/11/2013)
45------------------------------------
46
47*   A variable ``stack`` is now automatically defined in all UL4 templates. This
48    list contains a stack of the currently executing UL4 templates. ``stack[-1]``
49    is the current template.
50
51*   UL4 templates now support lexical scopes. A locally defined subtemplate can
52    access all local variables of the template in which it is defined.
53
54*   UL4 functions and methods now support keyword arguments, e.g.
55    ``format(now(), fmt="%Y-%m-%d", lang="en")``.
56
57*   UL4 templates can no longer be converted to Java ``CompiledTemplate`` objects.
58    (However converting it to an ``InterpretedTemplate`` is of course still
59    supported).
60
61*   If the view ``ctx_preferences`` doesn't exist :meth:`orasql.Preference.itername``
62    now will simply return an empty iterator instead of failing with an Oracle
63    exception ``ORA-00942: table or view does not exist``.
64
65*   For sisyphus jobs, the class attribute ``maxtime`` can now be set to a
66    ``datetime.timedelta`` object.
67
68
69Changes in 4.6 (released 12/18/2012)
70------------------------------------
71
72*   The :meth:`walk` method in XIST has been changed: The return value is a
73    cursor object that provides information about the path and can be used to
74    skip subtrees in the traversal. Filters (which are called selectors now)
75    can no longer influence which parts of the trees are traversed, only whether
76    a node is returned by the iterator or not.
77
78*   :func:`ll.xist.parse.itertree` now supports the same interface is the
79    :meth:`walk` method.
80
81*   A new function :func:`xfind.filter` has been added that filters the output
82    of :meth:`walk` or :func:`itertree` against a :class:`Selector` object.
83
84*   The XIST parse events have been renamed: The ``"start*"`` events to
85    ``"enter*"`` and the ``"end*"`` events to ``"leave*"``.
86
87*   Slicing XIST elements now returns a sliced element, instead of a slice from
88    the content :class:`Frag`::
89
90        >>> from ll.xist.ns import html
91        >>> html.ul(html.li(i) for i in range(5))[1:3].string()
92        '<ul><li>1</li><li>2</li></ul>'
93
94*   Functions with keyword only arguments are now supported in
95    :func:`ll.xist.ns.doc.explain`.
96
97*   :class:`ll.misc.monthdelta` now supports the :func:`abs` function (i.e.
98    ``abs(monthdelta(-1))`` returns ``monthdelta(1)``.)
99
100
101Changes in 4.5 (released 11/29/2012)
102------------------------------------
103
104*   Added UL4 functions ``any`` and ``all``.
105
106*   To improve UL4 exception messages there are now several undefined objects,
107    which give information about which key/name/index resulted in the undefined
108    object being created.
109
110*   UL4ON can no longer read or write undefined values.
111
112*   The UL4 function ``format`` now swallows all exceptions produced by
113    :mod:`locale`.
114
115*   Oracle URLs now support reading and writing bytes.
116
117*   Because of problems with `distribute`_/`pip`_ and `pytest`_
118    :file:`ll/__init__.py` has been reintroduced.
119
120    .. _distribute: http://pypi.python.org/pypi/distribute
121    .. _pip: http://www.pip-installer.org/
122    .. _pytest: http://pytest.org/latest/
123
124
125Changes in 4.4 (released 11/08/2012)
126------------------------------------
127
128*   Python 3.3 is required now (as the code uses ``yield from`` and
129    ``__qualname__``).
130
131*   :file:`ll/__init__.py` has been removed, i.e. XIST is now a PEP 420
132    compatible namespace package.
133
134*   Fixed tab/space mix in :file:`antlr3/debug.py`.
135
136
137Changes in 4.3.1 (released 11/06/2012)
138--------------------------------------
139
140*   Added a method ``values`` to UL4 for dictionaries.
141
142*   Fixed a bug in ``ll.misc.SysInfo.user_shell``.
143
144*   Fixed function :func:`ll.xist.ns.doc.explain` for methods.
145
146
147Changes in 4.3 (released 11/02/2012)
148------------------------------------
149
150*   UL4 now uses a parser generated by ANTLR_ instead of using spark_. This means
151    that the Python parser can now use the same grammar as the Java parser.
152    (A Python 3 port of the ANTLR runtime is included).
153
154    .. _ANTLR: http://www.antlr.org/
155    .. _spark: http://pages.cpsc.ucalgary.ca/~aycock/spark/
156
157*   Accessing non-existant variables in UL4 templates now no longer raises an
158    exception but returns the special object ``Undefined``. The same is true for
159    accessing non-existant dictionary keys or list/string indexes that are out of
160    range.
161
162    In a boolean context ``Undefined`` is treated as false and ``str(Undefined)``
163    returns the empty string.
164
165*   Two new UL4 functions have been added: ``isundefined`` returns whether the
166    argument is the ``Undefined`` object or not. ``isdefined`` has the inverted
167    logic, i.e. it returns ``True`` if the argument is *not* the ``Undefined``
168    object.
169
170*   The characters CR and LF are no longer allowed in UL4 string constants.
171    Furthermore the escape sequence ``\e`` is no longer supported.
172
173*   All AST nodes for loading constants have been merged into a single class
174    :class:`Const`.
175
176*   :mod:`ll.ul4on` can now read and write :class:`datetime.timedelta` and
177    :class:`misc.monthdelta` objects as well as the new ``Undefined`` object
178    from UL4 (:class:`ll.ul4c.Undefined`).
179
180
181Changes in 4.2 (released 10/22/2012)
182------------------------------------
183
184*   UL4 templates now support list and dictionary comprehension as well as
185    generator expressions.
186
187*   A new UL4 function ``date`` has been added.
188
189*   The UL4 method ``join`` no longer calls ``str`` on the items in the argument
190    list.
191
192*   The UL4 function format now supports a third argument: the language for
193    formatting dates. So ``format(date(2012, 10, 10), '%A', 'de')`` outputs
194    ``Mittwoch``.
195
196*   UL4 date objects now have a new ``week`` method. This method returns the
197    week number of the year. It supports one argument: the weekday number
198    (0 for Monday, ... 6 for Sunday) that should be considered the start day
199    of the week. All days in a new year preceding the first week start day are
200    considered to be in week 0. The week start day defaults to 0 (Monday).
201
202*   :class:`datetime.timedelta` objects are now completely supported in UL4
203    templates: They can be created with the ``timedelta`` function and can be
204    type tested for with ``istimedelta``.
205
206*   Added a new class :class:`ll.misc.monthdelta`. :class:`monthdelta` objects
207    can be used to add months/years to a :class:`datetime.datetime` or
208    :class:`datetime.date` object. If the resulting day falls out of the range of
209    valid days for the target month, the last day for the target month will be
210    used instead.
211
212*   :class:`monthdelta` objects are now supported in UL4 templates: They can be
213    created with the ``monthdelta`` function and can be type tested for with
214    ``ismonthdelta``.
215
216
217Changes in 4.1.1 (released 10/04/2012)
218--------------------------------------
219
220*   Fixed a bug in the UL4 handling of slices. (``('0' + str(x))[-2:]`` didn't
221    work correctly.)
222
223
224Changes in 4.1 (released 10/02/2012)
225------------------------------------
226
227*   Loop variable unpacking in UL4 now allows arbitrary nesting.
228
229*   Variable assignment in UL4 now allows variable unpacking too, i.e.
230    ``(a, b) = [17, 23]``.
231
232*   The support for Growl notifications in :mod:`ll.make` on the Mac has been
233    replaced by support for Mountain Lions Notification Center via
234    terminal-notifier__.
235
236    __ https://github.com/alloy/terminal-notifier
237
238*   :mod:`sispyhus` jobs now support notifications too.
239
240*   Java conversion of :class:`ll.ul4c.And` has been fixed to evaluate the second
241    operand only when the result isn't clear from the first.
242
243*   :class:`ll.ul4on.Decoder` now raises an ``EOFError`` when reading from an
244    empty stream.
245
246*   A new script has been added: ``oradd.py`` can be used for importing data into
247    an Oracle database (via procedure calls).
248
249
250Changes in 4.0 (released 08/08/2012)
251------------------------------------
252
253*   The source has been ported to Python 3. From now on XIST is a Python 3 only
254    project. A big thanks goes to Martin v. Löwis, who got this conversion
255    started at PyCon DE 2011. He did the basic ``2to3`` conversion and updated
256    the C source to work on Python 3. Without Martin, XIST wouldn't have made
257    the leap to Python 3 for several years.
258
259*   As there's no Python 3 port of libxml2_\s Python wrapper, XIST now uses lxml_
260    for HTML parsing.
261
262    .. _libxml2: http://www.xmlsoft.org/
263    .. _lxml: http://lxml.de/
264
265    This change shouldn't have any visible consequences.
266
267*   UL4 templates are no longer compiled to byte code, instead the AST is
268    evaluated or converted to the target sourcecode directly.
269
270*   Generating the final Javascript source code for UL4 templates is now done in
271    Javascript itself.
272
273*   A new module :mod:`ul4on` has been added. This module provides functions for
274    encoding and decoding a lightweight extensible machine-readable text format
275    for serializing the object types supported by UL4.
276
277*   The following new functions have been added to UL4: ``isfirst``, ``islast``,
278    ``isfirstlast``, ``enumfl``. They are variants of ``enumerate`` that give
279    information about whether the item is the first and/or last item.
280
281*   The following new functions have been added to UL4: ``urlquote`` and
282    ``urlunquote``. They encode/decode the ``%``-escaped form of URL query
283    parameters.
284
285*   The UL4 function ``json`` has been renamed to ``asjson`` and the following
286    new UL4 functions have been added: ``fromjson``, ``asul4on`` and ``fromul4on``.
287
288*   The UL4 function ``enumerate`` now supports 1 or 2 arguments (the second
289    argument being the start value).
290
291*   The UL4 functions ``str``, ``bool``, ``int`` and ``float`` now support being
292    called without arguments (just like in Python).
293
294*   Date constants in UL4 have changed again. They are now written like this:
295    ``@(2012-04-12)`` or ``@(2012-04-12T12:34:56)``.
296
297*   The ``<?render?>`` tag in UL4 now looks like a method call instead of a
298    function call. I.e. ``<?render t(a=17, b=23)?>`` has changed to
299    ``<?render t.render(a=17, b=23)?>``.
300
301*   UL4 stacktraces now use exception chaining to report the exception location
302    in nested templates.
303
304*   The UL4 methods ``find`` and ``rfind`` now support lists and tuples.
305
306*   Two new UL4 functions have been added: ``min`` and ``max``.
307
308*   The sort order for attributes when publishing XIST trees can be overwritten
309    by setting the ``xmlorder`` class attribute to a string. This string will be
310    used for sorting the attribute. Attributes that have ``xmlorder`` set will
311    always be published before those that don't.
312
313*   Support for the old ``ipipe`` infrastructure has been removed. Support for
314    IPythons new pretty printing infrastructure has been added. Output looks like
315    this::
316
317        In [1]: from ll.xist.ns import xml, html
318        In [2]: html.a(
319           ...:         'gurk',
320           ...:         xml.Attrs(lang='de'),
321           ...:         class_='link',
322           ...:         href='http://www.example.org/',
323           ...:         id='dings42',
324           ...: )
325        Out[2]:
326        ll.xist.ns.html.a(
327           'gurk',
328           ll.xist.ns.xml.Attrs.lang='de',
329           class_='link',
330           href='http://www.example.org/',
331           id='dings42')
332
333*   Added the attributes ``allowfullscreen`` and ``flashvars`` to
334    :class:`ll.xist.ns.html.embed`.
335
336*   Added the attribute ``allowfullscreen`` to  :class:`ll.xist.ns.html.iframe`.
337
338*   The :meth:`isdir` method now always returns ``False`` for real (i.e.
339    non-file or ssh) URLs. This allows stuff like::
340
341        ucp http://www.python.org/ftp/python/2.7.2/Python-2.7.2.tar.bz2 \
342            ssh://user@www.example.org/~/src/
343
344*   :class:`ll.orasql.Index` now uses the ``*_INDEXES`` views to get a list of
345    all indexes and ``LOB`` indexes are filtered out, since they will be recreated
346    with the LOB itself. The method :meth:`table` has been fixed for indexes that
347    belong to a different user than the index.
348
349*   :class:`ll.orasql.LOBStream` has a new method :meth:`seek`.
350
351*   :class:`ll.make.FileAction` supports encoding/decoding when writing/reading
352    the file. For this use the :var:`encoding` and :var:`errors` arguments.
353
354*   The XIST node method :meth:`sorted` has been removed, as it no longer makes
355    sense, because with Python 3 nodes might be uncomparable.
356
357*   Th support for ``%u`` escapes in URLs has been removed.
358
359*   The function :func:`html.astext` now uses the newer `links 2`_
360
361    .. _links 2: http://links.twibright.com/
362
363*   The scripts ``oracreate``, ``oradrop``, ``oradelete``, ``oradiff``,
364    ``oramerge``, ``oragrant``, ``orafind`` and ``uhpp`` no longer have an
365    :option:`-e`/:option:`--encoding` option. They always use Pythons output
366    encoding.
367
368*   The options :option:`-i`/:option:`--inputencoding` and
369    :option:`-o`/:option:`--outputencoding` of the script ``db2ul4`` have been
370    replaced with an option :option:`-e`/:option:`--encoding` for the encoding
371    of the template files. For printing the result Pythons output encoding is
372    used.
373
374*   The options :option:`--inputencoding`,/:option:`--inputerrors` and
375    :option:`--outputencoding`/:option:`--outputerrors` of
376    :class:`ll.sisyphus.Job` have been replaced with option
377    :option:`--encoding`/:option:`--errors` for the encoding of the log files.
378
379*   ``oradiff`` now iterates through the object in correct order, so if you're
380    running ``oradiff`` with ``-mfull`` the output shouldn't produce any errors
381    when executed.
382
383*   :mod:`ll.orasql.Index` can now handle domain indexes.
384
385*   :mod:`ll.orasql.Preference` has been added.
386
387*   :mod:`ll.orasql` now ignores indexes of type ``IOT - TOP``.
388
389*   :mod:`ll.orasql` can now handle primary keys where the underlying index has
390    a different name.
391
392*   :mod:`ll.orasql` now ignores tables with names starting with ``DR$``
393    (i.e. those created by Oracle Text Search).
394
395*   Attributes of :class:`ll.misc.SysInfo` instances are now calculated on
396    demand. With this change only one instance of :class:`ll.misc.SysInfo` is
397    required. This instance is :class:`ll.misc.sysinfo`.
398
399*   When connecting to the database :mod:`ll.orasql` sets the ``client_info``
400    attribute to the name of the running script (unless ``clientinfo=None`` is
401    passed to the :func:`connect` call).
402
403*   :class:`ll.xist.ns.specials.loremipsum` now repeats the text if the specified
404    ``len`` attribute is greater that the length of the lorem ipsum text.
405
406
407Changes in 3.25 (released 08/12/2011)
408-------------------------------------
409
410*   :class:`ll.xist.parse.Tidy` will now output the attribute events in sorted
411    order. Publishing an XIST node will output the attributes in sorted order too.
412
413*   The :meth:`compact` method has been renamed to :meth:`compacted` to avoid
414    collisions with the ``compact`` attribute in HTML elements.
415
416*   A new script ``uhpp`` has been added, that can be used for pretty printing
417    HTML. As the attributes are output in alphabetical order it can also be used
418    as a tool for comparing HTML files.
419
420
421Changes in 3.24.1 (released 08/10/2011)
422---------------------------------------
423
424*   Fixed a bug in the new :class:`ll.xist.xsc.AttrElement` class that surfaced
425    in the context of boolean attributes.
426
427
428Changes in 3.24 (released 08/09/2011)
429-------------------------------------
430
431*   The :class:`ProcInst` subclass :class:`ll.xist.xsc.AttrProcInst` has been
432    replaced with an :class:`Element` subclass :class:`ll.xist.xsc.AttrElement`.
433    Conditional handling of the attribute will be used, if the
434    :class:`AttrElement` instance is the only
435    child of the attribute. Outside of attributes the :class:`AttrElement`
436    instance will be published normally (via :meth:`publish`, which must be
437    implemented).
438
439*   :class:`ll.xist.ns.ul4.attr_if` is an :class:`ll.xist.xsc.AttrElement`
440    subclass now. The condition is in the ``cond`` attribute and the attribute
441    content is inside the element. Outside of an attribute :class:`attr_if`
442    will put a normal UL4 ``if`` condition around its content.
443
444*   :class:`ll.xist.ns.ul4.attr_ifnn` has been removed.
445
446
447Changes in 3.23.1 (released 07/28/2011)
448---------------------------------------
449
450*   Fixed a bug in :mod:`ll.sisyphus`: The code wasn't updated to use
451    :class:`ll.ul4c.Template` instead of :func:`ll.ul4c.compile`.
452
453
454Changes in 3.23 (released 07/20/2011)
455-------------------------------------
456
457*   UL4 template objects now have a name. This name will be displayed in
458    exception messages. Nested templates display their own name in the exception
459    message.
460
461*   The module global functions :func:`ll.ul4c.compile`, :func:`ll.ul4c.load` and
462    :func:`ll.ul4c.loads` have been removed. Instead of them the :class:`Template`
463    constructor and the class methods :meth:`load` and :meth:`loads` can be used.
464
465*   The script ``oradelete`` now supports the options :option:`--include`,
466    :option:`--exclude` and :option:`--keepjunk` too.
467
468
469Changes in 3.22 (released 07/14/2011)
470-------------------------------------
471
472*   The scripts ``oracreate``, ``oradrop`` and ``oragrant`` have new options
473    :option:`--include` and :option:`--exclude` that can be used to filter the
474    objects that will be output.
475
476
477Changes in 3.21 (released 06/03/2011)
478-------------------------------------
479
480*   Oracle 10 doesn't have a ``DBA_ARGUMENTS`` view.
481    Fixed :class:`ll.orasql.Function` and :class:`ll.orasql.Procedure`
482    accordingly.
483
484*   The ``type`` attribute for the :class:`input` element now supports the new
485    input types from HTML5.
486
487*   The form elements :class:`input`, :class:`select` and :class:`textarea`
488    gained the additional attributes from HTML5.
489
490
491Changes in 3.20.2 (released 05/23/2011)
492---------------------------------------
493
494*   Unicode parameters in :meth:`execute` and :meth:`executemany` in
495    :mod:`ll.xist.orasql` now get encoded to the Oracle client character set.
496
497
498Changes in 3.20.1 (released 05/18/2011)
499---------------------------------------
500
501*   Fixed a bug in the Java code generation for UL4 templates: When the template
502    source code contained C-style comments (i.e. ``/* foo */``) invalid Java
503    source code was produced.
504
505
506Changes in 3.20 (released 05/05/2011)
507-------------------------------------
508
509*   It's now possible to specify the connection mode (i.e. ``SYSDBA`` and
510    ``SYSOPER``) in ``oracle`` URLs like this::
511
512        $ uls oracle://sys:pwd:sysdba@dsn/
513
514    Supported are the values ``normal`` (the default), ``sysdba`` and ``sysoper``.
515
516*   The :var:`schema` argument used by various methods in :mod:`ll.orasql` has
517    been replaced by a :var:`owner` argument that can be :const:`None` (for the
518    current user), the constant :const:`ALL` for all users (which uses the
519    ``DBA_*`` variant of various meta data views if possible or the ``ALL_*``
520    variants otherwise) and a specific user name.
521
522    These views are also used if possible in all spots where the ``ALL_`` views
523    where used before.
524
525*   It's now possible to list all users in the database with the class methods
526    :meth:`User.iternames` and :meth:`User.iterobjects` and with
527    :meth:`Connection.iterusers`.
528
529*   Oracle :class:`Column` objects have a new method :meth:`table` that returns
530    the table the column belongs to.
531
532*   Oracle URLs now support the directory ``user/`` which contains all users, i.e.
533    ``oracle://user:pwd@db/user/`` lists all users and
534    ``oracle://user:pwd@db/user/foo/`` lists the same stuff as
535    ``oracle://foo:pwd@db/``. This directory however will *not* be listed in the
536    root directory ``oracle://user:pwd@db/``.
537
538*   :mod:`ll.orasql` now supports tables without columns.
539
540*   :class:`ll.orasql.Table` has a new method :meth:`pk` that returns the primary
541    key contraint (or :const:`None` if the table has now primary key contraint).
542
543*   A bug in the queries for :class:`Index` objects in :mod:`ll.orasql` has been
544    fixed.
545
546*   :mod:`ipipe` support has been removed from :mod:`ll.orasql`.
547
548*   Fixed a bug in :class:`ll.xist.xsc.Pool`: Registered elements/entities etc.
549    now show up as attributes of the pool object.
550
551
552Changes in 3.19 (released 04/26/2011)
553-------------------------------------
554
555*   :mod:`ll.orasql` now requires cx_Oracle 5.1.
556
557*   If the :var:`readlobs` option is false for :mod:`ll.orasql` cursors, the
558    CLOBs/BLOBs returned will be wrapped into something that behaves like a
559    Python file.
560
561
562Changes in 3.18.1 (released 04/13/2011)
563---------------------------------------
564
565*   The methods :meth:`elements`, :meth:`procinsts`, :meth:`entities` and
566    :meth:`charrefs` of :class:`ll.xist.xsc.Pool` now handle base pools properly.
567
568
569Changes in 3.18 (released 04/08/2011)
570-------------------------------------
571
572*   Fixed a regression in :class:`ll.orasql.OracleConnection`.
573
574*   Fixed :exc:`ZeroDivisionError` in script ``uls`` for empty directories.
575
576*   Added a class method :meth:`ll.orasql.Contraint.iternames` and a class method
577    :meth:`ll.orasql.Index.iternames` that skips those indexes that are generated
578    by constraints. With this addition ``uls``/``ucp`` now list/copy constraints
579    and indexes properly. All ``iternames`` methods now skip objects whose name
580    starts with ``BIN$``.
581
582*   The scripts ``uls``, ``ucp`` and ``ucat`` have new options :option:`--include`
583    and :option:`--exclude` for including/excluding URLs that match a regular
584    expression. They also have an new option :option:`--all` to include/exclude
585    dot files (i.e. files/directories whose name starts with a dot)
586
587*   ``ucp`` now supports to new options :option:`--padding` and
588    :option:`--separator` which are used for column output.
589
590*   Two unused options were removed: :option:`--verbose` from the script ``ucat``
591    and :option:`--defaults` from the script ``tld2xsc``.
592
593*   ``ucp -x`` now prints exception details.
594
595*   The variables available in UL4 templates used by ``db2ul4`` have changed.
596    Instead of a ``connect`` object, there are now three objects for each
597    supported database (i.e. ``oracle``, ``sqlite`` and ``mysql``)
598
599*   The script ``doc2txt`` now reads from ``stdin`` and writes to ``stdout``
600    instead of requiring file names on the command line.
601
602*   If the scripts ``xml2xsc`` or ``dtd2xsc`` are called without arguments
603    ``stdin`` is read.
604
605*   :mod:`ll.xist.ns.rest` now handles option lists.
606
607*   The Oracle URLs provided by :mod:`ll.orasql` now have a ``.sql`` extension
608    for all schema objects. On writing a ``.sql`` extension will be stripped to
609    get the name of the schema object.
610
611*   Oracle URLs now should support schema objects with fancy names (i.e. ones
612    that contain accented characters).
613
614*   :class:`ll.orasql.Table` has a new method :meth:`organization` that returns
615    ``"heap"`` or normal tables and ``"index"`` for index organized tables.
616
617*   Pretty printing of XIST trees can now be customized with the class attributes
618    :var:`prettyindentbefore` and :var:`prettyindentafter`. The values will be
619    added to the current indentation level before and after the node in question.
620
621*   All scripts that are part of XIST (``uls``, ``ucp``, ``ucat``, ``db2ul4``,
622    ``dtd2xsc``, ``tld2xsc``, ``doc2txt``, ``xml2xsc``, ``oracreate``,
623    ``oradrop``, ``oradelete``, ``oradiff``, ``oramerge``, ``oragrant`` and
624    ``orafind``) are now properly documented on the webpages.
625
626
627Changes in 3.17.3 (released 03/02/2011)
628---------------------------------------
629
630*   Enhanced support for table and column names containing non-ASCII characters
631    in :mod:`ll.orasql`.
632
633*   Fixed a bug in the ``uls`` script: In long recursive mode files were
634    printed twice.
635
636
637Changes in 3.17.2 (released 02/25/2011)
638---------------------------------------
639
640*   Fixed ``setup.py`` so that the spacer GIF and the UL4 Javascript support
641    library *really* get installed.
642
643
644Changes in 3.17.1 (released 02/25/2011)
645---------------------------------------
646
647*   Due to a bug in ``MANIFEST.in`` the spacer GIF and the UL4 Javascript support
648    library where not included in the distirbution package. This has been fixed.
649
650
651Changes in 3.17 (released 02/24/2011)
652-------------------------------------
653
654*   The UL4 function ``repr`` now handles all instances of
655    :class:`collections.Mapping` and :class:`collections.Sequence` too.
656
657*   The spacer pixel ``px/spc.gif`` and the UL4 Javascript support library
658    ``ul4.js`` will now be installed alongside the Python modules (in
659    ``ll.xist.data``).
660
661*   The Java source code produced by :meth:`ll.ul.Template.javasource` will now
662    contain register declarations only for the registers that are actually used.
663
664*   :func:`misc.javastring` has been renamed to :func:`misc.javaexpr` can can
665    now produce the Java sourcecode for more types.
666
667*   The UL4 method ``isoformat`` now omits the time part if it is ``00:00:00``.
668
669*   The UL4 function ``repr`` now produces a valid UL4 date literal for date
670    objects.
671
672*   The UL4 method ``format`` is now a function instead.
673
674*   The tests for UL4 now test the Java implementation too.
675
676
677Changes in 3.16 (released 01/21/2011)
678-------------------------------------
679
680*   The UL4 functions ``json``, ``type``, ``islist`` and ``isdict`` can now
681    handle all instances of :class:`collections.Mapping` and
682    :class:`collections.Sequence` not just :class:`tuple`, :class:`list` and
683    :class:`dict`.
684
685*   :mod:`ll.sisyphus` logging of exceptions and tracebacks should be more robust
686    against encoding problems.
687
688*   The :mod:`cssutils` version has been bumped to 0.9.7.
689
690*   ``dtd2xsc.py`` can now combine the content of more than one DTD into a
691    namespace. Handling of duplicate elements can be specified with a new
692    :option:`duplicates` option.
693
694*   ``xml2xsc.py`` can now collect the XML info from multiple XML files.
695
696*   Fixed a bug in the command line argument handling of ``dtd2xsc.py``.
697
698*   ``dtd2xsc.py`` can now handle undefined entities.
699
700*   The help message for all scripts in XIST now show the default for all options.
701
702*   Replaced the function :func:`misc.flag` with a class :class:`misc.FlagAction`
703    that can be used as the action in :meth:`argparse.ArgumentParser.add_argument`
704    calls.
705
706*   Command line options for all scripts have been enhanced: Flags without a
707    ``yes``/``no`` value now toggle the default (using the new
708    :class:`misc.FlagAction`).
709
710*   The script ``xml2xsc.py`` has a new option :option:`--defaultxmlns` for
711    setting a namespace name for elements without a namespace.
712
713*   :mod:`ll.xist.xnd` and the related scripts have seen some refactoring.
714
715
716Changes in 3.15.3 (released 11/26/2010)
717---------------------------------------
718
719*   :mod:`ll.sisyphus` now supports a non-forking mode (``--fork=no``). In this
720    mode executing the job and monitoring the maximum runtime is done by the same
721    (single) process.
722
723
724Changes in 3.15.2 (released 11/25/2010)
725---------------------------------------
726
727*   Publishing an :class:`ll.xist.ns.xml.XML` object will now always put the
728    correct encoding into the XML declaration, no matter where in the XML tree
729    the :class:`xml.XML` object sits.
730
731
732Changes in 3.15.1 (released 11/24/2010)
733---------------------------------------
734
735*   Fixed a bug in the error handling code of the UL4 compiler when an unknown
736    function or method was encountered.
737
738*   Fixed str/unicode problems with the search string in ``orafind.py``.
739
740
741Changes in 3.15 (released 11/09/2010)
742-------------------------------------
743
744*   It's now possible to create Java source code from UL4 templates with the
745    method :meth:`ll.ul4c.Template.javasource`.
746
747*   Creating source code (in Python, Javascript and Java) from UL4 templates
748    has been moved out of :class:`ll.ul4c.Template` into separate classes.
749
750*   The function :func:`ll.xist.ns.fromul4` now uses the new method
751    :meth:`ll.ul4c.Template.javasource` for generating JSP.
752
753*   The binary format for UL4 templates has changed to enhance readability.
754
755*   :func:`ll.xist.ns.jsp.javastring` has been moved to :mod:`ll.misc`.
756
757
758Changes in 3.14 (released 11/05/2010)
759-------------------------------------
760
761*   UL4 templates now have a method :meth:`jssource` that returns Javascript
762    source code. This means that now UL4 templates can be converted to: Python
763    source code, JSP source code and Javascript source code.
764
765*   Date constants in UL4 have changed. They are now written like this:
766    ``@2010-11-05T``.
767
768*   :meth:`ul4c.Template.pythonsource` no longer accepts :const:`None` as the
769    function name. The output will always be a full function.
770
771
772Changes in 3.13 (released 10/22/2010)
773-------------------------------------
774
775*   sisyphus jobs now have a new method :meth:`prefix`. This method is a context
776    manager. For the duration of the ``with`` block, the passed in prefix will be
777    prepended to all log lines.
778
779*   :mod:`ll.sisyphus` job can now log to ``stdout`` and ``stderr`` with the new
780    options :option:`-o`/:option:`--log2stdout` and
781    :option:`-e`/:option:`--log2stderr`.
782
783*   The tags that :mod:`ll.sisyphus` itself uses for logging have changed
784    slightly. For more info see the module documentation.
785
786*   The option :option:`-l` for sisyphus jobs has been renamed to :option:`-f`.
787
788
789Changes in 3.12.1 (released 10/21/2010)
790---------------------------------------
791
792*   Fixed a bug in :mod:`ll.sisyphus` when logging exceptions.
793
794
795Changes in 3.12 (released 10/21/2010)
796-------------------------------------
797
798*   The way that :mod:`ll.sisyphus` handles running jobs has changed. Jobs no
799    longer create a pid file. Avoiding duplicate running jobs is done with a file
800    lock on the script file and limiting the maximum runtime is done by forking
801    the process and monitoring the runtime in the parent process. This means that
802    a job that is past its maximum allowed runtime will not be killed by the next
803    job invocation. Instead the job will kill itself.
804
805*   A new class :mod:`ll.misc.SysInfo` has been added that provides
806    host/user/python/script information. :mod:`ll.sisyphus` uses this new
807    class.
808
809*   Changed the default output of tags in :mod:`ll.sisyphus` log files from::
810
811        [tag1, tag2, tag3]
812
813    to::
814
815        [tag1][tag2][tag3]
816
817*   The default location for :mod:`ll.sisyphus` log files has changed to
818    ``~/ll.sisyphus/projectname/jobname/``.
819
820*   :class:`ll.orasql.ForeignKey` has a new method :meth:`itercolumns` for
821    iterating over the columns the foreign key consists of.
822
823*   Fixed a bug in the ``uls`` script: For remote URLs uid and gid must be
824    resolved on the remote host.
825
826
827Changes in 3.11.1 (released 10/18/2010)
828---------------------------------------
829
830*   Fixed two bugs in the error handling for unknown XML parsing events in
831    :meth:`ll.xist.parse.Expat.__call__` and :meth:`ll.xist.parse.SGMLOP.__call__`
832    (exceptions were yielded instead of raised).
833
834*   :mod:`ll.sisyphus` jobs now don't break if they can't find the script source.
835
836
837Changes in 3.11 (released 10/15/2010)
838-------------------------------------
839
840*   :mod:`ll.sisyphus` has been rewritten. The new version supports: One log
841    file per job invocation; enhanced configuration for logging; command line
842    arguments.
843
844*   Various attributes of UL4 templates are exposed to UL4 itself.
845
846*   Fixed a bug in :meth:`ll.url.LocalConnection.rename`.
847
848
849Changes in 3.10.1 (released 10/13/2010)
850---------------------------------------
851
852*   Fixed bugs in the handling of the ``def`` and ``enddef`` opcodes in
853    :func:`ll.xist.ns.jsp.fromul4`.
854
855*   Fixed a bug in the handling of the ``render`` method in
856    :func:`ll.xist.ns.jsp.fromul4`.
857
858
859Changes in 3.10 (released 09/24/2010)
860-------------------------------------
861
862*   Python 2.7 is required now as XIST now uses set literals, set and dict
863    comprehension, the new :mod:`argparse` module and various other new features
864    of Python 2.7.
865
866*   All scripts and :mod:`ll.make` have been ported to use :mod:`argparse`.
867
868*   Fixed a bug in :mod:`ll.nightshade`. If the function/procedure didn't set an
869    encoding, the handling of the response body was totally broken (which
870    resulted in a ISO-8859-1 encoded output).
871
872*   :class:`ll.xist.parse.Tidy` now supports an additional parameter: If
873    :var:`skipbad` is true, unknown elements and attributes will be skipped.
874
875*   The random number functions ``random``, ``randrange`` and ``randchoice``
876    have been added to UL4.
877
878*   A new function :func:`ll.misc.prettycsv` has been added. It can be
879    used to pretty print the data produced by the :mod:`csv` module.
880
881
882Changes in 3.9 (released 08/04/2010)
883------------------------------------
884
885*   :class:`ll.xist.ns.html.html` will no longer change the ``lang`` and
886    ``xml:lang`` attributes. This functionality has been moved to the new element
887    :class:`ll.xist.ns.htmlspecials.html`. Furthermore this new element won't
888    change existing attributes.
889
890*   :class:`ll.xist.ns.html.title` no longer does any manipulation of its content.
891
892*   The Java string literal formatting function in :mod:`ll.xist.ns.jsp` has been
893    exposed as :func:`javastring`.
894
895*   Fixed a bug in ``oracreate.py``: If the source of procedures and functions
896    didn't have whitespace between the name and the ``(`` the ``(`` was missing
897    from the output.
898
899
900Changes in 3.8.3 (released 07/29/2010)
901--------------------------------------
902
903*   :class:`str` arguments are now always treated as ``BLOB``\s in
904    :mod:`ll.orasql` functions and procedures.
905
906
907Changes in 3.8.2 (released 06/21/2010)
908--------------------------------------
909
910*   Fixed a bug in the logging methods of :class:`ll.sisyphus.Job`: Logging
911    unicode strings didn't work. Now all strings are promoted to unicode.
912
913*   The default encoding for :class:`ll.sisyphus` log files has changed to UTF-8.
914    This can be changed by setting the class attribute :attr:`encoding` in the
915    class derived from :class:`ll.sisyphus.Job`.
916
917
918Changes in 3.8.1 (released 06/17/2010)
919--------------------------------------
920
921*   The method :meth:`ll.url.URL.import_` that had been dropped in version 3.8
922    has been reintroduced. However internally :func:`misc.module` is used for
923    creating the module object. A side effect of this is that importing from
924    non-local URLs now works::
925
926        >>> from ll import url
927        >>> u = url.URL("http://www.livinglogic.de/Python/misc/index_module.py")
928        >>> m = u.import_()
929        >>> m.last("gurk")
930        "k"
931
932
933Changes in 3.8 (released 06/15/2010)
934------------------------------------
935
936*   The parsing infrastructure has been completely rewritten to be more modular
937    and to support iterative parsing (similar to `ElementTree`__).
938
939    __ http://effbot.org/zone/element-iterparse.htm
940
941    Now parsing XML is done in a pipelined approach that looks like this::
942
943        >>> from ll.xist import xsc, parse
944        >>> from ll.xist.ns import html
945        >>> doc = parse.tree(
946        ...     parse.String("<a href='http://www.python.org/'>Python</a>")
947        ...     parse.Expat()
948        ...     parse.NS(html)
949        ...     parse.Node(pool=xsc.Pool(html))
950        ... )
951        >>> doc.bytes()
952        '<a href="http://www.python.org/">Python</a>'
953
954    Iterative parsing looks like this::
955
956        >>> from ll.xist import xsc, parse
957        >>> from ll.xist.ns import xml, html, chars
958        >>> for (evtype, path) in parse.itertree(
959        ...     parse.URL("http://www.python.org/"),
960        ...     parse.Expat(ns=True),
961        ...     parse.Node(pool=xsc.Pool(xml, html, chars)),
962        ...     filter=html.a/html.img
963        ... ):
964        ...     print path[-1].attrs.src, "-->", path[-2].attrs.href
965        http://www.python.org/images/python-logo.gif --> http://www.python.org/
966        http://www.python.org/images/trans.gif --> http://www.python.org/#left%2Dhand%2Dnavigation
967        http://www.python.org/images/trans.gif --> http://www.python.org/#content%2Dbody
968        http://www.python.org/images/donate.png --> http://www.python.org/psf/donations/
969        http://www.python.org/images/worldmap.jpg --> http://wiki.python.org/moin/Languages
970        http://www.python.org/images/success/tribon.jpg --> http://www.python.org/about/success/tribon/
971
972*   The XIST element :class:`ll.xist.ns.specials.z` has been moved to the
973    :mod:`ll.xist.ns.doc` module.
974
975*   The function :class:`ll.xist.xsc.docprefixes` has been dropped. A new
976    function :class:`ll.xist.xsc.docpool` has been added.
977
978*   The module :mod:`ll.xist.parsers` has been renamed to :mod:`parse`.
979
980*   The module :mod:`ll.xist.presenters` has been renamed to :mod:`present`.
981
982*   The classes :class:`ll.xist.converters.Converter` and
983    :class:`ll.xist.publishers.Publisher` has been moved to :mod:`ll.xist.xsc`.
984    The modules :mod:`ll.xist.converters` and :mod:`ll.xist.publishers` no longer
985    exist.
986
987*   The walk methods :meth:`walknode` and :meth:`walkpath` have been renamed to
988    :meth:`walknodes` and :meth:`walkpaths` and the implemention has been moved
989    from the nodes classes into :class:`WalkFilter`. :class:`WalkFilter` has been
990    moved to :mod:`ll.xist.xfind`.
991
992*   A new selector has been added to :mod:`ll.xist.xfind`: :class:`AnySelector`
993    outputs all nodes.
994
995*   Added a new function :func:`misc.module` that creates a module from source
996    code.
997
998*   :class:`ll.url.Path` has been simplified: Path segments are strings instead
999    of tuples now.
1000
1001*   The old :class:`URL` method :meth:`import_` has been removed. The new
1002    function :func:`misc.module` can now be used for that.
1003
1004*   The two classes :class:`ll.make.PoolAction` and
1005    :class:`ll.make.XISTPoolAction` have been dropped. You can use
1006    ``make.ObjectAction(misc.Pool).call()`` and
1007    ``make.ObjectAction(xsc.Pool).call()`` for that.
1008
1009*   The class :class:`XISTParseAction` has been removed. This action can be
1010    replaced by a combination of :class:`ObjectAction`, :class:`CallAction` and
1011    :class:`CallAttrAction`.
1012
1013*   Two new UL4 functions ``abs`` and ``utcnow`` have been added.
1014
1015*   A few methods have been added to UL4 date objects: ``mimeformat``, ``day``,
1016    ``month``, ``year``, ``hour``, ``minute``, ``second``, ``microsecond``,
1017    ``weekday`` and ``yearday``.
1018
1019*   Use autoboxing in the Java code generated by :mod:`ll.xist.ns.jsp.fromul4`.
1020
1021*   All code has been switched to using the :meth:`format` method instead of
1022    using the ``%`` operator.
1023
1024*   ssh URLs in :mod:`ll.url` now use the standalone :mod:`execnet` package__.
1025
1026    __ http://codespeak.net/execnet/
1027
1028*   ssh URLs now support a ``nice`` argument instead of ``ssh_config``.
1029
1030
1031Changes in 3.7.6 (released 05/14/2010)
1032--------------------------------------
1033
1034*   Fixed a bug in :class:`ll.xist.ns.htmlspecials.autopixel`.
1035
1036
1037Changes in 3.7.5 (released 04/19/2010)
1038--------------------------------------
1039
1040*   :class:`ll.orasql.PrimaryKey` has a new method :meth:`itercolumns` that
1041    returns an iterator over the columns this primary key consists of.
1042
1043
1044Changes in 3.7.4 (released 03/25/2010)
1045--------------------------------------
1046
1047*   Fixed a bug in :class:`ll.xist.ns.rss20.guid`. The ``isPermaLink`` attribute
1048    was a :class:`URLAttr`, but must be a :class:`TextAttr`.
1049
1050
1051Changes in 3.7.3 (released 02/27/2010)
1052--------------------------------------
1053
1054*   Fixed a bug in the generated JSP code for the ``def`` opcode in
1055    :func:`ll.xist.ns.jsp.fromul4`.
1056
1057
1058Changes in 3.7.2 (released 02/26/2010)
1059--------------------------------------
1060
1061*   Fixed two bugs in the XML codecs:
1062
1063    -   An externally specified encoding wasn't honored in the incremental decoder.
1064
1065    -   Fixed reset() for incremental codecs: If encoding has been changed during
1066        parsing in the incremental codecs it now gets reset to its proper initial
1067        value.
1068
1069*   Fixed a bug in the handling of the UL4 opcode ``addlist`` in
1070    :func:`ll.xist.ns.jsp.fromul4`.
1071
1072*   Added missing processing instruction class for the UL4 ``def`` tag to the
1073    :mod:`ll.xist.ns.ul4` namespace module.
1074
1075*   The generated JSP code for the ``loadvar`` opcode now uses the Java method
1076    ``Utils.getItem``, so that non-existent variables no longer get treated as
1077    ``None``/``null``.
1078
1079
1080Changes in 3.7.1 (released 02/08/2010)
1081--------------------------------------
1082
1083*   :func:`ll.xist.ns.jsp.fromul4` now outputs the correct code for calling the
1084    ``format`` method on date objects (This requires version exp-22 of the
1085    UL4 Java package).
1086
1087
1088Changes in 3.7 (released 09/10/2009)
1089------------------------------------
1090
1091*   In UL4 templates it's now possible to define locale templates via
1092    ``<?def tmpl?>templatecode<?end def?>``.
1093
1094*   Python 2.6 is required now.
1095
1096*   :mod:`ll.orasql` and :mod:`ll.nightshade` are now part of the distribution.
1097
1098*   :mod:`ll.make` has a new Action class: :class:`ObjectAction` simply returns
1099    an existing object.
1100
1101*   The following classes have been removed from :mod:`ll.make`:
1102    :class:`EncodeAction`, :class:`DecodeAction`, :class:`EvalAction`,
1103    :class:`GZipAction`, :class:`GUnzipAction`,
1104    :class:`JavascriptMinifyAction`, :class:`XISTBytesAction`,
1105    :class:`XISTStringAction`, :class:`JoinAction`, :class:`UnpickleAction`,
1106    :class:`PickleAction`, :class:`TOXICAction`, :class:`TOXICPrettifyAction`,
1107    :class:`SplatAction`, :class:`UL4CompileAction`, :class:`UL4RenderAction`,
1108    :class:`UL4DumpAction`, :class:`UL4LoadAction`, :class:`XISTTextAction` and
1109    :class:`XISTConvertAction`. All of these actions can be executed by using
1110    :class:`CallAction` or :class:`CallAttrAction`.
1111
1112*   :class:`ll.make.PipeAction` has been renamed to :class:`TransformAction`.
1113
1114*   The new :class:`ll.make.PipeAction` pipes the input through an external
1115    command.
1116
1117*   :class:`ll.make.FileAction` now automatically wraps the :var:`key` argument
1118    into an :class:`URL` object.
1119
1120*   :class:`ll.make.FileAction` has two new methods :meth:`chmod` and
1121    :meth:`chown` that return a :class:`ModeAction` and :class:`OwnerAction`
1122    for modifying the file created by the :class:`FileAction`.
1123
1124*   :class:`ll.make.Action` has three new methods: :meth:`call`, :meth:`getattr`
1125    and :meth:`callattr` create a :class:`CallAction`, :class:`GetAttrAction`
1126    or :class:`CallAttrAction` object respectively.
1127
1128*   The division operator is no longer implemented for :class:`Action` objects
1129    in :mod:`ll.make`.
1130
1131*   Two new UL4 functions have been added: ``float`` and ``iscolor``.
1132
1133*   Two new scripts have been added: ``uls`` can be used to list any directory
1134    given as an URL. ``ucat`` can be used to output any file or directory.
1135
1136*   The script ``ucp`` now changes the user and group only if a user or group is
1137    given.
1138
1139*   A bug in the 64-bit support for :mod:`sgmlop` has been fixed.
1140
1141*   Fixed a bug in the remote :meth:`stat` method for ssh URLs (it seems that
1142    the :class:`posix.stat_result` tuple objects can no longer be pickled).
1143
1144*   There's a new function :func:`misc.itersplitat` for splitting a string at
1145    specified positions.
1146
1147*   For ssh URLs a keyword argument ``ssh_config`` is supported now instead of
1148    ``identity`` (This mirrors the corresponding change in the py__ library)
1149
1150    __ http://codespeak.net/py/dist/
1151
1152
1153Changes in 3.6.6 (released 07/09/2009)
1154--------------------------------------
1155
1156*   Fixed handling of empty pid files in :mod:`ll.sisyphus` (Fixes issue #11
1157    reported by Jarek Zgoda).
1158
1159
1160Changes in 3.6.5 (released 06/02/2009)
1161--------------------------------------
1162
1163*   Fix UL4 templates that produce no output: As the generated Python sourcecode
1164    didn't contain any ``yield`` statements, the resulting function was an
1165    ordinary function instead of a generator.
1166
1167
1168Changes in 3.6.4 (released 03/19/2009)
1169--------------------------------------
1170
1171*   A new UL4 method ``join`` has been added. It works like the Python string
1172    method join.
1173
1174*   :mod:`ll.misc` has three new functions: :func:`gzip` und :func:`gunzip` can
1175    be used for compressing and uncompressing byte strings with gzip.
1176    :func:`jsmin` can be used to minify Javascript source.
1177
1178*   Parsing an empty string with ``tidy=True`` in
1179    :func:`ll.xist.parsers.parsestring` now works again.
1180
1181
1182Changes in 3.6.3 (released 03/02/2009)
1183--------------------------------------
1184
1185*   The xfind operators ``attrhasvalue````attrhasvalue_xml``,
1186    ``attrcontains``, ``attrcontains_xml``, ``attrstartswith``,
1187    ``attrstartswith_xml``, ``attrendswith``, ``attrendswith_xml``, ``hasid``
1188    and ``hasclass`` now support multiple values. The operator matches the
1189    node if it matches with any of the given values.
1190
1191*   A new function ``reversed`` is now available in UL4 templates. It returns
1192    an iterator that will output the items of any sequence in reverse order.
1193
1194
1195Changes in 3.6.2 (released 02/16/2009)
1196--------------------------------------
1197
1198*   Inside UL4 templates rendering other templates can now be done with the new
1199    ``render`` method. This method returns the template output as a string.
1200    Passing parameters can be done via keyword arguments or with the ``**``
1201    syntax like when using the ``render`` tag.
1202
1203*   A new version of the ``int`` function has been added to UL4: When called with
1204    two arguments, the first must be a string, and the second is treated as the
1205    base for the conversion.
1206
1207
1208Changes in 3.6.1 (released 01/27/2009)
1209--------------------------------------
1210
1211*   Generating the Python source from an UL4 template is now 20-25% faster.
1212
1213*   Fixed a buffer overrun in the C portions of the url module.
1214
1215*   Added a class :class:`addattr` to :mod:`ll.xist.xsc`. This can be used
1216    to extend XML attributes via ``with`` blocks.
1217
1218*   Added the function :func:`ll.xist.ns.jsp.fromul4` which can turn an UL4
1219    template into JSP source code.
1220
1221
1222Changes in 3.6 (released 12/31/2008)
1223------------------------------------
1224
1225*   The following :class:`Color` class methods have been dropped: ``fromrgba``,
1226    ``fromrgba4``, ``fromrgba8``, ``fromint4``, ``fromint8``.
1227
1228*   The following :class:`Color` properties have been dropped: ``r4``, ``g4``,
1229    ``b4``, ``a4``, ``r8``, ``g8``, ``b8``, ``a8``, ``r``, ``g``, ``b````a``
1230    ``int4``, ``int8``, ``rgb4``, ``rgba4``, ``rgb8``, and ``rgba8``. The new
1231    methods ``r``, ``g``, ``b`` and ``a`` return the 8 bit component values.
1232
1233*   The class methods ``fromhsva`` and ``fromhlsa`` have been renamed to
1234    ``fromhsv`` and ``fromhls``.
1235
1236*   The property ``css`` has been dropped. Instead the CSS string is returned
1237    by ``__str__``.
1238
1239*   Dividing colors now does a scalar division. Blending colors is now done with
1240    the modulo operator.
1241
1242*   Support for color objects has been added to UL4.
1243
1244*   The XPIT templating language and :class:`ll.make.XPITAction` have been
1245    removed.
1246
1247*   Fixed a bug in :meth:`ll.make.CacheAction.get`: The action must return real
1248    data when called with ``bigbang`` as the timestamp.
1249
1250*   :class:`ll.make.UL4RenderAction` has been fixed.
1251
1252
1253Changes in 3.5 (released 12/05/2008)
1254------------------------------------
1255
1256*   A new function ``json`` has been added to UL4: This function returns a
1257    JSON dump of the object passed in (this requires either :mod:`simplejson`
1258    or Python 2.6).
1259
1260*   The UL4 function ``csvescape`` has been renamed to ``csv``.
1261
1262*   A new option :option:`--showregistration`/:option:`-r` has been added to
1263    make scripts.
1264
1265*   :mod:`ll.make` now supports Growl__ notifications on Mac OS X. To activate
1266    it set the ``LL_MAKE_GROWL`` environment variable to ``1`` or use the ``-g``
1267    or ``--growl`` options.
1268
1269    __ http://growl.info/
1270
1271*   :mod:`ll.make` has a new action class :class:`JavascriptMinifyAction` for
1272    minimizing Javascript source.
1273
1274*   :class:`ll.color.Color` has been rewritten to create immutable objects
1275    with the components being 8 bit values (i.e. 0-255) instead of floating
1276    point values between 0 and 1. An alpha component has been added.
1277
1278*   A ``strong`` element has been added to the :mod:`ll.xist.ns.doc`
1279    namespace.
1280
1281
1282Changes in 3.4.4 (released 09/16/2008)
1283--------------------------------------
1284
1285*   Fixed a bug in :meth:`ll.make.JoinAction.execute`.
1286
1287
1288Changes in 3.4.3 (released 09/09/2008)
1289--------------------------------------
1290
1291*   :func:`css.applystylesheets` could no longer handle style declarations
1292    containing comments. This has been fixed now.
1293
1294
1295Changes in 3.4.2 (released 09/03/2008)
1296--------------------------------------
1297
1298*   Parsing didn't work when :var:`tidy` was set to true and a :var:`base`
1299    argument was given. This has been fixed now.
1300
1301
1302Changes in 3.4.1 (released 08/29/2008)
1303--------------------------------------
1304
1305*   Bugs with thread local storage have been fixed so using :class:`xsc.Pool`,
1306    :class:`xsc.build` and URL contexts in ``with`` blocks in multithreaded
1307    applications should work now.
1308
1309
1310Changes in 3.4 (released 08/19/2008)
1311------------------------------------
1312
1313*   Templates can no longer be passed as a separate dictionary to UL4 templates
1314    but are passed as variables like other data objects too.
1315
1316*   Strings in UL4 have gained a new method ``capitalize``.
1317
1318*   Printing XML escaped strings in UL4 has now gained its own tag and opcode.
1319    ``<?printx foo?>`` is equivalent to ``<?print xmlescape(foo)?>``.
1320
1321*   Exception handling in UL4 has been rewritten to allow proper error reporting
1322    when calling nested templates.
1323
1324*   UL4 has gained a new function ``zip``. It can be called with two or three
1325    arguments and does what :func:`itertools.zip` does.
1326
1327*   UL4 has gained another new function: ``type`` returns the type of its
1328    argument as a string.
1329
1330*   UL4 now supports tuple unpacking in ``<?for?>`` tags with three variables.
1331
1332*   UL4 has a new tag for comments: ``<?note This is comment?>``.
1333
1334*   A new script ``db2ul4.py`` has been added that can render UL4 templates with
1335    database content.
1336
1337*   In UL4s ``<?render?>`` tags it's now possible to pass along a complete
1338    argument dictionary via the ``**arg`` syntax just like in Python. This syntax
1339    can even be used multiple times in the call. This syntax is available in
1340    dictionary literals too, i.e. ``{1:2, 3:4}`` and ``{**{1:2}, **{3:4}}`` are
1341    equivalent.
1342
1343*   A new UL4 function ``get`` has been added that works similar to the
1344    dictionary method ``get``, but works with global variables.
1345
1346*   The missing processing instruction :class:`render` has been added to
1347    :mod:`ll.xist.ns.ul4`.
1348
1349*   :mod:`xml_codec` now partially works, even if the C module is missing. As
1350    long as you explicitly specify an encoding on parsing and publishing it
1351    should work.
1352
1353*   A new processing instruction class :class:`ll.xist.AttrProcInst` has been
1354    introduced. When an :class:`AttrProcInst` node is the first node in an
1355    attribute, it takes over publishing of the attribute. In all other cases
1356    the processing instruction disappears completely. UL4 uses this to implement
1357    "conditional attributes" (via the new classes :class:`attr_if` and
1358    :class:`attr_ifnn`).
1359
1360*   Building trees with ``with`` blocks has changed slightly. Nodes used in
1361    ``with`` blocks and with ``+`` are now passed to a ``with`` handler instead
1362    of building the tree directly. This fixes a problem when nested
1363    :meth:`convert` calls use ``with`` blocks.
1364
1365*   The element :class:`ll.xist.ns.form.memo` has been renamed to
1366    :class:`textarea` and :class:`ll.xist.ns.form.edit` has been renamed to
1367    :class:`text`. Classes :class:`ll.xist.ns.form.button` and
1368    :class:`ll.xist.ns.form.file` have been added.
1369
1370*   Iterating through the inputs in :mod:`ll.make` actions has been fixed (i.e.
1371    the additional inputs will be output too). :meth:`ll.make.Project.findpaths`
1372    has been fixed to work with non-:class:`ll.make.Action` inputs. (This means
1373    that now you *have* to pass a real registered target action to
1374    :meth:`findpaths` not just its key).
1375
1376*   :mod:`ll.make` has gained a new action: :class:`XISTStringAction` publishes
1377    an XIST node as a unicode string. :class:`XISTPublishAction` has been renamed
1378    to :class:`XISTBytesAction`.
1379
1380*   Fixed a bug in the caching logic in :meth:`ll.make.CacheAction`.
1381
1382*   :class:`ll.make.CallMethAction` has been renamed to :class:`CallAttrAction`
1383    because it can be used to e.g. call functions in a module too.
1384
1385*   The properties ``showaction``, ``showstep`` and ``shownote`` of
1386    :class:`ll.make.Project` object can now be assigned booleans as well (which
1387    results in *all* or *no* actions being shown.
1388
1389*   The version number for :mod:`cssutils` has been bumped to 0.9.5.1.
1390
1391
1392Changes in 3.3.2 (released 07/15/2008)
1393--------------------------------------
1394
1395*   Dictionaries in UL4 have gained a new method ``get``.
1396
1397*   The version number for :mod:`cssutils` has been bumped again (to 0.9.5rc2
1398    or a later 0.9.5 version).
1399
1400*   Fixed a bug in the parsing of slice expressions in UL4.
1401
1402*   :mod:`ll.make` has gained a new :class:`UL4RenderAction` action.
1403
1404*   Fixed a bug in the formatting for the ``getslice2`` opcode for UL4.
1405
1406
1407Changes in 3.3.1 (released 07/14/2008)
1408--------------------------------------
1409
1410*   Fixed a bug in the implementation of the "not" operator in UL4.
1411
1412*   When the UL4 compiler encounters unclosed blocks, it will now include the
1413    start location of the block in the error message.
1414
1415
1416Changes in 3.3 (released 07/11/2008)
1417------------------------------------
1418
1419*   XIST has gained its fourth templating language: ``UL4`` the
1420    "Universal Layout Language". This templating language is similar in
1421    capabilities to `Djangos templating language`__. However ``UL4`` templates
1422    are compiled to a bytecode format, which makes it possible to implement
1423    template renderers in other languages and makes the template code "secure"
1424    (i.e.template code can't open or delete files).
1425
1426    __ http://www.djangoproject.com/documentation/templates/
1427
1428*   :mod:`ll.make` has gained new actions: :class:`GZipAction`,
1429    :class:`GUnzipAction`, :class:`CallFuncAction`:class:`CallMethAction`,
1430    :class:`UL4CompileAction`, :class:`UL4DumpAction` and :class:`UL4LoadAction`.
1431
1432*   The version number for :mod:`cssutils` has been bumped to 0.9.5rc1.
1433
1434*   Nodes of type :class:`ll.xist.xsc.Comment` and :class:`ll.xist.xsc.DocType`
1435    inside of attributes are now simply ignored when publishing instead of
1436    generating an exception.
1437
1438*   All actions in :mod:`ll.make` no longer check whether their inputs are
1439    action objects. Non-action objects are simply treated as ancient input data.
1440    This also means that most action classes have an :var:`input` parameter in
1441    their constructor again, as this input could now be a constant.
1442
1443*   Most attributes of action objects in :mod:`ll.make` can now be action objects
1444    themselves, so for example the name of the encoding to be used in an
1445    :class:`EncodeAction` can be the output of another action.
1446
1447*   :class:`ll.make.ImportAction` has been dropped as now the module object can
1448    be used directly (e.g. as the input for an :class:`XISTPoolAction` object).
1449
1450*   :func:`ll.misc.xmlescape` now escapes ``'`` as ``&#39;`` for IE compatibility.
1451
1452*   Functions :func:`ll.misc.xmlescape_text` and :func:`ll.misc.xmlescape_attr`
1453    have been added that implement the functionality from XIST 3.2.5 and earlier.
1454
1455*   The default parser for XIST is expat now. To switch back to sgmlop simply
1456    pass an :class:`SGMLOPParser` object to the parsing functions::
1457
1458        >>> from ll.xist import parsers
1459        >>> node = parsers.parsestring("<a>", parser=parsers.SGMLOPParser())
1460
1461*   TOXIC has been split into a compiler module :mod:`ll.toxicc` and an XIST
1462    namespace :mod:`ll.xist.ns.toxic`. TOXIC now supports output for
1463    SQL Server. The function :func:`xml2ora` as been renamed to :func:`compile`
1464    (and has a new :var:`mode` argument for specifying the database type).
1465
1466*   The :var:`targetroot` parameter for :meth:`ll.make.XISTConvertAction.__init__`
1467    has been renamed to :var:`root`.
1468
1469
1470Changes in 3.2.7 (released 05/16/2008)
1471--------------------------------------
1472
1473*   Added the missing file ``_misc_include.c`` to the distribution archives.
1474
1475
1476Changes in 3.2.6 (released 05/07/2008)
1477--------------------------------------
1478
1479*   A new action class :class:`EvalAction` has been added to :mod:`ll.make`.
1480
1481*   :func:`ll.xist.helpers.escapetext` and :func:`ll.xist.helpers.escapeattr`
1482    have been merged into one function that escapes all special characters
1483    (including ``'`` and ``"``) and has been renamed/moved to
1484    :func:`ll.misc.xmlescape`.
1485
1486*   Python versions of all the functions in the module :mod:`ll.misc` have been
1487    added. Those versions will be used in case the C module is not available.
1488
1489
1490Changes in 3.2.5 (released 04/11/2008)
1491--------------------------------------
1492
1493*   A refcounting bug in the attribute parsing code of :mod:`sgmlop` has been
1494    fixed.
1495
1496*   The helper function :func:`cssescapereplace` has been removed, as it's no
1497    longer needed.
1498
1499*   Pure Python versions of :func:`helpers.excapetext` and
1500    :func:`helpers.escapeattr` have been added, in case the C module is not
1501    available.
1502
1503
1504Changes in 3.2.4 (released 04/02/2008)
1505--------------------------------------
1506
1507*   The following functions have been added to :mod:`ll.xist.css`:
1508    :func:`parsestring`, :func:`parsestream`, :func:`parsefile`, :func:`parseurl`
1509    and :func:`write`. They parse CSS resources and are similar to the XML/HTML
1510    parsing functions in that they apply the specified base URL to all URLs in
1511    the style sheet.
1512
1513*   :mod:`cssutils` 0.9.5b2 is required now.
1514
1515*   :func:`ll.xist.css.iterrules` and :func:`ll.xist.css.applystylesheets` now
1516    support specifying whether the preferred stylesheets or an alternate
1517    stylesheet group should be used.
1518
1519*   :meth:`ll.xist.xsc.ProcInst.__mul__` and
1520    :meth:`ll.xist.xsc.ProcInst.__rmul__` now return a fragment containing
1521    the node repeated a number of times instead of one processing instruction
1522    node containing repeated content.
1523
1524*   The constructor for :class:`ll.xist.parsers.ExpatParser` now takes two
1525    additional arguments:
1526
1527    :var:`xmldecl`
1528        If this is true the XML declaration will appear in the resulting XIST
1529        tree.
1530
1531    :var:`doctype`
1532        If this is true the doctype declaration will appear in the resulting
1533        XIST tree (however any internal DTD subset will be dropped).
1534
1535
1536Changes in 3.2.3 (released 03/04/2008)
1537--------------------------------------
1538
1539*   :mod:`cssutils` 0.9.5 is used now. This simplifies the implementation of
1540    :func:`css.selector`.
1541
1542*   A function :func:`ll.xist.css.geturls` has been added. This returns a list of
1543    all the URLs in a :mod:`cssutils` stylesheet.
1544
1545*   :func:`toxic.xml2ora` now treats unknown processing instructions as text.
1546    This makes it possible to e.g. output an XML header via toxic.
1547
1548*   The pseudo-elements in :mod:`ll.xist.ns.jsp` are no longer in a namespace,
1549    so they will always be published without any prefixes.
1550
1551
1552Changes in 3.2.2 (released 02/25/2008)
1553--------------------------------------
1554
1555*   A new method :meth:`replaceurls` has been added to
1556    :class:`ll.xist.xsc.StyleAttr`. With this method all URLs in a ``style``
1557    attribute can be replaced.
1558
1559*   Fixed a bug in :meth:`ll.xist.parsers.SGMLOPParser.begin`: The encoding
1560    wasn't passed properly to the XML decoder.
1561
1562*   :meth:`ll.xist.xsc.ProcInst.publish` now calls the :meth:`checkvalid`
1563    method too.
1564
1565
1566Changes in 3.2.1 (released 02/05/2008)
1567--------------------------------------
1568
1569*   It's now possible to force the publisher to output certain ``xmlns``
1570    attributes via the :var:`showxmlns` argument to the :class:`Publisher`
1571    constructor.
1572
1573
1574Changes in 3.2 (released 02/01/2008)
1575------------------------------------
1576
1577*   The core package has been moved into XIST, installing XIST now only requires
1578    *one* package.
1579
1580*   :mod:`ll.toxic` has been moved into XIST and is now available as
1581    :mod:`ll.xist.ns.toxic`.
1582
1583*   When a :class:`ll.make.XISTParseAction` object is executed the content of
1584    the pool will now be extended by the content of the pool from the
1585    :class:`XISTPoolAction` instead of being replaced.
1586
1587*   :class:`ll.make.Pool` and :class:`ll.xist.xsc.Pool` no longer use a
1588    :class:`WeakValueDictionary`, but a simple :class:`dict`. This means they
1589    can now store *any* object. A method :meth:`clear` has been added, which
1590    removes all registered objects.
1591
1592*   Fixed a bug in :func:`ll.xist.css.iterrules` that surfaced when a
1593    :var:`base` argument was given.
1594
1595*   Fixed a second bug in :func:`ll.xist.css.iterrules` where the ``href`` of a
1596    :class:`link` element wasn't applied to the URLs in the stylesheet.
1597
1598
1599Changes in 3.1 (released 01/18/2008)
1600------------------------------------
1601
1602*   Fixed the problem that the source distibution didn't include header files.
1603
1604*   If an :class:`URLAttr` attribute contains a processing instruction XIST
1605    will no longer transform the URL in any way.
1606
1607*   Fixed a parser bug where attributes were dropped when the attribute value
1608    was empty.
1609
1610*   Putting a module into a :class:`Pool` object now copies the ``xmlns``
1611    attribute too. This makes it possible to use :class:`Pool` objects as
1612    conversion targets.
1613
1614
1615Changes in 3.0 (released 01/07/2008)
1616------------------------------------
1617
1618*   Namespaces have been greatly simplified. There are no namespace modules any
1619    longer. An element class can be assigned a namespace by setting the
1620    ``xmlns`` class attribute to the namespace name. Global attributes can be
1621    assigned a namespace by setting the ``xmlns`` attribute on the attribute
1622    class itself (*not* on the :class:`Attrs` class). The classes
1623    :class:`Prefixes` and :class:`NSPool` are gone too. Instead a new class
1624    :class:`Pool` is used to specify which classes should be used for parsing.
1625
1626*   Dependency on PyXML_ has finally been dropped. XIST now uses its own XML
1627    parsing API. Two parsers are available: One based on expat_ and one based on
1628    a custom version of sgmlop_.
1629
1630    .. _PyXML: http://pyxml.sf.net/
1631    .. _expat: http://expat.sourceforge.net/
1632    .. _sgmlop: http://effbot.org/zone/sgmlop-index.htm
1633
1634*   Tree traversal has been rewritten again. XFind expressions involving
1635    multiple uses of ``//`` now work correctly. The method :meth:`walk` now
1636    doesn't yield :class:`Cursor` objects, but simple path lists (actually it's
1637    always the same list, if you want distinct lists use :meth:`walkpath`).
1638    Applying XFind expressions to nodes directly is no longer supported, you
1639    have to call :meth:`walk`, :meth:`walknode` or :meth:`walkpath` with the
1640    XFind expression instead. Many XFind operators have been renamed and/or
1641    reimplemented (see the documentation for the :mod:`xfind` module for more
1642    information).
1643
1644*   The methods :meth:`__getitem__`, :meth:`__setitem__` and :meth:`__delitem__`
1645    for :class:`Frag` and :class:`Element` now support the new walk filters, so
1646    you can do:
1647
1648    *   ``del node[html.p]`` to delete all :class:`html.p` child elements of
1649        ``node``;
1650    *   ``del node[html.p[2]]`` to delete only the third :class:`html.p`;
1651    *   ``node[xfind.hasclass("note")] = html.p("There was a note here!")`` to
1652        replace several child nodes with a new one;
1653    *   ``for c in node[xfind.empty]: print c.bytes()`` to print all empty
1654        (element) children of ``node``;
1655    *   ``del node[node[0]]`` to delete the first child node (which is silly,
1656        but illustrates that you can pass a node to get/replace/delete that
1657        node);
1658
1659*   A new module :mod:`ll.xist.css` has been added which contains CSS related
1660    functionality: The generator function :func:`iterrules` can be passed an
1661    XIST tree and it will produce all CSS rules defined in any
1662    :class:`html.link` or :class:`html.style` elements or imported by them
1663    (via the CSS rule ``@import``). This requires the :mod:`cssutils` package.
1664
1665*   The function :func:`applystylesheets` modifies the XIST tree passed in by
1666    removing all CSS (from :class:`html.link` and :class:`html.style` elements
1667    and their ``@import``\ed stylesheets) and putting the styles into ``style``
1668    attributes of the affected elements instead.
1669
1670*   The function :func:`selector` returns a tree walk filter from a CSS selector
1671    passed in as a string.
1672
1673*   Constructing trees can now be done with ``with`` blocks. Code looks like
1674    this::
1675
1676        with xsc.Frag() as node:
1677            +xml.XML()
1678            +html.DocTypeXHTML10transitional()
1679            with html.html():
1680                with html.head():
1681                    +meta.contenttype()
1682                    +html.title("Example page")
1683                with html.body():
1684                    +html.h1("Welcome to the example page")
1685                    with html.p():
1686                        +xsc.Text("This example page has a link to the ")
1687                        +html.a("Python home page", href="http://www.python.org/")
1688                        +xsc.Text(".")
1689
1690        print node.conv().bytes(encoding="us-ascii")
1691
1692    Also the function :func:`xsc.append` has been renamed to :func:`add` and
1693    supports ``with`` blocks now instead of XPython__.
1694
1695    __ http://codespeak.net/svn/user/hpk/talks/xpython-talk.txt
1696
1697*   A subset of ReST__ is supported now for docstrings when using the
1698    :mod:`ll.xist.ns.doc` module. The module attribute :attr:`__docformat__`
1699    is now honored (Set it to ``"xist"`` to get XIST docstrings).
1700
1701    __ http://docutils.sourceforge.net/rst.html
1702
1703*   Many classes in the :mod:`ll.xist.ns.doc` have been renamed to more
1704    familiar names (from HTML, XHTML 2 or ReST).
1705
1706*   The ``media`` attribute of :class:`html.link` and :class:`html.style` now
1707    has a method :meth:`hasmedia`.
1708
1709*   The node method :meth:`asBytes` has been renamed to :meth:`bytes` and
1710    :meth:`bytes` has been renamed to :meth:`iterbytes`.
1711
1712*   The node method :meth:`asString` has been renamed to :meth:`string` and a
1713    new method :meth:`iterstring` has been added.
1714
1715*   :class:`ll.xist.ns.xml.XML10` is gone now. Use :class:`ll.xist.ns.xml.XML`
1716    instead.
1717
1718*   :func:`xsc.tonode` now will raise an exception when it can't handle an
1719    argument instead of issuing a warning.
1720
1721*   A class attribute :attr:`empty` inside element classes will now no longer
1722    get converted into :attr:`model`.
1723
1724*   :class:`ll.xist.ns.doc.pyref` now copes better with decorated methods.
1725
1726*   The deprecated :class:`Element` methods :meth:`hasAttr`, :meth:`hasattr`,
1727    :meth:`isallowedattr`, :meth:`getAttr`, :meth:`getattr`,
1728    :meth:`setDefaultAttr`, :meth:`setdefaultattr`, :meth:`attrkeys`,
1729    :meth:`attrvalues`, :meth:`attritems`, :meth:`iterattrkeys`,
1730    :meth:`iterattrvalues`, :meth:`iterattritems`, :meth:`allowedattrkeys`,
1731    :meth:`allowedattrvalues`, :meth:`allowedattritems`,
1732    :meth:`iterallowedattrkeys`, :meth:`iterallowedattrvalues`,
1733    :meth:`iterallowedattritems` and :meth:`copyDefaultAttrs` have been removed.
1734    The deprecated :class:`Attrs` method :meth:`copydefaults` has been removed
1735    too.
1736
1737*   The namespace module :mod:`ll.xist.ns.cond` has been removed.
1738
1739*   When calling the function :func:`ll.xist.parsers.parseURL` the arguments
1740    :var:`headers` and :var:`data` are now passed along to the parser's method
1741    only if they are specified. This makes it possible to pass ssh URLs to
1742    :func:`ll.xist.parsers.parseURL`.
1743
1744*   The methods :meth:`withnames` and :meth:`withoutnames` have been split into
1745    two that take Python names and two that take XML names. Multiple arguments
1746    are used now (instead of one argument that must be a sequence). Passing a
1747    namespace to remove all attributes from the namespace is no longer
1748    supported.
1749
1750*   The :class:`Attrs` methods :meth:`updatenew` and :meth:`updatexisting` have
1751    been removed.
1752
1753
1754Changes in 2.15.5 (released 07/17/2007)
1755---------------------------------------
1756
1757*   The Python quotes example no longer contains the XML source or the
1758    generated HTML.
1759
1760
1761Changes in 2.15.4 (released 07/16/2007)
1762---------------------------------------
1763
1764*   The Python quotes example now always parses the file from the original URL.
1765
1766*   The Python quotes and the media example now print the result to ``stdout``.
1767
1768
1769Changes in 2.15.3 (released 07/16/2007)
1770---------------------------------------
1771
1772*   Use a consistent license (MIT) everywhere. This should make XIST Debian
1773    compatible.
1774
1775*   Change the Python quotes example, so that it works even if there's no
1776    :file:`python-quotes.xml` in the current directory.
1777
1778
1779Changes in 2.15.2 (released 01/24/2007)
1780---------------------------------------
1781
1782*   Fixed a bug in :meth:`presenters.CodePresenter.__str__`.
1783
1784*   Fixed base URL handling for tidy parsing.
1785
1786*   Updated examples.
1787
1788*   Updated :func:`xiter` and :func:`xattrs` implementations for :class:`Node`
1789    and :class:`Namespace` to conform to the newest version of IPython.
1790
1791
1792Changes in 2.15.1 (released 09/25/2006)
1793---------------------------------------
1794
1795*   Fixed a few bugs in the :mod:`sgmlop` function declarations.
1796
1797*   Readded the spacer pixel.
1798
1799
1800Changes in 2.15 (released 09/24/2006)
1801-------------------------------------
1802
1803*   XIST has been made compatible with Python 2.5: Code has been updated
1804    to use the proper C API for memory management and :pep:`353` support has
1805    been added. XIST now includes its own fixed version of :mod:`sgmlop`.
1806
1807*   The :class:`ll.xist.xsc.Attrs` methods :meth:`with` and :meth:`without` have
1808    been renamed to :meth:`withnames` and :meth:`withoutnames` for Python 2.5
1809    compatibility.
1810
1811*   :class:`ll.xist.ns.htmlspecials.pixel` no longer handles colors via
1812    different GIFs. It uses the ``background-color`` in the ``style`` attribute
1813    instead. The same change has been implemented for
1814    :class:`ll.xist.ns.htmlspecials.autopixel`. It's now possible to overwrite
1815    the default ``src`` attribute value of ``root:px/spc.gif`` either via the
1816    XML attribute or via the converter context.
1817
1818*   The node method :meth:`asText` has been made a function, moved into the
1819    :mod:`html` namespace and renamed to :func:`astext`. Furthermore elinks_ is
1820    used for plain text formatting now instead of w3m_.
1821
1822    .. _elinks: http://elinks.or.cz/
1823    .. _w3m: http://w3m.sf.net/
1824
1825
1826Changes in 2.14.2 (released 07/04/2006)
1827---------------------------------------
1828
1829*   Fixed a bug in the :meth:`presentAttr` method of
1830    :class:`ll.xist.presenters.TreePresenter`.
1831
1832
1833Changes in 2.14.1 (released 06/29/2006)
1834---------------------------------------
1835
1836*   Fixed a bug in the :meth:`presentEntity` method of
1837    :class:`ll.xist.presenters.CodePresenter`.
1838
1839*   Updated installation instructions.
1840
1841
1842Changes in 2.14 (released 06/28/2006)
1843-------------------------------------
1844
1845*   Namespaces for RSS 0.91, RSS 2.0 and Atom 1.0 have been added.
1846
1847*   A new namespace :mod:`ll.xist.ns.detox` has been added that is similar to
1848    :mod:`ll.toxic` but can be used to generate Python code instead of
1849    PL/SQL code. Using :mod:`detox` templates is about 50 times faster than
1850    using XIST trees directly and about 10 times faster than Kid__.
1851
1852    __ http://kid.lesscode.org/
1853
1854*   Presenters are now compatible to IPython__ :mod:`ipipe` module. This means
1855    that you can browse XIST trees interactively if you have IPython installed.
1856    :class:`NormalPresenter` and the :class:`Node` methods :meth:`repr` and
1857    :meth:`asrepr` have been removed.
1858
1859    __ http://ipython.scipy.org/
1860
1861*   A new processing instruction :class:`ll.xist.ns.specials.url` has been added
1862    that does the same URL transformation as :class:`ll.xist.xsc.URLAttr` does.
1863
1864*   On publishing :class:`ll.xist.ns.html.html` now only adds a ``lang`` and
1865    ``xml:lang`` attribute, if neither of them exists.
1866
1867*   :mod:`setuptools` is now supported for installation.
1868
1869
1870Changes in 2.13 (released 10/31/2005)
1871-------------------------------------
1872
1873*   :meth:`ll.xist.xsc.Namespace.tokenize` requires a :class:`unicode` object
1874    as input now. This makes it possible to use encodings that are not ASCII
1875    compatible (such as UTF-16). The :var:`encoding` argument is gone.
1876
1877*   :meth:`ll.xist.xsc.Node.asString` uses the :var:`encoding` argument to
1878    determine which characters have to be output as character references
1879    now. (You'll still get a unicode object as the result.)
1880
1881*   A new processing instruction class :class:`ll.xist.ns.specials.literal` has
1882    been added, that will output its content literally when published. This can
1883    be used for embedding preformatted XML (e.g. from a database) into an XIST
1884    tree.
1885
1886
1887Changes in 2.12 (released 10/13/2005)
1888-------------------------------------
1889
1890*   Namespaces for `Relax NG`_ and Kid_ have been added.
1891
1892    .. _Relax NG: http://www.relaxng.org/
1893    .. _Kid: http://kid.lesscode.org/
1894
1895*   XIST requires version 1.0 of the core package now.
1896
1897*   The class name for the DocBook DTD class has been fixed.
1898
1899
1900Changes in 2.11 (released 07/29/2005)
1901-------------------------------------
1902
1903*   A script :file:`xml2xsc.py` has been added, that can be used to parse an
1904    XML file and generate a rudimentary XIST namespace from it.
1905
1906*   A :class:`DocType` for XHTML 1.1 has been added (suggested by Elvelind
1907    Grandin).
1908
1909*   Line number information is now added when parsing HTML.
1910
1911*   The :meth:`sorted` method now supports the same arguments (:var:`cmp`,
1912    :var:`key` and :var:`reverse`) as :meth:`list.sort` and :func:`sorted`
1913    in Python 2.4.
1914
1915*   The :meth:`walk` doesn't yield the node directly, but yields a :class:`Cursor`
1916    object now, with has several ways of referencing the node.
1917
1918*   New methods :meth:`walknode`, :meth:`walkpath` and :meth:`walkindex` have
1919    been added.
1920
1921*   Presenters use an iterator API instead of a stream API now. Dumping an
1922    XML tree presentation to the terminal can now start immediately instead
1923    of having to wait for the complete string to be formatted.
1924
1925*   Fixed a bug with element/attribute names that contained a ``.`` character.
1926    (This broke :mod:`ll.xist.ns.fo`.)
1927
1928*   Fixed a bug with ``xmlns`` attributes in nested elements. When an element
1929    ended the parser restored the wrong prefix mapping.
1930
1931*   The :dir:`python-quotes` demo has been updated to use the current version of
1932    AMK's XML file.
1933
1934*   Removed iterator stuff from :mod:`ll.xist.xfind`, as this is now part of the
1935    :mod:`ll` package/module.
1936
1937*   The function :func:`ToNode` has been renamed to :func:`tonode`.
1938
1939*   :class:`ll.xist.Context` no longer subclasses :class:`list`.
1940
1941*   :class:`ll.xist.ns.doc.explain` will now try to output the objects in the
1942    order in which they appear in the Python source.
1943
1944*   The node methods :meth:`find` and :meth:`findfirst` have been removed.
1945
1946*   :mod:`ll.xist.ns.cond` now uses a sandbox dictionary in a converter context
1947    for evaluating expression.
1948
1949
1950Changes in 2.10 (released 05/20/2005)
1951-------------------------------------
1952
1953*   The content of the processing instruction :class:`ll.xist.ns.code.pyexec`
1954    will not be executed at construction time, but at conversion time. The code
1955    in :class:`ll.xist.ns.code.pyexec` or :class:`ll.xist.ns.code.pyeval` will
1956    no longer be executed in the :mod:`ll.xist.sandbox` module (which has been
1957    removed), but in a sandbox dictionary in the converter context of the
1958    :mod:`ll.xist.ns.code` namespace.
1959
1960*   The tests have been ported to `py.test`_.
1961
1962    .. _py.test: http://codespeak.net/py/current/doc/test.html
1963
1964*   The method :meth:`mapped` is now callable without arguments. In this case a
1965    converter will be created on the fly. You can pass constructor arguments for
1966    this converter to :meth:`mapped` as keyword arguments.
1967
1968*   The publishing API has changed again:
1969    :meth:`ll.xist.publishers.Publisher.publish` no longer accepts an argument
1970    :var:`stream` to which the byte strings are written, but it is a generator
1971    now. The publisher methods :meth:`write` and :meth:`writetext` have been
1972    renamed to :meth:`encode` and :meth:`encodetext` and return the encoded
1973    byte string, instead of writing it directly to the stream. There's a new
1974    generator method :meth:`bytes` for nodes now, which can be passed the same
1975    arguments as :meth:`asBytes`. These changes should help when using XIST in
1976    WSGI applications.
1977
1978*   The iterator returned from :meth:`Element.__getitem__`,
1979    :meth:`Frag.__getitem__` and the :meth:`walk` method now supports
1980    :meth:`__getitem__` itself, so you can write ``table[html.tr][0]`` to get
1981    the first row from a table or ``page.walk(xsc.FindTypeAll(html.td))[-1]``
1982    to get the last table cell from a complete HTML page.
1983
1984*   Several bugs in the namespaces :mod:`ll.xist.ns.meta`, :mod:`ll.xist.ns.form`
1985    and :mod:`ll.xist.ns.specials` have been fixed.
1986
1987*   The namespace modules :mod:`ll.xist.ns.css` and :mod:`ll.xist.ns.cssspecials`
1988    have been removed.
1989
1990
1991Changes in 2.9 (released 04/21/2005)
1992------------------------------------
1993
1994*   XIST trees can now be pickled. The only restriction is that global
1995    attributes must come from a namespace that has been turned into a module via
1996    :meth:`makemod`, so that this module can be imported on unpickling.
1997
1998*   Two arguments of the :meth:`walk` method have been renamed: :var:`filtermode`
1999    has been renamed to :var:`inmode` and :var:`walkmode` has been renamed to
2000    :var:`outmode`. For these modes two new values are supported:
2001
2002    :const:`ll.xist.xsc.walkindex`
2003        The value passed to the filter function or yielded from the iterator is
2004        a list containing child indizes and attribute names that specify the path
2005        to the node in question.
2006
2007    :const:`ll.xist.xsc.walkrootindex`
2008        The filter function will be called with two arguments: The first is the
2009        root node of the tree (i.e. the node for which :meth:`walk` has been
2010        called), the second one is an index path (just like for
2011        ``ll.xist.xsc.walkindex``). If used as an :var:`outmode` a tuple with
2012        these two values will be yielded.
2013
2014* Attribute mappings now support :meth:`__getitem__`, :meth:`__setitem__` and
2015    :meth:`__delitem__` with list arguments, i.e. you can do::
2016
2017        >>> from ll.xist.ns import html
2018        >>> e = html.a("gurk", href=("hinz", "kunz"))
2019        >>> print e.attrs[["href", 0]]
2020        hinz
2021        >>> e.attrs[["href", 0]] = "hurz"
2022        >>> print e["href"]
2023        hurzkunz
2024        >>> del e.attrs[["href", 0]]
2025        >>> print e["href"]
2026        kunz
2027
2028    XML attributes can now be accessed as Python attributes, i.e.::
2029
2030        >>> from ll.xist.ns import html
2031        >>> e = html.a("spam", href="eggs")
2032        >>> print e.attrs.href
2033        eggs
2034
2035    (Don't confuse this with ``e.Attrs.href`` which is the attribute class.)
2036
2037*   :class:`Frag` and :class:`Element` now support :class:`Node` subclasses as
2038    arguments to their :meth:`__getitem__` method: An iterator for all children
2039    of the specified type will be returned.
2040
2041*   The encoding used for parsing now defaults to :const:`None`. When reading
2042    from an URL and no default encoding has been specified the one from the
2043    ``Content-Type`` header will be used. If this still doesn't result in a
2044    usable encoding, ``"utf-8"`` will be used when parsing XML and
2045    ``"iso-8859-1"`` will be used when parsing broken HTML.
2046
2047*   All error and warning classes from :mod:`ll.xist.errors` have been merged
2048    into :mod:`ll.xist.xsc`. This avoids import problems with circular imports.
2049
2050*   The attributes :attr:`showLocation` and :attr:`showPath` of
2051    :class:`ll.xist.presenters.TreePresenter` have been lowercased and
2052    presenters are properly reset after they've done their job.
2053
2054*   The class attribute :attr:`xmlname` will no longer be turned into a list
2055    containing the Python and the XML name, but will be the XML name only.
2056    You can get the Python name of :class:`foo` from ``foo.__class__.__name__``.
2057
2058*   :class:`DeprecationWarning`\s for :attr:`name` and :attr:`attrHandlers` have
2059    finally been removed.
2060
2061*   Instances of :class:`ll.xist.xsc.Entity` subclasses can now be compared.
2062    :meth:`__eq__` simply checks if the objects are instances of the same class.
2063
2064
2065Changes in 2.8.1 (released 03/22/2005)
2066--------------------------------------
2067
2068*   Added a note about the package init file to the installation documentation.
2069
2070
2071Changes in 2.8 (released 01/03/2005)
2072------------------------------------
2073
2074*   XIST requires Python 2.4 now.
2075
2076*   :class:`ll.xist.ns.specials.x` has been renamed to
2077    :class:`ll.xist.ns.specials.ignore`.
2078
2079*   :func:`ll.xist.utils.findAttr` has been renamed to
2080    :func:`ll.xist.utils.findattr`.
2081
2082*   :class:`ll.xist.xfind.item` no longer handles slices.
2083
2084*   XFind has been enhanced to support item and slice operators, i.e. if
2085    ``foo`` is an XFind operator, ``foo[0]`` is an operator that will produce
2086    the first node from ``foo`` (if there is one). Negative values and slices
2087    are supported too.
2088
2089*   Operators can be chained via division: ``html.a/html.b`` is an operator
2090    that can be passed around and applied to a node.
2091
2092*   XIST requires the new core module and makes use of the new
2093    "cooperative displayhook" functionality defined there: If you install the
2094    displayhook you can tweak or replace ``ll.xist.presenters.hookpresenter``
2095    to change the output.
2096
2097
2098Changes in 2.7 (released 11/24/2004)
2099------------------------------------
2100
2101*   The transparent pixel used by :class:`ll.xist.ns.htmlspecials.pixel` has
2102    been renamed to :file:`spc.gif` to avoid problems with IE.
2103
2104*   Removed a debug print in :class:`ll.xist.xfind.Finder.__getitem__`.
2105
2106*   :mod:`ll.xist.xfind` now has a new function :func:`item`, that can be used
2107    to get a certain item or slice from an iterator. :func:`xfind.first` and
2108    :func:`xfind.last` have been changed to use :func:`xfind.item`, so you now
2109    have to pass a default value to get the old behaviour.
2110
2111*   Obsolete options in :mod:`ll.xist.options` have been removed (and
2112    :data:`reprEncoding` has been renamed to :data:`reprencoding`).
2113
2114
2115Changes in 2.6.2 (released 06/06/2005)
2116--------------------------------------
2117
2118*   Fixed a bug in :meth:`ll.xist.parsers.Parser.parse`.
2119
2120
2121Changes in 2.6.1 (released 11/02/2004)
2122--------------------------------------
2123
2124*   Fixed a bug in :meth:`ll.xist.xfind.Finder.__floordiv__`.
2125
2126*   Restricted characters as defined in `XML 1.1`__ will now be published as
2127    character references.
2128
2129    __ http://www.w3.org/TR/2004/REC-xml11-20040204/#NT-RestrictedChar
2130
2131
2132Changes in 2.6 (released 10/26/2004)
2133------------------------------------
2134
2135*   :func:`ToNode` now tries iterating through the value passed in, so it's now
2136    possible to pass iterators and generators (and generator expressions in
2137    Python 2.4) to :class:`Frag` and :class:`Element` constructors.
2138
2139*   A new API named XFind has been added for iterating through XML trees.
2140    XFind expressions look somewhat like XPath expressions but are pure Python
2141    expressions. For example finding all images inside links in an HTML page
2142    can be done like this::
2143
2144        from ll.xist import parsers, xfind
2145        from ll.xist.ns import html
2146        node = parsers.parseURL("http://www.python.org/", tidy=True)
2147        for img in node//html.a/html.img:
2148            print img["src"]
2149
2150*   The module :mod:`ll.xist.xfind` contains several operators that can be used
2151    in XFind expressions.
2152
2153*   Parsing broken HTML is now done with the HTML parser from libxml2_. The
2154    parsing functions no longer accept options for tidy, only the boolean value
2155    of the :var:`tidy` argument is used.
2156
2157    .. _libxml2: http://www.xmlsoft.org/
2158
2159*   The publishing API has been simplified: Publication can now be done with
2160    a call to :meth:`ll.xist.publishers.Publisher.publish`, passing in a
2161    :class:`ll.xist.xsc.Node`. Writing strings to the publisher output is
2162    now done with :meth:`ll.xist.publishers.Publisher.write`. The methods
2163    :meth:`beginPublication` and :meth:`endPublication` have been
2164    removed.
2165
2166*   The presentation API has been simplified in the same way: You'll get a
2167    presentation by calling: ``string = presenter.present(node)``. The methods
2168    :meth:`beginPresentation` and :meth:`endPresentation` have been removed.
2169
2170*   The parser now has the option to ignore illegal elements, attributes,
2171    processing instructions and entities. The default behaviour is to raise an
2172    exception, but this can now be reconfigured via Python's warning framework.
2173
2174*   The classmethod :meth:`tokenize` from :mod:`ll.toxic` has been moved to
2175    :class:`ll.xist.xsc.Namespace`, so it's now possible to tokenize an XML
2176    string for other processing instructions as well.
2177
2178*   A new class :class:`ll.xist.xsc.NSPool` has been added. An :class:`NSPool`
2179    contains a pool of namespaces from which the parser selects the appropriate
2180    namespace once an ``xmlns`` attribute is encountered.</item>
2181
2182*   The script :file:`xscmake.py` (which has been unmaintained for a while now)
2183    has been removed.</item>
2184
2185*   Elements :class:`hostname`, :class:`tty`, :class:`prompt` and :class:`input`
2186    were added to :mod:`ll.xist.ns.doc`.
2187
2188*   The method :meth:`ll.xist.xsc.Attrs.set` now returns the new attribute
2189    object.
2190
2191*   The :meth:`visit` method has been removed.
2192
2193*   :meth:`ll.xist.xsc.FindOld` has been removed.
2194
2195*   :class:`ll.xist.ns.xml.header` has been renamed to
2196    :class:`ll.xist.ns.xml.declaration`.
2197
2198
2199Changes in 2.5 (released 06/30/2004)
2200------------------------------------
2201
2202*   Specifying content models for elements has seen major enhancements. The
2203    boolean class attribute :attr:`empty` has been replaced by an object
2204    :attr:`model` whose :meth:`checkvalid` method will be called for validating
2205    the element content.
2206
2207*   A new module :mod:`ll.xist.sims` has been added that provides a simple
2208    schema validation. Schema violations will be reported via Pythons
2209    warning framework.
2210
2211*   All namespace modules have been updated to use :mod:`sims` information.
2212    The SVG module has been updated to SVG 1.1. The docbook module has been
2213    updated to DocBook 4.3.
2214
2215*   It's possible to switch off validation during parsing and publishing.
2216
2217*   :class:`ll.xist.xsc.Frag` and :class:`ll.xist.xsc.Element` both have a
2218    :meth:`__call__` method with the same arguments as their constructors.
2219    Those methods will append content nodes (and set attributes for
2220    :class:`ll.xist.xsc.Element`) and return :var:`self`, so they can be used
2221    when creating an object tree. This makes it possible to put the attributes
2222    close to the tag name, instead of putting them at the end after the content.
2223
2224    Instead of::
2225
2226        node = html.table(
2227            html.tr(
2228                html.td("foo"),
2229                html.td("bar"),
2230            ),
2231            html.tr(
2232                html.td("spam"),
2233                html.td("eggs")
2234            ),
2235            class_="example"
2236
2237    you can now use the following::
2238
2239        node = html.table(class_="example")(
2240            html.tr(
2241                html.td("foo"),
2242                html.td("bar"),
2243            ),
2244            html.tr(
2245                html.td("spam"),
2246                html.td("eggs")
2247            )
2248        )
2249
2250*   Experimental support for Holger Krekel's XPython_ has been added. Code
2251    might look like this::
2252
2253        from ll.xist import xsc, converters
2254        from ll.xist.ns import html, meta
2255
2256        import random
2257
2258        c = converters.Converter()
2259        <c>:
2260            <html.html()>:
2261                <html.head()>:
2262                    <meta.contenttype()>: pass
2263                    <html.title()>:
2264                        xsc.append("The title")
2265                <html.body(class_="foo")>:
2266                    <html.h1()>:
2267                        flag = random.choice((0, 1))
2268                        if flag:
2269                            xsc.append("The foo page", class_="foo")
2270                        else:
2271                            xsc.append("The bar page", class_="bar")
2272                    <html.p()>:
2273                        if flag:
2274                            xsc.append("The foo content")
2275                        else:
2276                            xsc.append("The bar content")
2277
2278        print c.lastnode.asBytes()
2279
2280    .. _XPython: http://codespeak.net/svn/user/hpk/talks/xpython-talk.txt
2281
2282*   Creating global attributes has been simplified. Passing an instance of
2283    :class:`ll.xist.xsc.Namespace.Attrs` to an :class:`Element` constructor
2284    now does the right thing::
2285
2286        from ll.xist.ns import html, xml
2287        node = html.html(
2288            html.head(),
2289            xml.Attrs(lang="de"),
2290            lang="en",
2291        )
2292
2293*   Creating skeleton implementations of XIST namespaces is no longer done
2294    via XML conversion (i.e. the namespace module :mod:`ll.xist.ns.xndl`),
2295    but through the new module :mod:`ll.xist.xnd`. The script :file:`dtdxsc.py`
2296    will automatically generate :mod:`sims` information.
2297
2298*   :class:`ll.xist.xsc.CharRef` now inherits from :class:`ll.xist.xsc.Text`
2299    too, so you don't have to special case :class:`CharRef`\s any more. When
2300    publishing, :class:`CharRef`\s will be handled like :class:`Text` nodes.
2301
2302*   :class:`ll.xist.ns.meta.contenttype` now has an attribute ``mimetype``
2303    (defaulting to ``"text/html"``) for specifying the MIME type.
2304
2305*   :class:`ll.xist.ns.htmlspecials.caps` has been removed.
2306
2307*   Registering elements in namespace classes has been rewritten to use a
2308    cache now.
2309
2310*   Pretty printing has been changed: Whitespace will only be added now if
2311    there are no text nodes in element content.
2312
2313*   Two mailing lists are now available: One for discussion about XIST and
2314    one for XIST announcements.
2315
2316
2317Changes in 2.4.1 (released 01/05/2004)
2318--------------------------------------
2319
2320*   Changed the xmlname of :class:`ll.xist.ns.jsp.directive_page` back again
2321    (it's ``directive.page`` only for the XML form, which we don't use anyway.)
2322
2323*   Drop the default value for
2324    :class:`ll.xist.ns.jsp.directive_page.Attrs.language`, as this attribute can
2325    only be used once.
2326
2327*   If an :class:`ll.xist.xsc.Prefixes` object has a prefix mapping for a
2328    namespace it will return this prefix too, if asked for a prefix for a
2329    subclass of this namespace.
2330
2331
2332Changes in 2.4 (released 01/02/2004)
2333------------------------------------
2334
2335*   The class :class:`ll.xist.parsers.Handler` has been renamed to :class:`Parser`
2336    and has been made reusable, i.e. it is possible to instantiate a parser once
2337    and use it multiple times for parsing. All the classes derived from
2338    :class:`xml.sax.xmlreader.InputSource` have been dropped and the methods
2339    for parsing strings, URLs and files have been implemented as methods of
2340    the parser. Most of the arguments that had to be passed to the various
2341    parsing functions are passed to the parser constructor now. The basic
2342    parsing functionality is implemented by parsing streams instead of
2343    :class:`InputSource` objects.
2344
2345*   Similar to the changes for parsing, publishers have been changed to be
2346    reusable and most arguments to the publishing functions are available as
2347    arguments to the publisher constructor.
2348
2349*   Now converter contexts are no longer bound to an element class, but to the
2350    context class defined by the element class, i.e. the attribute ``Context``
2351    of the argument for :meth:`Converter.__getitem__` will be used as the
2352    dictionary key. This makes it possible to use a class and it subclasses
2353    interchangeably (as long as the base class defines its own :class:`Context`
2354    class and the subclasses don't overwrite it).
2355
2356*   Added a find functor :class:`FindTypeAllAttrs` that searches content and
2357    attributes.
2358
2359*   Fixed the XML name for :class:`ll.xist.ns.jsp.directive_page`.
2360
2361*   All character references in :mod:`ll.xist.ns.ihtml` that exist in
2362    :mod:`ll.xist.ns.chars` too have been removed.
2363
2364
2365Changes in 2.3 (released 12/08/2003)
2366------------------------------------
2367
2368*   It's now possible to parse XML without generating location information for
2369    each node, by passing ``loc=False`` to the constructor of the
2370    :class:`Handler`.
2371
2372*   The :class:`HTMLParser` no longer complains about global attributes or
2373    ``xmlns``.
2374
2375*   XIST now supports uTidylib_ in addition to mxTidy. uTidylib is found
2376    it is preferred over mxTidy.
2377
2378    .. _uTidylib: http://utidylib.sf.net/
2379
2380*   It's possible now to pass arguments to tidy simple by passing an argument
2381    dictionary for the :var:`tidy` argument in the parsing functions.
2382
2383*   The methods :meth:`parsed` and :meth:`checkvalid` have been separated.
2384
2385*   :class:`ll.xist.ns.htmlspecials.pixel` and
2386    :class:`ll.xist.ns.htmlspecials.autopixel` now check whether their
2387    :attr:`color` attribute is ok.
2388
2389*   The base URL is now set correctly when parsing from an URL even if the
2390    original URL does a redirect. (This requires :mod:`ll.url` version 0.11.3).
2391
2392*   Namespace handling has been rewritten again, to be more standards compliant:
2393    Now there is no prefixes for entities and processing instructions any longer.
2394    Prefix mappings can be created much simpler, and they no longer contain any
2395    namespace stack for parsing, as this is now done by the parser itself.
2396    :class:`xsc.NamespaceAttrMixIn` is gone too.
2397
2398*   The processing instructions :class:`exec_` and :class:`eval_` from
2399    :mod:`ll.xist.ns.code` have been renamed to :class:`pyexec` and
2400    :class:`pyeval` and :class:`import_` has been removed.
2401
2402*   :class:`CharRef`\s from :mod:`ll.xist.ns.html` have been moved to a new
2403    module named :mod:`ll.xist.ns.chars`.
2404
2405*   The method names :meth:`beginPublication`, :meth:`endPublication` and
2406    :meth:`doPublication` have been lowercased.
2407
2408
2409Changes in 2.2 (released 07/31/2003)
2410------------------------------------
2411
2412*   Namespace handling has been completely rewritten. Namespaces are now
2413    classes derived from :class:`ll.xist.xsc.Namespace`. Defining element
2414    classes can be done inside or outside the namespace class. If the element
2415    classes are defined outside the namespace class, they can be moved inside
2416    the namespace with a simple attribute assignment::
2417
2418        class foo(xsc.Element):
2419            empty = False
2420
2421        class xmlns(xsc.Namespace):
2422            xmlname = "foo"
2423            xmlurl = "http://www.foo.com/ns/foo"
2424
2425        xmlns.foo = foo
2426
2427*   The methods :meth:`elementkeys`, :meth:`iterelementkeys`,
2428    :meth:`elementvalues`, :meth:`iterelementvalues`, :meth:`elementitems` and
2429    :meth:`iterelementitems` can be used for iterating through the element
2430    classes and their names. You can use the method :meth:`element` to get an
2431    element class with a certain name::
2432
2433        >>> from ll.xist.ns import html
2434        >>> html.element("div")
2435        <element class ll.xist.ns.html/div at 0x824363c>
2436
2437*   For processing instructions, entities and character references similar
2438    methods are available.
2439
2440*   The method :meth:`update` can be used to add many element classes to a
2441    namespace at once, simply by passing a dictionary with those classes
2442    (use ``vars()`` to add everything that's defined inside your module).
2443    The method :meth:`updatenew` does the same, but copies only those
2444    attributes that don't exist in the namespace, :meth:`updateexisting`
2445    copies only those that do exist. You can turn a namespace into a module
2446    with :meth:`makemod`::
2447
2448        from ll.xist import xsc
2449
2450        class foo(xsc.Element):
2451            empty = False
2452
2453        class xmlns(xsc.Namespace):
2454            xmlname = "foo"
2455            xmlurl = "http://www.foo.com/ns/foo"
2456        xmlns.makemod(vars())
2457
2458*   Put the above code into :file:`foo.py` and you can do the following::
2459
2460        >>> import foo
2461        >>> foo
2462        <namespace foo/xmlns name=u'foo' url=u'http://www.foo.com/ns/foo' with 1 elements from 'foo.py' at 0x81bfc14>
2463
2464*   :func:`getns` has been dropped, so you always have to pass in a
2465    :class:`Namespace` class where a namespace is required.
2466
2467*   For the :class:`ll.xist.ns.jsp.directive_page` element automatic generation
2468    of the correct ``charset`` option in the ``contentType`` attribute is only
2469    done when there is a ``contentType`` attribute, as ``contentType`` is
2470    optional.
2471
2472*   The converter has a new property :func:`node`. :var:`node` can't be passed
2473    to :meth:`conv` but will be set to :var:`self` by :meth:`conv`
2474    automatically. This makes it possible to access the "document root" during
2475    conversion.
2476
2477*   :class:`ll.xist.ns.htmlspecials.autoimg` no longer touches existing width
2478    and height attributes. This means that %-formatting of the existing
2479    attributes is no longer done.
2480
2481*   Added a new class :class:`ll.xist.ns.htmlspecials.autopixel` that works
2482    like :class:`ll.xist.ns.htmlspecials.pixel` but inherits the size for the
2483    image specified via the ``src`` attribute.
2484
2485*   :class:`Frag` and :class:`Element` now support extended slices.
2486
2487*   :class:`Frag` and :class:`Element` now support the methods :meth:`extend`
2488    and :meth:`__iadd__`.
2489
2490*   For walking the tree the method :meth:`walk` has been completely rewritten
2491    and a new method :meth:`visit` has been added. For more info see the
2492    docstrings.
2493
2494*   :class:`Node` now has two new methods :meth:`copy` and :meth:`deepcopy` and
2495    supports the :mod:`copy` module from the Python standard library.
2496
2497*   Calling :meth:`mapped` through :meth:`conv` has been removed. You again
2498    have to call :meth:`mapped` directly and pass a node and a converter.
2499
2500*   The HTML handling of the :class:`HTMLParser` has been improved (it now
2501    uses code from :mod:`xml.sax.drivers2.drv_sgmlop_html` (which is part of
2502    PyXML__.
2503
2504    __ http://pyxml.sf.net/
2505
2506*   The core functionality found in the script :file:`dtd2xsc.py` has been
2507    moved to a class method :meth:`ll.xist.ns.xndl.fromdtd` in the
2508    :mod:`ll.xist.ns.xndl` namespace.
2509
2510*   :class:`ll.xist.parsers.ExpatParser` is now a real subclass instead of an
2511    alias for :class:`xml.sax.expatreader.ExpatParser` It reports unknown
2512    entity references to the application (if loading of external entities is
2513    switched off, which is done by :class:`ll.xist.parsers.Handler` and only
2514    outside of attributes).
2515
2516*   Namespaces have been added for Zope's TAL and METAL specifications.
2517
2518*   A namespace has been added for `XSL-FO`_.
2519
2520    .. _XSL-FO: http://www.w3.org/Style/XSL/
2521
2522
2523Changes in 2.1.4 (released 06/13/2003)
2524--------------------------------------
2525
2526*   Remove the checks for attributes in attributes and moved the publication
2527    code for the full element into a separate method. This allows JSP tag
2528    library namespaces to simply overwrite :meth:`publish` to publish the
2529    element even inside attributes. (This is the same fix as in release 1.5.10).
2530
2531
2532Changes in 2.1.3 (released 05/07/2003)
2533--------------------------------------
2534
2535*   The methods :meth:`sorted`, :meth:`reversed` and :meth:`shuffled` have been
2536    rewritten so they no longer use ``sys.maxint``. This change fixes those
2537    methods for 64 bit platforms (reported by Giles Frances Hall)
2538
2539
2540Changes in 2.1.2 (released 02/27/2003)
2541--------------------------------------
2542
2543*   :class:`ll.xist.ns.struts_config11.plug_in` now allows content (as the DTD
2544    states). (This is the same fix as in release 1.5.8.)
2545
2546
2547Changes in 2.1.1 (released 02/11/2003)
2548--------------------------------------
2549
2550*   Added a few elements and attributes to :mod:`ll.xist.ns.doc`:
2551    :class:`username`, which is used for the name of a user account,
2552    :class:`xref`, which is used for internal cross references and the attribute
2553    ``id`` for :class:`section`, which specifies the target for an :class:`xref`.
2554
2555
2556Changes in 2.1 (released 12/09/2002)
2557------------------------------------
2558
2559*   Added a new namespace module :mod:`ll.xist.ns.xndl` that contains the
2560    "XIST namespace definition language", i.e. elements that describe an
2561    XIST namespace and can be used by various scripts to generate skeleton
2562    namespace modules. The first of these script is the DTD to namespace
2563    converter :file:`dtd2xsc.py`.
2564
2565*   Added a new namespace module :mod:`ll.xist.ns.tld` that contains the
2566    definition for Java Server Pages Tag Library descriptors and a script
2567    :file:`tld2xsc.py` that uses this namespace to generate namespace modules
2568    from ``tld`` files.
2569
2570*   :class:`Attr` now supports the method :meth:`filtered`. This is used by
2571    :meth:`without` now. The arguments for :meth:`without` have changed,
2572    because handling global attributes was too "magic". A new method :meth:`with`
2573    has been added, with does the opposite of :meth:`without`, i.e. it removes
2574    all attributes that are not specified as parameters.
2575
2576*   The Python name of each :class:`Node` subclass is now available as the class
2577    attribute :attr:`pyname`.
2578
2579*   To continue the great renaming :meth:`withSep` has been renamed to
2580    :meth:`withsep`.
2581
2582*   The namespace name for the :mod:`ll.xist.ns.struts_html` module has been
2583    fixed.
2584
2585*   The argument :var:`defaultEncoding` for the various parsing functions has
2586    been renamed to :var:`encoding`.
2587
2588
2589Changes in 2.0.8 (released 11/20/2002)
2590--------------------------------------
2591
2592*   :func:`ll.xist.ns.doc.getDoc` has been renamed to :func:`getdoc`.
2593
2594*   The CSS parser was dropping the ``%`` from percentage values. This has
2595    been fixed.
2596
2597
2598Changes in 2.0.7 (released 11/12/2002)
2599
2600*   :meth:`xsc.Element.__nonzero__` can no longer fall back to
2601    :meth:`xsc.Frag.__nonzero__`. (this is the same fix as in 1.5.7).
2602
2603
2604Changes in 2.0.6 (released 11/11/2002)
2605--------------------------------------
2606
2607*   Performance optimizations.
2608
2609
2610Changes in 2.0.5 (released 11/11/2002)
2611--------------------------------------
2612
2613*   Fixed a bug in :class:`ll.xist.ns.specials.autoimg`: Attributes were not
2614    converted before the size check was done (this is the same fix as in 1.5.5).
2615
2616
2617Changes in 2.0.4 (released 11/08/2002)
2618--------------------------------------
2619
2620*   Fixed a regression bug in :class:`ll.xist.ns.jsp.directive` and several
2621    documentation issues.
2622
2623
2624Changes in 2.0.3 (released 10/30/2002)
2625--------------------------------------
2626
2627*   Fixed a few bugs in :class:`HTMLParser`.
2628
2629*   Added DocBook conversion for several elements in :mod:`ll.xist.ns.doc`.
2630
2631*   Now the :file:`__init__.py` file for the :mod:`ll` package is included.
2632
2633
2634Changes in 2.0.2 (released 10/21/2002)
2635--------------------------------------
2636
2637*   Fixed a bug in :meth:`Frag.__rmul__` (by reusing :meth:`__mul__`).
2638
2639*   Fixed a bug with the backwards compatible prefix mapping: Defining element
2640    classes in ``exec`` processing instructions didn't work, because the
2641    prefixes object used for parsing wouldn't be updated when the namespace
2642    object is defined inside the processing instruction. Now using the default
2643    for the :var:`prefixes` argument in calls to the parsing functions uses one
2644    global shared :class:`Prefixes` instances where all the namespaces that are
2645    newly defined will be registered too.
2646
2647
2648Changes in 2.0.1 (released 10/17/2002)
2649--------------------------------------
2650
2651*   Fixed :file:`xscmake.py` by removing the prefix handling.
2652    :class:`OldPrefixes` will always be used for parsing now.
2653
2654
2655Changes in 2.0 (released 10/16/2002)
2656------------------------------------
2657
2658*   XIST now requires at least Python 2.2.1.
2659
2660*   Attribute handling has been largely rewritten. Instead of a class attribute
2661    :attr:`attrHandlers`, the attributes are now defined through a nested class
2662    named :class:`Attrs` inside the element. This class must be derived from
2663    :class:`ll.xist.Element.Attrs` (or one of its subclasses if you want to
2664    inherit attributes from this class). Defining attributes is done through
2665    classes nested inside this attributes class and derived from any of the
2666    known attribute classes (like :class:`TextAttr`, :class:`URLAttr` etc.).
2667    The class name will be the attribute name (and can be overwritten with a
2668    class attribute :attr:`xmlname`. This makes it possible to have docstrings
2669    for attributes. Furthermore it's possible to define an attribute default
2670    value via the class attribute :attr:`default`, allowed values for the
2671    attribute via :attr:`values`, which is a list of allowed values, and
2672    whether the attribute is required or not via :attr:`required`.
2673
2674*   XIST now has real namespace support. The new class
2675    :class:`ll.xist.xsc.Prefixes` can be used to define a mapping between
2676    prefixes and namespace names. This can be used for parsing and publishing.
2677    Namespace support is even available for entities and processing instruction.
2678
2679*   Global attributes are supported now. Namespace modules for the ``xml`` and
2680    ``xlink`` namespaces have been added (and :class:`ll.xist.xsc.XML` was
2681    moved to :mod:`ll.xist.ns.xml`).
2682
2683*   A new namespace module for SVG 1.0 has been added: :mod:`ll.xist.ns.svg`.
2684
2685*   The HTML specific parts of :mod:`ll.xist.ns.specials` have been split off
2686    into a separate module :mod:`ll.xist.ns.htmlspecials`.
2687
2688*   Comparison of attributes with strings has been removed. You have to use
2689    :meth:`__unicode__` or :meth:`__str__` now before comparing.
2690
2691*   The :class:`HTMLParser` now removes unknown attributes instead of
2692    complaining.
2693
2694*   There is a new parser class :class:`BadEntityParser`, which is a SAX2
2695    parser that recognizes the character entities defined in HTML and tries to
2696    pass on unknown or malformed entities to the handler literally.
2697
2698*   To give all nodes a chance to do something after they have been parsed (e.g.
2699    to prepend the base URL for :class:`URLAttr` nodes), the parser now calls
2700    the method :meth:`parsed` immediately after node creation. This is used for
2701    the new class :class:`StyleAttr`, which uses the :class:`CSSTokenizer`, to
2702    prepend the base URL to all URLs found in a style attribute.
2703
2704*   The pixel images have been moved to the directory :dir:`px` to make image
2705    URLs shorter.
2706
2707
2708Changes in 1.6.1 (released 08/25/2003)
2709--------------------------------------
2710
2711*   Updated to work with newer versions of :mod:`ll.ansistyle`.
2712
2713*   Updated the namespaces :mod:`ll.xist.ns.struts_html` and
2714    :mod:`ll.xist.ns.struts_config11` to the state of Struts 1.1 final.
2715
2716
2717Changes in 1.6 (released 07/02/2003)
2718------------------------------------
2719
2720*   Removed the default value for the ``className`` attribute in
2721    :class:`ll.xist.ns.struts_config11.action`.
2722
2723*   Added an attribute ``type`` to
2724    :class:`ll.xist.ns.struts_config11.action_mapping`.
2725
2726
2727Changes in 1.5.13 (released 07/01/2003)
2728---------------------------------------
2729
2730*   Implemented :meth:`ll.xist.xsc.Namespace.__eq__`, so that replacing a
2731    namespace in the registry really works.
2732
2733*   Added an attribute ``target`` to :class:`ll.xist.ns.html.area`.
2734
2735
2736Changes in 1.5.12 (released 06/17/2003)
2737---------------------------------------
2738
2739*   Fixed a bug in the new :mod:`ll.xist.ns.jsp`.
2740
2741
2742Changes in 1.5.11 (released 06/13/2003)
2743---------------------------------------
2744
2745*   Updated :mod:`ll.xist.ns.jsp` to JSP 1.2.
2746
2747
2748Changes in 1.5.10 (released 06/13/2003)
2749---------------------------------------
2750
2751*   Remove the checks for attributes in attributes and moved the publication
2752    code for the full element into a separate method. This allows JSP tag
2753    library namespaces to simply overwrite :meth:`publish` to publish the
2754    element even inside attributes.
2755
2756
2757Changes in 1.5.9 (released 04/30/2003)
2758--------------------------------------
2759
2760*   Reregistering a namespace now properly overwrites the old version in
2761    ``xsc.namespaceRegistry``.
2762
2763
2764Changes in 1.5.8 (released 02/27/2003)
2765--------------------------------------
2766
2767*   :class:`ll.xist.ns.struts_config11.plug_in` now allows content (as the
2768    DTD states).
2769
2770
2771Changes in 1.5.7 (released 11/12/2002)
2772--------------------------------------
2773
2774*   :meth:`xsc.Element.__nonzero__` can no longer fall back to
2775    :meth:`xsc.Frag.__nonzero__`.
2776
2777
2778Changes in 1.5.6 (released 11/11/2002)
2779--------------------------------------
2780
2781*   Performance optimizations.
2782
2783
2784Changes in 1.5.5 (released 11/11/2002)
2785--------------------------------------
2786
2787*   Fixed a bug in :class:`ll.xist.ns.specials.autoimg`: Attributes were not
2788    converted before the size check was done.
2789
2790
2791Changes in 1.5.4 (released 09/30/2002)
2792--------------------------------------
2793
2794*   :file:`xscmake.py` now tries to strip off a trailing ``xsc`` from the
2795    filename before it falls back to the extension ``html`` (The builtin
2796    extension mapping is still tried first).
2797
2798
2799Changes in 1.5.3 (released 09/25/2002)
2800--------------------------------------
2801
2802*   Added new processing instruction class :class:`ll.xist.ns.php.expression`
2803    that generates a PHP ``print`` statement from its content.
2804
2805
2806Changes in 1.5.2 (released 09/19/2002)
2807--------------------------------------
2808
2809*   Removed the ``value`` magic from :class:`ll.xist.ns.form.checkbox` as this
2810    conflicted with dynamic ``value`` values.
2811
2812
2813Changes in 1.5.1 (released 09/17/2002)
2814--------------------------------------
2815
2816*   Comparison of attributes with strings has been removed. You have to use
2817    :meth:`__unicode__` or :meth:`__str__` instead.
2818
2819*   The :class:`HTMLParser` now removes unknown attributes instead of
2820    complaining.
2821
2822*   There is a new parser class :class:`BadEntityParser`, which is a SAX2
2823    parser that recognizes the character entities defined in HTML and tries to
2824    pass on unknown or malformed entities to the handler literally.
2825
2826*   To give all nodes a chance to do something after they have been parsed (e.g.
2827    to prepend the base URL for :class:`URLAttr` nodes), the parser now calls
2828    the method :meth:`parsed()` immediately after node creation. This is used
2829    for the new class :class:`StyleAttr`, which uses the :class:`CSSTokenizer`,
2830    to prepend the base url to all urls found in a style attribute.
2831
2832*   The :class:`HTMLParser` now removes unknown attributes instead of
2833    complaining.
2834
2835*   There is a new parser class :class:`BadEntityParser`, which is a SAX2
2836    parser that recognizes the character entities defined in HTML and tries to
2837    pass on unknown or malformed entities to the handler literally.
2838
2839*   To give all nodes a chance to do something after they have been parsed (e.g.
2840    to prepend the base URL for :class:`URLAttr` nodes), the parser now calls
2841    the method :meth:`parsed` immediately after node creation. This is used for
2842    the new class :class:`StyleAttr`, which uses the :class:`CSSTokenizer`, to
2843    prepend to base URL to all URLs found in a style attribute.
2844
2845
2846Changes in 1.4.3 (released 04/29/2002)
2847--------------------------------------
2848
2849*   New namespace module :mod:`xist.ns.struts_config11` allows to parse and
2850    modify Struts_ configuration files conforming to the `Struts 1.1 DTD`_.
2851
2852    .. _Struts: http://jakarta.apache.org/struts/
2853    .. _Struts 1.1 DTD: http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd
2854
2855
2856Changes in 1.4.2 (released 03/22/2002)
2857--------------------------------------
2858
2859*   Updated :file:`xscmake.py` to be compatible with the new :mod:`url` module.
2860
2861*   :class:`xist.ns.jsp.directive_page` now automatically sets the
2862    ``contentType`` on publishing.
2863
2864
2865Changes in 1.4.1 (released 03/21/2002)
2866--------------------------------------
2867
2868*   Removed :class:`TidyURLInputSource`. Now it's possible to pass a :var:`tidy`
2869    flag to the remaining functions :func:`parseString`, :func:`parseFile` and
2870    :func:`parseURL` to specify whether the source should be tidied.
2871
2872*   To prevent an element from being registered in a :class:`Namespace` the
2873    class attribute :attr:`register` can be used now. This makes it possible
2874    to have a name for the element even when it's not registered.
2875
2876*   :mod:`xist.ns.form` elements now have all the attributes that the
2877    corresponding elements from :mod:`xist.ns.html` have.
2878
2879*   Removed the old :mod:`xist.url` from the Windows distribution.
2880
2881
2882Changes in 1.4 (released 03/18/2002)
2883------------------------------------
2884
2885*   Reimplemented URL handling again. Now the new global module :mod:`url` is
2886    used for that.
2887
2888
2889Changes in 1.3.1 (released 03/14/2002)
2890--------------------------------------
2891
2892*   Added a method :meth:`pretty` to :class:`Node` for generating a pretty
2893    printable version of the node.
2894
2895*   ``xsc.Node.name`` no longer is a class method, but a class attribute, that
2896    will be set at class instantiation time by the meta class.
2897
2898
2899Changes in 1.3 (released 02/12/2002)
2900------------------------------------
2901
2902*   Ported to Python 2.2. :class:`Node` is now derived from :class:`object`,
2903    :class:`Frag` from :class:`list` and there's a new class :class:`Attrs`
2904    which is derived from :class:`dict` for the attribute mappings. All
2905    presenters have been adapted to work with :class:`Attrs`. In addition to
2906    the usual dictionary methods and operators :class:`Attrs` has a
2907    method :meth:`without` that returns a copy of the :class:`Attrs` instance
2908    with some specified attributes removed.
2909
2910*   All the node classes now have a new method :meth:`walk` that generates all
2911    nodes in the tree using the new generator feature of Python 2.2.
2912
2913*   Also a new method :meth:`walkPath` has been added that works the same as
2914    :meth:`walk` but yields the complete path to each node as a list.
2915
2916*   Added a class :class:`block` to :mod:`xist.ns.jsp`. The content of the
2917    :class:`block` instance will simply be enclosed in a ``{}`` block.
2918    :mod:`xist.ns.php` got such a class too.
2919
2920*   Added a new module :mod:`xist.ns.ihtml` for i-mode HTML.
2921
2922*   Added new modules :mod:`xist.ns.css` and :mod:`xist.ns.cssspecials` for
2923    generating CSS.
2924
2925*   Now the various attributes of the :class:`Converter` object are collected in
2926    a :class:`ConverterState` object and it's possible to push and pop those
2927    states, i.e. it's now easy to temporarily modify a converter object during
2928    a :meth:`convert` call and revert back to a previous state afterwards.
2929
2930*   :func:`parseURL` and :func:`parseTidyURL` now have an additional parameter
2931    :var:`headers` which is a list of string pairs specifying additional
2932    headers to be passed in with the request.
2933
2934*   :func:`parseString` has an additional parameter :var:`systemId` which will
2935    be the system id of the :class:`InputSource`.
2936
2937*   The distribution now includes the makefile and the XML source files so now
2938    the distribution can rebuild ifself.
2939
2940*   Various other small bugfixes and enhancements.
2941
2942
2943Changes in 1.2.5 (released 12/03/2001)
2944--------------------------------------
2945
2946*   Added a new element :class:`contentscripttype` to :mod:`xist.ns.meta` that
2947    generates a ``<meta http-equiv="Content-Script-Type" ...>`` element.
2948
2949*   :func:`xist.ns.doc.explain` now generates anchor elements for the class,
2950    function and method description, so now the links on the XIST webpages
2951    work.
2952
2953*   Docstrings and documentation has been reworked. Now :class:`xist.ns.doc.pyref`
2954    no longer implies a font change. Use the classes :class:`xist.ns.doc.module`,
2955    :class:`xist.ns.doc.class`, :class:`xist.ns.doc.method`,
2956    :class:`xist.ns.doc.function` and :class:`xist.ns.doc.arg` to mark up your
2957    Python identifiers.
2958
2959*   Added the attributes ``type`` and ``key`` to
2960    :class:`xist.ns.struts_config.data_source`.
2961
2962
2963Changes in 1.2.4 (released 11/23/2001)
2964--------------------------------------
2965
2966*   Added the deprecated attributes ``start`` to :class:`xist.ns.html.ol` and
2967    ``value`` to :class:`xist.ns.html.li`.
2968
2969
2970Changes in 1.2.3 (released 11/22/2001)
2971--------------------------------------
2972
2973*   Added missing :meth:`asPlainString` methods to :class:`Comment` and
2974    :class:`DocType`.
2975
2976
2977Changes in 1.2.2 (released 11/16/2001)
2978--------------------------------------
2979
2980*   :meth:`xist.url.URL.fileSize` and :meth:`xist.url.URL.imageSize` now use
2981    the warning framework to report errors.
2982
2983*   There is a new presenter named :class:`CodePresenter` that dumps the tree
2984    as Python source code.
2985
2986*   The filenames of the pixel images used by :class:`xist.ns.specials.pixel`
2987    have changed. These images are now included.
2988
2989
2990Changes in 1.2.1 (released 10/08/2001)
2991--------------------------------------
2992
2993*   URLs that are completely dynamic will now be left in peace when parsing or
2994    publishing.
2995
2996
2997Changes in 1.2 (released 10/03/2001)
2998------------------------------------
2999
3000*   :class:`xist.ns.meta.keywords` and :class:`xist.ns.meta.description` no
3001    longer call :meth:`asPlainString` on their content. This makes it possible
3002    to e.g. generate the keywords via JSP::
3003
3004        >>> from xist import parsers
3005        >>> from xist.ns import meta, jsp
3006        >>> s = '<keywords>' + \
3007        ...     '<?jsp:expression "foo"?>' + \
3008        ...     '</keywords>'
3009        >>> e = parsers.parseString(s)
3010        >>> print e.conv().asBytes()
3011        <meta name="keywords" content="<%= "foo" %>" />
3012
3013*   When an element occurs inside an attribute during publishing, there won't
3014    be an exception raised any more. Instead the content of the element will be
3015    published. This fixes problems with abbreviation entities inside attributes.
3016
3017*   :class:`xist.parsers.TidyURLInputSource` now uses the new experimental
3018    eGenix mx Extension package, which includes a Python port of tidy.
3019
3020*   :meth:`__repr__` now uses the new class :class:`presenters.PlainPresenter`
3021    which gives a little more info than the default :meth:`__repr__`.
3022
3023*   URL handling has been changed again. Upto now, :class:`URLAttr` had an
3024    additional instance attribute ``base``, which was the "base" file/URL from
3025    which the attribute was parsed. Now the base URL will be directly
3026    incorporated into the URL. You can pass the base URL to all the parsing
3027    functions. Similar to that when publishing you can specify a base URL. All
3028    URLs in the tree will be output relative to this base URL. Joining URLs is
3029    now done via :meth:`__div__` and no longer via :meth:`__add__`. This makes
3030    it more consistent with :mod:`fileutils`. The plan is to make URLs string
3031    like immutable objects and to merge them with :class:`fileutils.Filename`.
3032
3033*   :class:`xist.ns.specials.php` has been moved to its own module
3034    (:mod:`xist.ns.php`). This module provided additional convenience
3035    processing instructions (just like :mod:`xist.ns.jsp` does).
3036
3037
3038Changes in 1.1.3 (released 09/17/2001)
3039--------------------------------------
3040
3041*   The global namespace registry now keeps a sequential list of all registered
3042    namespaces, which will be used by the parser when searching for names. This
3043    gives a predictable search order even without using :class:`Namespaces`
3044    and its :meth:`pushNamespace` method: modules imported last will be searched
3045    first.
3046
3047*   Processing instructions are now allowed inside attributes when publishing.
3048
3049*   :mod:`xist.ns.docbooklite` has been renamed to :mod:`xist.ns.doc`. It can
3050    now generate HTML and Docbook output and has improved a lot. The XIST
3051    web pages now use this for automatic documentation generation. The doc
3052    example has been removed.
3053
3054*   :class:`xist.url.URL` now has a new method :meth:`info` that returns the
3055    headers for the file/URL.
3056
3057*   :class:`xist.url.URL` now has a methods :meth:`fileSize` and
3058    :meth:`imageSize` too.
3059
3060*   :class:`xist.ns.jsp.directive_page` now has new attribute ``session``.
3061
3062
3063Changes in 1.1.2 (released 08/21/2001)
3064--------------------------------------
3065
3066*   :meth:`__repr__` now uses the new class :class:`presenters.PlainPresenter`
3067    which gives a little more info than the default :meth:`__repr__`.
3068
3069
3070Changes in 1.1.1 (released 08/01/2001)
3071--------------------------------------
3072
3073*   Small bugfix in :func:`presenters.strProcInst`.
3074*   Fixed :class:`xist.ns.struts_html.option` to allow content.
3075
3076
3077Changes in 1.1 (released 07/19/2001)
3078------------------------------------
3079
3080*   Sequences in constructor arguments for :class:`Frag` and :class:`Element`
3081    are again expanded and it's again possible to pass dictionaries in an
3082    :class:`Element` constructor to specify attributes. As sequences are always
3083    unpacked, the method :meth:`extend` is gone. This works for :meth:`append`
3084    and :meth:`insert` too.
3085
3086*   :class:`Node` and :class:`Frag` implement :meth:`__mul__` and
3087    :meth:`__rmul__`, so you can do stuff like::
3088
3089        html.br()*5
3090
3091    This returns a :class:`Frag` with five times to same node.
3092
3093*   Arguments for the converter constructor can be passed to
3094    :meth:`xist.xsc.Node.conv` now, so it's possible to do stuff like this::
3095
3096        from xist.ns import code
3097        print code.Eval("return converter.lang").conv(lang="en").asBytes()
3098
3099    which will print ``en``.
3100
3101*   The option :var:`XHTML` for the publishers has been changed to lowercase.
3102
3103*   :class:`xist.ns.html.html` will automatically generate a ``lang`` and
3104    ``xml:lang`` attribute when the converter has a language set.
3105
3106
3107Changes in 1.0 (released 06/18/2001)
3108------------------------------------
3109
3110*   New module for WML 1.3.
3111
3112*   The publishing interface has changed internally and publishing should be
3113    faster now.
3114
3115*   Publishers now support a new parameter: :var:`usePrefix`, which specifies
3116    if namespace prefixes should be output for the element names.
3117
3118*   Part of the implementation of the publishing stuff has been moved to C, so
3119    now you'll need a C compiler to install XIST.
3120
3121*   When publishing ``"``, it will now only be replaced with ``&quot;`` inside
3122    attributes.
3123
3124*   All the :meth:`asHTML` methods now have an additional argument
3125    :var:`converter`. This makes it possible to implement different processing
3126    modes or stages for new elements. All currently implemented elements and
3127    entities ignore this argument, but pass it on in the call to their
3128    childrens' :meth:`asHTML` method. As the name :meth:`asHTML` no longer
3129    makes sense, :meth:`asHTML` has been renamed to :meth:`convert`.
3130
3131*   There is now a tool :file:`dtd2xsc.py` in the :dir:`scripts` directory that
3132    creates a skeleton XIST module from a DTD (this requires xmlproc from the
3133    PyXML package).
3134
3135*   New preliminary module for DocBook 4.12. (Incomplete: :meth:`convert`
3136    methods and Unicode character entities are missing; any volunteers for
3137    implementing 375 classes?)
3138
3139*   New module :file:`ruby.py` that implements the `W3C Ruby draft`_.
3140
3141    .. _W3C Ruby draft: http://www.w3.org/TR/ruby/xhtml11-ruby-1.mod
3142
3143*   :file:`sql.py` has been removed from XIST, but is available as a
3144    separate module.
3145
3146*   The parsing interface has been changed. Parsing is now done with the
3147    functions :func:`parseFile`, :func:`parseString`, :func:`parseURL` and
3148    :func:`parseTidyURL` in the module :mod:`parsers`. It's now possible to
3149    specify which parser should be used for parsing by passing a SAX2 parser
3150    instance to any of these functions. XIST now includes a rudimentary
3151    SAX2 driver for :class:`sgmlop` and a rudimentary HTML parser that
3152    emits SAX2 events.
3153
3154*   The python-quotes example has been updated to work with expat.
3155
3156*   Added a new example: media.
3157
3158*   All abbreviation entities have been moved to a new module :file:`abbr.py`.
3159
3160*   All the modules that provide new elements and entitites have been moved
3161    to a subpackage :mod:`ns`.
3162
3163*   :class:`Frag` and :class:`Element` now have new methods :meth:`sorted`,
3164    :meth:`reversed`, :meth:`filtered` and :meth:`shuffled` that return sorted,
3165    reversed, filtered and shuffled versions of the :class:`Frag`/:class:`Element`
3166    object.
3167
3168*   New namespace modules :file:`ns/jsp.py` and :file:`ns/struts_html.py` have
3169    been added that allow you to use JSP_ and Struts_ tags with XIST.
3170
3171    .. _JSP: http://java.sun.com/products/jsp/
3172    .. _Struts: http://jakarta.apache.org/struts/
3173
3174*   A new method :meth:`asText` was added, that returns the node as a formatted
3175    plain ASCII text (this requires that w3m__ is installed.)
3176
3177    __ http://w3m.sf.net/
3178
3179*   :file:`make.py` has been renamed to :file:`xscmake.py` and moved to the
3180    :dir:`scripts` directory, it will be installed as a callable script with
3181    ``python setup.py install_scripts``.
3182
3183*   :file:`xscmake.py` has a new option :option:`--files`/:option:`-f`.
3184    The argument is a file containing a list of filenames (one name per line)
3185    that should be converted.
3186
3187*   :file:`xscmake.py` has a new option :option:`--parser`/:option:`-r` for
3188    specifying which parser to use. Allowed values are ``sgmlop`` and ``expat``.
3189
3190*   :file:`xscmake.py` has a new option :option:`--namespace`/:option:`-n`
3191    that can be used for appending :class:`Namespace` objects to the
3192    :class:`Namespaces` object used by :file:`xscmake.py`::
3193
3194        xscmake.py -n html -n spam eggs.xsc
3195
3196    With this call the parser will find element classes from the module with
3197    the prefix name ``spam`` before those from ``html`` and those before
3198    anything else.
3199
3200*   :class:`xist.url.URL` no longer has an attribute :attr:`ext`. :attr:`file`
3201    and :attr:`ext` are merged.
3202
3203*   The special treatment of sequences as constructor arguments to :class:`Frag`
3204    and :class:`Element` has been removed, so XIST will no longer remove one
3205    level of nesting. If you still want that, use a ``*`` argument.
3206
3207*   :class:`Frag` and :class:`Element` now have a new method :meth:`mapped`,
3208    that recursively maps the nodes through a function. This is like
3209    :meth:`convert` but via an external function.
3210
3211*   Attribute handling has been improved thanks to a suggestion by Hartmut
3212    Goebel: :meth:`Element.__getitem__` now always works as long as the
3213    attribute name is legal. If the attribute is not set, an empty attribute
3214    will be returned. All empty attributes will be considered as being not set
3215    and so :meth:`hasAttr` returns ``0`` for them, and :meth:`publish` doesn't
3216    publish them. This simplifies several very common cases:
3217
3218    *   Copying an attribute from one element to another works regardless of
3219        whether the attribute is set or not;
3220
3221    *   Testing for an attributes presence can now be done much simpler:
3222        ``if element["attrname"]`` instead of ``if element.hasAttr("attrname")``
3223        (which still works, and should be a little faster);
3224
3225    *   When you construct an XIST tree and the presence or absence of an
3226        attribute is tied to a condition, you can construct the attribute in
3227        advance and use it afterwards in the tree construction::
3228
3229            if condition:
3230                align = "right"
3231            else:
3232                align = None
3233            node = html.div("spam", align=align)
3234
3235        So, when the ``condition`` is false, the node will not have the
3236        attribute ``align`` set.
3237
3238*   :class:`xist.ns.cond.If` (and :class:`xist.ns.cond.ElIf`) can now be used
3239    to test for attributes of the converter. I.e. it's possible to write the
3240    following XML::
3241
3242        <if lang="en">Title
3243        <elif lang="de">Überschrift
3244        </if>
3245
3246*   URL handling has be completely changed and is much, much simpler now. There
3247    are no more path markers. To specify an URL that is relative to the current
3248    directory use the scheme ``root`` (e.g. ``root:main.css``).
3249
3250
3251Changes in 0.4.7 (released 11/24/2000)
3252--------------------------------------
3253
3254*   Fixed a bug in the entity handling.
3255
3256*   Added a few deprecated elements and attributes to the :mod:`html` module.
3257
3258*   Improved the publishing of attributes. Now all attribute values will be
3259    published. For boolean attributes no value will be published for ``XHTML==0``
3260    and the attribute name will be used for ``XHTML==1`` or ``XHTML==2``.
3261
3262*   :meth:`Element.compact` now works (better) ;).
3263
3264*   Incorparated many bug fixes from Hartmut Goebel.
3265
3266*   Implemented :meth:`xsc.Element.copyDefaultAttrs`, which copies unset
3267    attributes over from a dictionary (simplifies implementing
3268    :class:`specials.plaintable` and :class:`specials.plainbody`).
3269
3270*   :meth:`providers.Provider.pushNamespace` now handles multiple arguments
3271    which may be :class:`Namespace` objects or modules (in which case,
3272    ``module.namespace`` will be pushed).
3273
3274*   :meth:`providers.Providers.popNamespace` can now pop multiple namespaces
3275    at once.
3276
3277*   :class:`providers.TidyURIProvider` now uses :func:`os.popen3` for piping
3278    the file through tidy, so now there will be no more temporary files. The
3279    call to tidy now includes options that hopefully make the output more
3280    suited to XIST.
3281
3282*   Incorparated a new :file:`url.py` by Hartmut Goebel, that fixes many problem
3283    (e.g. optimizing ``http://server/foo/bar/../../baz.gif`` now works.)
3284
3285*   :file:`make.py` includes a new option :option:`--path` for adding
3286    directories to :data:`sys.path`.
3287
3288
3289Changes in 0.4.6 (released 11/03/2000)
3290--------------------------------------
3291
3292*   Now uses :class:`sgmlop.XMLParser` instead of :class:`sgmlop.SGMLParser`,
3293    so case is preserved.
3294
3295*   Fixed another regression from the URL to string conversion change.
3296
3297
3298Changes in 0.4.5 (released 11/01/2000)
3299--------------------------------------
3300
3301*   Converting URLs to nodes is now done in :func:`ToNode`, so :class:`URL`
3302    objects can be used everywhere.
3303
3304*   Fixed a few bugs in :meth:`Text._strtext` and :meth:`URLAttr._str`.
3305
3306
3307Changes in 0.4.4 (releases 10/27/2000)
3308--------------------------------------
3309
3310*   Now testing if characters can be encoded with the specified encoding is
3311    done directy. This means, that escaping unencodable characters now works
3312    even with exotic encodings (tested with `JapaneseCodecs 1.0.1`__.
3313
3314    __ http://pseudo.grad.sccs.chukyo-u.ac.jp/~kajiyama/python/
3315
3316*   The :class:`URLAttr` constructor now can handle a single parameter of the
3317    type :class:`URL`.
3318
3319*   The URL to string conversion function have changed: :meth:`URL.asString`
3320    returns the URL with path markers, :meth:`URL.asPlainString` returns the
3321    URL without path markers.
3322
3323*   Added the ``i18n`` attribute to the :class:`font` element.
3324
3325*   Fixed the clashes between the class names for the elements and entities
3326    :class:`sub` and :class:`sup` in :file:`html.py`.
3327
3328*   Several small enhancements and bug fixes contributed by Hartmut Goebel.
3329
3330
3331Changes in 0.4.3 (released 10/19/2000)
3332--------------------------------------
3333
3334*   Now processing instruction classes are registered in the same way as
3335    elements and entities are.
3336
3337*   The leaf nodes (:class:`Text`, :class:`Comment`, :class:`ProcInst`) are now
3338    considered immutable. This means that their :meth:`asHTML` method can
3339    simply return :var:`self`, because now those nodes can be shared between
3340    trees. Functionality for manipulation the objects is provided by a mixin
3341    class very similar to :class:`UserString`. All this results in a speedup
3342    of about 10% for the python-quotes example.
3343
3344*   Small optimizations in the :meth:`asHTML` methods of :class:`Element` and
3345    :class:`Frag` optimized away many calls to :meth:`append`, :meth:`extend`
3346    and :meth:`ToNode` and result in a speedup of about 30% for the
3347    python-quotes example. One consequence of this is that :class:`Null`
3348    objects will no longer be ignored.
3349
3350
3351Changes in 0.4.2 (released 09/24/2000)
3352--------------------------------------
3353
3354*   New elements :class:`keywords` and :class:`description` in :file:`meta.py`.
3355
3356*   Fixed a bug in :meth:`Namespace.register`, now setting ``name=None`` to
3357    prevent an element from being registered works again.
3358
3359
3360Changes in 0.4.1 (released 09/21/2000)
3361--------------------------------------
3362
3363*   A new module named :file:`meta.py` has been created, that simplifies
3364    generating meta tags.
3365
3366*   Various small bugfixes.
3367
3368
3369Changes in 0.4 (released 09/19/2000)
3370------------------------------------
3371
3372*   XIST now requires at least Python 2.0b1.
3373
3374*   A new bugfixed version of the sgmlop source is available from the
3375    `FTP site`_.
3376
3377    .. _FTP site: ftp://ftp.livinglogic.de/pub/livinglogic/xist/
3378
3379*   XIST now completely supports Unicode. For output any encoding known to
3380    Python can be used, so now you can output your HTML in ASCII, Latin-1,
3381    UTF-8, UTF-16, ...
3382
3383*   All publishers have been updated to support Unicode. The publishing
3384    interface has been streamlined (:var:`encoding` and :var:`XHTML` parameters
3385    are now attributes of the publisher).
3386
3387*   :meth:`asString` will now always return a Unicode string. If you want a byte
3388    string use :meth:`asBytes` instead, where the encoding can be specified as
3389    an argument.
3390
3391*   There an additional publisher class :class:`FilePublisher`, which can be
3392    used for publishing to a file (or anything else that has a :meth:`write`
3393    and a :meth:`writelines` method, and is supported by the stream writer
3394    available through :func:`codecs.lookup`).
3395
3396*   Element and attribute names are no longer converted to lowercase. If you
3397    have an attribute name which clashes with a Python keyword (e.g. ``class``)
3398    append an underscore (``_``), which will be removed before accessing the
3399    attribute. This is the "official" Python method for handling these cases.
3400
3401*   Elements and entities are no longer registered one by one. Now you can
3402    build :class:`Namespace` objects which are used for searching and there are
3403    :meth:`pushNamespace` and :meth:`popNamespace` functions in :mod:`XSC.xsc`.
3404    For more info, see the source.
3405
3406*   Image size calculation has been removed from :class:`html.img` and
3407    :class:`html.input`. Use :class:`specials.autoimg` and
3408    :class:`specials.autoinput` for that.
3409
3410*   :meth:`__getitem__`, :meth:`__setitem__` and :meth:`__delitem` of
3411    :class:`Frag` and :class:`Element` now accepts a list as an argument. The
3412    method will be applied recursively, i.e. ``e[[0, 1, "foo", 2]`` is the
3413    same as ``e[0][1]["foo"][2]``.
3414
3415*   The deprecated module :file:`db.py` no longer exists. Useful functions and
3416    elements from :file:`db.py` have been moved to :file:`sql.py` and
3417    :file:`form.py` respectively.
3418
3419*   When using :func:`xsc.make` the encoding and XHTML parameters to use can
3420    now be specified on the command line (e.g. ``--encoding utf-8 --xhtml 2``)
3421
3422*   Handling of multiline ``<?xsc-eval?>`` and ``<?xsc-exec?>`` has been
3423    enhanced, although XIST will not be able to guess the correct indentation
3424    in all cases. As a workarround simply add a Python comment to the beginning.
3425    So the following won't work::
3426
3427        <?xsc-exec
3428            for i in xrange(10):
3429                do(i)
3430        ?>
3431
3432    But this will::
3433
3434        <?xsc-exec
3435            #
3436            for i in xrange(10):
3437                do(i)
3438        ?>
3439
3440*   Make functionality has been moved to :file:`make.py`, as certain modules
3441    can't be used as the main script, because reimporting them in processing
3442    instructions won't work. Now you can simply call::
3443
3444        make.py --import xist.html --import spam eggs.xsc
3445
3446*   There is a new module :file:`cond.py`, that contains elements that can be
3447    used for conditionals::
3448
3449        <?xsc-exec a=42?>
3450        <if cond="a==21">
3451            <b>foo</b>
3452        <elif cond="a==42"/>
3453            <i>bar</i>
3454        <else/>
3455            baz
3456        </if>
3457
3458
3459Changes in 0.3.9 (released 08/10/2000)
3460--------------------------------------
3461
3462*   sgmlop will now be found either via ``import sgmlop`` or via
3463    ``from xml.parsers import sgmlop``.
3464
3465
3466Changes in 0.3.8 (released 07/14/2000)
3467--------------------------------------
3468
3469*   Fixed a bug in :meth:`URLAttr.publish`, which prevented :class:`URLAttr`
3470    from working at all.
3471
3472
3473Changes in 0.3.7 (released 07/06/2000)
3474--------------------------------------
3475
3476*   Fixed a bug in :class:`html.img` and :class:`html.input`. Now image size
3477    calculation works again.
3478
3479
3480*   Changes in 0.3.6 (released 07/04/2000)
3481
3482*   Fixed a bug in :meth:`Node._matches`, which resulted in a non working
3483    :meth:`find`.
3484
3485
3486Changes in 0.3.5 (released 07/02/2000)
3487--------------------------------------
3488
3489*   The documentation example has been enhanced. Now documenting methods works.
3490
3491*   When the member :attr:`elementname`: in the element class is set before
3492    calling :func:`registerElement`, this element name will be used for the
3493    element. This allows custom names even when using
3494    :func:`registerAllElements`.
3495
3496*   Comparison of scheme and server in URLs is done case insensitive (as
3497    :rfc:`2068` requires.)
3498
3499*   Image size calculation is now done in :meth:`asString` and not in
3500    :meth:`asHTML`. This allows to write faster code. Old method::
3501
3502        e = html.div(html.img(...),gurk.hurz()).asHTML().asString()
3503
3504    New method::
3505
3506        e = html.div(html.img(...),gurk.hurz().asHTML()).asString()
3507
3508*   Image size calculation is now done for ``<input type="image">``. The ``size``
3509    attribute is set to the image width.
3510
3511*   Manipulating the path in an URL is now done via the usual
3512    :meth:`__setitem__`/:meth:`__getitem__` stuff, which keeps the path in a
3513    consistent state::
3514
3515        >>> from xist.URL import URL
3516        >>> u = URL("/foo/*/../bar/baz.gif")
3517        >>> del u[1]
3518        >>> u
3519        URL(scheme='server', path=['bar'], file='baz', ext='gif')
3520
3521*   :meth:`findNodes` (which has been shortened to :meth:`find`) has an
3522    additional argument :var:`test`, which can be a test function that will be
3523    called when the node passes all other tests.
3524
3525*   :meth:`asString` no longer generates a string directly, but uses the new
3526    method :meth:`publish`, which has an additional argument :var:`publisher`,
3527    to which the strings to be output are passed.
3528
3529
3530Changes in 0.3.4 (released 05/31/2000)
3531--------------------------------------
3532
3533*   Location information is now copied over in :meth:`clone`, :meth:`asHTML`
3534    and :meth:`compact` where appropriate, so you know even in the HTML tree
3535    where something came from.
3536
3537*   ``xsc.repransi`` can now have three values:
3538
3539    0
3540        coloring is off
3541    1
3542        coloring is on for a dark background
3543    2
3544        coloring is on for a light background
3545
3546*   All ``repransi`` variables are now arrays with two strings, the first for
3547    dark, the second for light.
3548
3549
3550Changes in 0.3.3 (released 05/30/2000)
3551--------------------------------------
3552
3553*   The workaround for the trailing CDATA bug in sgmlop has been removed, so
3554    now you'll need a newer version of sgmlop (included in PyXML 0.5.5.1).
3555
3556
3557Changes before 0.3.3
3558--------------------
3559
3560*   These changes predate written history.
Note: See TracBrowser for help on using the browser.