Skip to content

delb 0.6

Latest

Choose a tag to compare

@github-actions github-actions released this 15 Feb 13:35
· 1 commit to main since this release

This release brings significant changes that evolve delb to a mature level, namely:

  • 🎇 All data keeping is now implemented natively without lxml, leading to remarkable performance improvements.
  • 🎉 There's a new parser interface for extensiblity.
  • 🪩 The API can be considered stable.

At least 99.5% of all code is guaranteed to be covered by tests. The accompanying integration test corpora have been updated and extended.

News

  • ⚠️ For more clarity the symbols that are re-exported in the top-level module delb are greatly reduced. Instead they're to be imported from their domain specific modules delb.filters, delb.names, delb.nodes and delb.utils. Some generally applicable ones will stay available for convenice though.
  • There are new abstract base classes for each node type rooting from delb.typing.XMLNodeType that should be used for type annotations.
  • ⚠️ Functions to construct new node instances such as delb.nodes.new_tag_node are deprecated. The corresponding, concrete node classes are now to be instantiated directly.
  • A new parser interface allows the use of arbitrary parsing backends. Support for the standard library's expat interface and lxml are contributed. For details see „Installation” and delb.parser.ParserOptions.
  • When a used parser backend supports DTDs, it can be instructed with the delb.parser.ParserOptions.load_referenced_resources option to consider these.
  • New parsing related exceptions have been added: delb.exceptions.ParsingError bases delb.exceptions.ParsingProcessingError and delb.exceptions.ParsingValidityError.
  • ⚠️ The delb.parser.ParserOptions.resolve_entities option has been removed entirely as delb's data model doesn't include any entities (that could stay unresolved in a document model).
  • The W3C's parser conformance test suite is included in delb's.
  • ⚠️ delb.parse_tree replaces delb.TagNode.parse to produce tag nodes from a serialized tree. The new delb.parse_nodes produces an iterator over (sub-)trees (possibly an XML document fragment).
  • ⚠️ The installation extra https-loader is renamed to web-loader
  • ⚠️ The parser_options must now be passed as keyword argument to a delb.Document.
  • A source_url can now be passed explicitly when instantiating a delb.Document.
  • ⚠️ The delb.nodes.TagNode.prefix attribute is gone.
  • ⚠️ Support for Python 3.8 & 3.9 was removed, for Python 3.14 it's added.

The package distributions are available at the Python Package Index.