read_html() now allows huge elements by default (#455)
Workaround for xQuartz/Cocoa on MacOS hitting our global errorhandler.
Avoid accessing some struct internals disallowed in libxml22.14
Replace new “non-api” call IS_S4_OBJECT with Rf_isS4
Windows: update fallback libs (for R < 4.3) to libxml22.11.5
Compile with C_VISIBILITY and CXX_VISIBILITY on supportedplatforms
Windows: use libxml2 from Rtools if found
Update maintainer
Minor cleanups
Now compatible with libxml2 2.12.0 and later (
Fixed format string issues detected in R-devel.
Remove unused dependencies on glue, withr and lifecycle (
print() is faster for very longxml_nodeset inputs (#366,
xml_attr(),xml_attrs(),xml_double(),xml_integer(),xml_length(),xml_name(),xml_path(),xml_text(), andxml_type() no longer use S3 dispatch but instead dispatchin C, leading to considerable performance improvements in many cases(@mgirlich,#400).
xml_find_int() analogous toxml_find_num() for returning integers matched by an XPath(#365,
xml_serialize() now includes the document type sothatxml_unserialize() works also for HTML documents (#407,
Small speedup forxml_find_all() (
Fixes for R CMD check problems.
Fixes for R CMD check problems.
Windows: update to libxml2 2.10.3
Hadley Wickham is now (again) the maintainer.
xml2 has been re-licensed as MIT (#317).
xml_find_all.xml_node() fails more informatively thexpath parameter is the wrong type (
xml_find_all.xml_nodeset() gains aflatten argument to control whether to return a singlenodeset or a list of nodesets (#311,
write_xml() andwrite_html() now returnNULL invisibly, as they did prior to version 1.3.0 (#307)
XPtr gets explicit copy constructor and assignmentoperator definitions, which were two missing components of theRuleof three (
Windows: update to libxml2 2.9.10 and libxslt 1.1.34 and add ucrtlibs
read_html() andread_xml() now error ifpassed strings of length greater than one (#121)
read_xml.raw() had an inadvertent regression in1.3.0 and is now again fixed (#300)
Compilation fix on macOS 10.15.4 (
read_html() now again works with HTML files withnon-ASCII encodings (#293).Fix potential dangling pointer with internalasXmlChar() function (
as_xml_document() now handles cases with text nodestrailing normal nodes (#274).
xml_add_child() can now create nodes with apar attribute. These previously errored due to partial namematching of theparent function in the internalcreate_node() function. (
libxml2_version() now returns a semantic versionrather than alphanumeric version, so “2.9.10” > “2.9.9”(#277)
xml2 now has a pkgdown site!https://xml2.r-lib.org (
Windows: upgrade to libxml2 2.9.8
print methods now match the type of document,e.g. read_html() prints as “{html_document}” rather than“{xml_document}” (#227)
Generic xml2 error are now forwarded as R errors. Previouslythese errors were output to stderr, so could not be suppressed(#209).
Fix for ICU 59+ defaulting to use char16_t, which is onlyavailable in C++11 (#231)
No longer uses the C connections API
Better error message when trying to rundownload_xml() without the curl package installed(#262)
xml2 classes are now registered for use with S4 by callingsetOldClass() (#248)
Nodes with nested data type definition entities now work withoutcrashing (#241)
Test failure fixed due to behavior change with relative paths inlibxml2 2.9.9 (#245).
read_xml() now has a better error message when givenzero length character inputs (#212).
read_xml() andread_html() nowautomatically check if the response succeeded before trying to read froma HTTP response (#255).
xml_root() can now create root nodes with namespaces(#239)
xml_set_attr() no longer crashes if you try to setthe same namespace on the same node multiple times (#253).
xml_set_attr() now recycles the values if needed(#221)
xml_structure() gains afile argument,to support writing to a file rather than the console (#244).
as_list() onxml_document objects did notproperly include the root node in the returned list. Previous behaviorcan be obtained by usingas_list()[[1L]] in place ofas_list().download_xml() anddownload_html()helper functions to make it easy to download files (#193).
xml_attr() can now set attributes with no value(#198).
xml_serialize() andxml_unserialize()now create file connections when given character input (#179).
xml_find_first() no longer de-duplicates results, sothe results are always the same length as the inputs (as documented)(#194).
xml2 can now build using libxml2 2.7.0
Use Rcpp symbol registration and visibility to prevent symbolconflicts on Linux
xml_add_child() now requires less resources toinsert a node when called with.where = 0L (
Fixed failing examples due to a change in an externalresource.
write_xml() andwrite_html() now acceptconnections as well as filenames for output. (#157)
xml_add_child() now takes a.whereargument specifying where to add the new children. (#138)
as_xml() generic function to convert R objects toxml. The most important method is for lists and enables full roundtripsupport for going to and back from xml for lists and enables fullroundtrip support to and from XML. (#137, #143)
xml_new_root() can be used to create a new documentand a root node in one step (#131).
xml_add_parent() inserts a new node between the nodeand its parent (#129)
Addxml_validate() to validate a document against anxml schema (#31,
Exportxml2_types.h to allow for extension packagessuch as xslt.
xml_comment() allows you to add comment nodes to adocument. (#111)
xml_cdata() allows you to add CDATA nodes to adocument. (#128)
Addxml_set_text() andxml_set_name()equivalent toxml_text<- andxml_name<-.(#130).
Addxml_set_attr() andxml_set_attrs()equivalent toxml_attr<- andxml_attrs<-. (#109, #130)
Addwrite_html() method (#133).
xml_new_document() now explicitly sets the encoding(default UTF-8) (#142)
Document formatting options forwrite_xml()(#132)
Add missing methods for xml_missing objects. (#134)
Bugfix for xml_length.xml_nodeset that caused it to failunconditionally. (#140)
is.na() now returnsTRUE forxml_missing objects. (#139)
Trim non-breaking spaces inxml_text(trim = TRUE)(#151).
Allow setting non-character attributes (values are coerced tocharacters). (@sjp, #117,#122).
Fixed return value in call to vapply in xml_integer.xml_nodeset.(@ddiez, #146,#147).
Allow docs missing a root element to be created and printed.(@sjp, #126,#121).
xml_add_* methods now return invisibly. (
as_list() now preserves element names whenattributes exist, and escapes XML attributes that conflict with specialR attributes (
All C++ functions now usechecked_get() instead ofget() where possible, so NULL XPtrs properly throw an errorrather than crashing. (
xml_integer() andxml_double()functions to make it easy to extract integer and double text from nodes(@jimhester, #97,#99).
xml2 now supports modification and creation of XML nodes. Newfunctionsxml_new_document(),xml_new_child(),xml_new_sibling(),xml_set_namespace(), ,xml_remove(),xml_replace(),xml_root() and replacement methods forxml_name(),xml_attr(),xml_attrs() andxml_text() (
xml_ns() now keeps namespace prefixes that point tothe same URI (
read_xml() andread_html() methodsadded forhttr::response() objects. (
xml_child() function to make selecting children alittle easier (
xml_find_one() has been deprecated in favor ofxml_find_first() (
xml_read() functions now default to passing thedocument’s namespace object. Namespace definitions can now be removed aswell as added andxml_ns_strip() added to remove alldefault namespaces from a document. (
xml_read() gains aoptions argument tocontrol all available parsing options, includingHUGE toturn off limits for parsing very large documents and now drops blanktext nodes by default, mimicking default behavior of XML package. (
xml_write() expands the path on filenames, sodirectories can be specified with ‘~/’ (
xml_find_one() now returns a ‘xml_missing’ nodeobject if there are 0 matches (
xml_find_num(),xml_find_chr(),xml_find_lgl() functions added to return numeric, characterand logical results from XPath expressions. (
xml_name() andxml_text() alwayscorrectly encode returned value as UTF-8 (#54).
Improved configure script - now works again on R-devel onwindows.
Compiles with older versions of libxml2.,
Make configure script more cross platform.
Addxml_length() to count the number of children(#32).