Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

replace REXML with nokogiri (note REXML code currently breaks in ruby 3.0) #68

Open
jrochkind opened this issue Aug 21, 2019 · 2 comments
Milestone

Comments

@jrochkind
Copy link
Collaborator

This code is still using REXML. It should be replaced with nokogiri, becuase REXML is unmaintained and abandoned and much slower than nokogiri.

If there are other alternatives to nokogiri someone wants to suggest, feel free. Nokogiri is definitely the most popular in ruby at present, and one most developers are familiar with (for purposes of writing the code in this gem), but perhaps there's something lighter weight suffiicent for needs here.

@jrochkind
Copy link
Collaborator Author

REXML is used both in tests and in actual live code.

Replacing it in live code is more important than replacing it in tests. Although it might make sense to get it out of tests too, I'd start with replacing it in live code without touching the tests and still having them green, and then considering if you want to leave it that way, or replace REXML in tests too.

@jrochkind
Copy link
Collaborator Author

jrochkind commented Apr 4, 2022

Note that current code fails on ruby 3.0, because of assuming rexml is in stdlib, which it no longer is.

If I try to run tests in ruby 3.0, I get:

$ bundle exec rake
/Users/jrochkind/code/ruby-oai/lib/oai/provider.rb:1:in `require': cannot load such file -- rexml/document (LoadError)

For Ruby 3.0, you may need to add rexml as an explicit dependency, but not sure if that will break things in older versions of ruby. We really have to fix this one way or another.

@jrochkind jrochkind changed the title replace REXML with nokogiri replace REXML with nokogiri (note REXML code currently breaks in ruby 3.0) Apr 4, 2022
@barmintor barmintor added this to the 2.0 milestone Apr 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants