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

require pathname where it is used #388

Merged
merged 1 commit into from Mar 21, 2019

Conversation

d235j
Copy link
Contributor

@d235j d235j commented Feb 10, 2019

Lib::Zip::Entry uses Pathname; if the project that is using RubyZip doesn't already require 'pathname', a bizarre error message of the following form will be generated:

/Users/homedir/.rbenv/versions/2.6.1/lib/ruby/gems/2.6.0/gems/rubyzip-1.2.2/lib/zip/entry.rb:116:in `name_safe?': uninitialized constant Zip::Entry::Pathname (NameError)

As Pathname is used internally, I believe it should be imported from within RubyZip. If there is a better solution to this issue, I'd love to know!

@coveralls
Copy link

Coverage Status

Coverage increased (+0.4%) to 95.794% when pulling a420323 on d235j:pathname-require into d07b13a on rubyzip:master.

Copy link
Member

@jdleesmiller jdleesmiller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for catching this, and sorry for the trouble caused by my patch!

@jdleesmiller
Copy link
Member

I'm helping Alex with rubyzip maintenance now, so I'll get this merged.

@jdleesmiller jdleesmiller merged commit 6aecdf9 into rubyzip:master Mar 21, 2019
This was referenced Mar 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants