xref: /aosp_15_r20/external/jsoup/CHANGES.md (revision 6da8f8c4bc310ad659121b84dd089062417a2ce2)
1*6da8f8c4SAndroid Build Coastguard Worker# jsoup Changelog
2*6da8f8c4SAndroid Build Coastguard Worker
3*6da8f8c4SAndroid Build Coastguard Worker## 1.17.2 (2023-Dec-29)
4*6da8f8c4SAndroid Build Coastguard Worker
5*6da8f8c4SAndroid Build Coastguard Worker### Improvements
6*6da8f8c4SAndroid Build Coastguard Worker
7*6da8f8c4SAndroid Build Coastguard Worker* **Attribute object accessors**: Added `Element.attribute(String)` and `Attributes.attribute(String)` to more simply
8*6da8f8c4SAndroid Build Coastguard Worker  obtain an `Attribute` object. [2069](https://github.com/jhy/jsoup/issues/2069)
9*6da8f8c4SAndroid Build Coastguard Worker* **Attribute source tracking**: If source tracking is on, and an Attribute's key is changed (
10*6da8f8c4SAndroid Build Coastguard Worker  via `Attribute.setKey(String)`), the source range is now still tracked
11*6da8f8c4SAndroid Build Coastguard Worker  in `Attribute.sourceRange()`. [2070](https://github.com/jhy/jsoup/issues/2070)
12*6da8f8c4SAndroid Build Coastguard Worker* **Wildcard attribute selector**: Added support for the `[*]` element with any attribute selector. And also restored
13*6da8f8c4SAndroid Build Coastguard Worker  support for selecting by an empty attribute name prefix (`[^]`). [2079](https://github.com/jhy/jsoup/issues/2079)
14*6da8f8c4SAndroid Build Coastguard Worker
15*6da8f8c4SAndroid Build Coastguard Worker### Bug Fixes
16*6da8f8c4SAndroid Build Coastguard Worker
17*6da8f8c4SAndroid Build Coastguard Worker* **Mixed-cased source position**: When tracking the source position of attributes, if the source attribute name was
18*6da8f8c4SAndroid Build Coastguard Worker  mix-cased but the parser was lower-case normalizing attribute names, the source position for that attribute was not
19*6da8f8c4SAndroid Build Coastguard Worker  tracked correctly. [2067](https://github.com/jhy/jsoup/issues/2067)
20*6da8f8c4SAndroid Build Coastguard Worker* **Source position NPE**: When tracking the source position of a body fragment parse, a null pointer
21*6da8f8c4SAndroid Build Coastguard Worker  exception was thrown. [2068](https://github.com/jhy/jsoup/issues/2068)
22*6da8f8c4SAndroid Build Coastguard Worker* **Multi-point emoji entity**: A multi-point encoded emoji entity may be incorrectly decoded to the replacement
23*6da8f8c4SAndroid Build Coastguard Worker  character. [2074](https://github.com/jhy/jsoup/issues/2074)
24*6da8f8c4SAndroid Build Coastguard Worker* **Selector sub-expressions**: (Regression) in a selector like `parent [attr=va], other`, the `, OR` was binding
25*6da8f8c4SAndroid Build Coastguard Worker  to `[attr=va]` instead of `parent [attr=va]`, causing incorrect selections. The fix includes a EvaluatorDebug class
26*6da8f8c4SAndroid Build Coastguard Worker  that generates a sexpr to represent the query, allowing simpler and more thorough query parse
27*6da8f8c4SAndroid Build Coastguard Worker  tests. [2073](https://github.com/jhy/jsoup/issues/2073)
28*6da8f8c4SAndroid Build Coastguard Worker* **XML CData output**: When generating XML-syntax output from parsed HTML, script nodes containing (pseudo) CData
29*6da8f8c4SAndroid Build Coastguard Worker  sections would have an extraneous CData section added, causing script execution errors. Now, the data content is
30*6da8f8c4SAndroid Build Coastguard Worker  emitted in a HTML/XML/XHTML polyglot format, if the data is not already within a CData
31*6da8f8c4SAndroid Build Coastguard Worker  section. [2078](https://github.com/jhy/jsoup/issues/2078)
32*6da8f8c4SAndroid Build Coastguard Worker* **Thread safety**: The `:has` evaluator held a non-thread-safe Iterator, and so if an Evaluator object was
33*6da8f8c4SAndroid Build Coastguard Worker  shared across multiple concurrent threads, a NoSuchElement exception may be thrown, and the selected results may be
34*6da8f8c4SAndroid Build Coastguard Worker  incorrect. Now, the iterator object is a thread-local. [2088](https://github.com/jhy/jsoup/issues/2088)
35*6da8f8c4SAndroid Build Coastguard Worker
36*6da8f8c4SAndroid Build Coastguard Worker---
37*6da8f8c4SAndroid Build Coastguard WorkerOlder changes for versions 0.1.1 (2010-Jan-31) through 1.17.1 (2023-Nov-27) may be found in
38*6da8f8c4SAndroid Build Coastguard Worker[change-archive.txt](./change-archive.txt).
39