# Nokogiri 1.4.2 Released

**URL:** <https://www.ruby-forum.com/t/nokogiri-1-4-2-released/189034>\
**Category:** Ruby\
**Created:** [May 22, 2010, 5:43pm UTC](https://www.ruby-forum.com/t/nokogiri-1-4-2-released/189034 "2010-05-22T17:43:25Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![aaronpowell](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/7bcc69/32.png) [@aaronpowell](https://www.ruby-forum.com/u/aaronpowell)\
**Post date:** [May 22, 2010, 5:43pm UTC](https://www.ruby-forum.com/t/nokogiri-1-4-2-released/189034/1 "2010-05-22T17:43:25Z")

</div>

nokogiri version 1.4.2 has been released!

- [http://nokogiri.org](http://nokogiri.org)
- [http://github.com/tenderlove/nokogiri/wikis](http://github.com/tenderlove/nokogiri/wikis)
- [http://github.com/tenderlove/nokogiri/tree/master](http://github.com/tenderlove/nokogiri/tree/master)
- [http://groups.google.com/group/nokogiri-talk](http://groups.google.com/group/nokogiri-talk)
- [http://github.com/tenderlove/nokogiri/issues](http://github.com/tenderlove/nokogiri/issues)

Nokogiri (é‹¸) is an HTML, XML, SAX, and Reader parser. Among Nokogiri’s  
many features is the ability to search documents via XPath or CSS3  
selectors.

XML is like violence - if it doesnâ€™t solve your problems, you are not  
using  
enough of it.

Changes:

### 1.4.2 / 2010/05/22

- New Features

- Bugfixes

- Notes

---

<div class="post-metadata">

**Author:** ![aaronpowell](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/7bcc69/32.png) [@aaronpowell](https://www.ruby-forum.com/u/aaronpowell)\
**Post date:** [May 26, 2010, 11:59pm UTC](https://www.ruby-forum.com/t/nokogiri-1-4-2-released/189034/2 "2010-05-26T23:59:38Z")

</div>

FYI, a new Nokogiri that has some changes to work with JRuby 1.5.

Also of note, there’s a Nokogiri 1.5 beta that moves to the “pure  
Java” version. You can install with gem install --pre nokogiri. Do  
that and help the Java Nokogiri folks shake out remaining  
functionality and perf issues 🙂

---------- Forwarded message ----------  
From: Aaron P. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
Date: Sat, May 22, 2010 at 10:42 AM  
Subject: [ANN] nokogiri 1.4.2 Released  
To: ruby-talk ML [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid), removed\_email\_address@domain.invalid,  
removed\_email\_address@domain.invalid

nokogiri version 1.4.2 has been released!

- [http://nokogiri.org](http://nokogiri.org)
- [http://github.com/tenderlove/nokogiri/wikis](http://github.com/tenderlove/nokogiri/wikis)
- [http://github.com/tenderlove/nokogiri/tree/master](http://github.com/tenderlove/nokogiri/tree/master)
- [http://groups.google.com/group/nokogiri-talk](http://groups.google.com/group/nokogiri-talk)
- [http://github.com/tenderlove/nokogiri/issues](http://github.com/tenderlove/nokogiri/issues)

Nokogiri (é‹¸) is an HTML, XML, SAX, and Reader parser. Â Among Nokogiri’s  
many features is the ability to search documents via XPath or CSS3  
selectors.

XML is like violence - if it doesnâ€™t solve your problems, you are not  
using  
enough of it.

Changes:

### 1.4.2 / 2010/05/22

- New Features

Â \* XML::Node#parse will parse XML or HTML fragments with respect to the  
Â Â context node.  
Â \* XML::Node#namespaces returns all namespaces defined in the node and  
all  
Â Â ancestor nodes  
Â Â (previously did not return ancestors’ namespace definitions).  
Â \* Added Enumerable to XML::Node  
Â \* Nokogiri::XML::Schema#validate now uses xmlSchemaValidateFile if a  
Â Â filename is passed, which is faster and more memory-efficient. GH  
#219  
Â \* XML::Document#create\_entity will create new EntityDecl objects. GH  
#174  
Â \* JRuby FFI implementation no longer uses ObjectSpace.\_id2ref,  
Â Â instead using Charles Nutter’s rocking Weakling gem.  
Â \* Nokogiri::XML::Node#first\_element\_child fetch the first child node  
that is  
Â Â an ELEMENT node.  
Â \* Nokogiri::XML::Node#last\_element\_child fetch the last child node that  
is  
Â Â an ELEMENT node.  
Â \* Nokogiri::XML::Node#elements fetch all children nodes that are  
ELEMENT  
Â Â nodes.  
Â \* Nokogiri::XML::Node#add\_child, #add\_previous\_sibling, #before,  
Â Â #add\_next\_sibling, #after, #inner\_html, #swap and #replace all now  
Â Â accept a Node, DocumentFragment, NodeSet, or a string containing  
Â Â markup.  
Â \* Node#fragment? indicates whether a node is a DocumentFragment.

- Bugfixes

Â \* XML::NodeSet is now always decorated (if the document has  
decorators).  
Â Â GH #198  
Â \* XML::NodeSet#slice gracefully handles offset+length larger than the  
set  
Â Â length. GH #200  
Â \* XML::Node#content= safely unlinks previous content. GH #203  
Â \* XML::Node#namespace= takes nil as a parameter  
Â \* XML::Node#xpath returns things other than NodeSet objects. GH #208  
Â \* XSLT::StyleSheet#transform accepts hashes for parameters. GH #223  
Â \* Psuedo selectors inside not() work. GH #205  
Â \* XML::Builder doesn’t break when nodes are unlinked.  
Â Â Thanks to vihai! GH #228  
Â \* Encoding can be forced on the SAX parser. Thanks Eugene Pimenov! GH  
#204  
Â \* XML::DocumentFragment uses XML::Node#parse to determine children.  
Â \* Fixed a memory leak in xml reader. Thanks sdor! GH #244  
Â \* Node#replace returns the new child node as claimed in the  
Â Â RDoc. Previously returned +self+.

- Notes

Â \* The Windows gems now bundle DLLs for libxml 2.7.6 and libxslt  
Â Â 1.1.26. Prior to this release, libxml 2.7.3 and libxslt 1.1.24  
Â Â were bundled.
