pythonicrubyist / creek

Ruby library for parsing large Excel files.
http://rubygems.org/gems/creek
MIT License
388 stars 109 forks source link

Remove HTTP dependency #81

Closed fanfilmu closed 4 years ago

fanfilmu commented 5 years ago

Proposed solution for https://github.com/pythonicrubyist/creek/issues/80

mdavidn commented 5 years ago

To avoid a breaking change to the API, you could use Net::HTTP rather than the http gem.

Net::HTTP ships with Ruby. Any application that prefers a different client library (e.g. for VCR) should simply avoid the :remote option.

fanfilmu commented 5 years ago

Hi and thank you for your comment @mdavidn !

Sure, it is an option. Depends on what @pythonicrubyist decides, but in my opinion, we should not avoid the breaking change here... For me, it seems really weird for Excel parser library to be able to download files from the internet.

I would suggest going with the Unix philosophy here, do one thing and do it well ;)

mdavidn commented 5 years ago

I don't disagree. I just don't want a major version bump to be a reason to keep the http dependency.

savfischer commented 5 years ago

I really appreciate the ease of parsing excel files from a remote location this allows. If it is removed maybe it could be a plugin, like shrine does.

mdavidn commented 4 years ago

Ruby already makes it very easy to read files from a remote location. This library does not need additional dependencies to support that feature.

require 'open-uri'
URI('https://path/to/excel/file.xlsx').read
pythonicrubyist commented 4 years ago

I completely agree that this library should not have had the remote option at the first place, but I do not want to introduce a breaking change to a library with over over a milliton downloads.