Releases: scrapy/parsel
Releases · scrapy/parsel
1.8.1
1.8.0
- Add support for JMESPath: you can now create a selector for a JSON document and call
Selector.jmespath()
. - Selectors can now be constructed from
bytes
(using thebody
andencoding
arguments) instead ofstr
(using thetext
argument). - Typing improvements
- The
pkg_resources
module (which was absent from the requirements) is no longer used - Documentation build fixes
1.7.0
- Add PEP 561-style type information
- Support for Python 2.7, 3.5 and 3.6 is removed
- Support for Python 3.9-3.11 is added
- Very large documents (with deep nesting or long tag content) can now be parsed, and Selector now takes a new argument huge_tree to disable this
- Support for new features of cssselect 1.2.0 is added
- The Selector.remove() and SelectorList.remove() methods are deprecated and replaced with the new Selector.drop() and SelectorList.drop() methods which don’t delete text after the dropped elements when used in the HTML mode.
1.6.0
v1.3.1
has-class
XPath extension function;parsel.xpathfuncs.set_xpathfunc
is a simplified way to register
XPath extensions;Selector.remove_namespaces
now removes namespace declarations;- Python 3.3 support is dropped;
make htmlview
command for easier Parsel docs development.- CI: PyPy installation is fixed; parsel now runs tests for PyPy3 as well.
1.3.1 was released shortly after 1.3.0 to fix pypi upload issue.
v1.2.0
- Add
get()
andgetall()
methods as aliases forextract_first
andextract
respectively - Add default value parameter to
SelectorList.re_first
method - Add
Selector.re_first
method - Bug fix: detect
None
result from lxml parsing and fallback with an empty document - Rearrange XML/HTML examples in the selectors usage docs
- Travis CI:
- Test against Python 3.6
- Test against PyPy using "Portable PyPy for Linux" distribution
v1.1.0
- Change default HTML parser to lxml.html.HTMLParser,
which makes easier to use some HTML specific features - Add css2xpath function to translate CSS to XPath
- Add support for ad-hoc namespaces declarations
- Add support for XPath variables
- Documentation improvements and updates
v1.0.3
v1.0.2
Bug fix in exception handling and documentation fixes.
v1.0.1
- Documentation and typo fixes