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

Incompatible with URI >=1.0.0 #2759

Closed
swelther opened this issue Nov 7, 2024 · 2 comments · Fixed by #2760
Closed

Incompatible with URI >=1.0.0 #2759

swelther opened this issue Nov 7, 2024 · 2 comments · Fixed by #2760

Comments

@swelther
Copy link

swelther commented Nov 7, 2024

Today the standard gem URI was released as 1.0.0, introducing a new default parser RFC3986_Parser: https://github.com/ruby/uri/pull/107/files

This results in errors like

NameError: uninitialized constant URI::REGEXP
Did you mean?  Regexp
…/ruby/3.1.0/gems/uri-1.0.0/lib/uri/common.rb:53:in `const_missing'
…/ruby/3.1.0/gems/carrierwave-3.0.7/lib/carrierwave/utilities/uri.rb:7:in `<module:Uri>'

I think I could prevent this error by setting the default parser back to the old one with URI.parser = URI::RFC2396_PARSER. But not sure how carrierwave should behave.

@jules-w2
Copy link

jules-w2 commented Nov 7, 2024

i confirm, @ollym 's PR fix this issue.
I hope it can be merged quickly

@taketo1113
Copy link

I encountered the same error with uri gem v1.0.0.

Updating to uri gem v1.0.1 resolved the uninitialized constant URI::REGEXP error.
It seems that in uri gem v1.0.1, URI::REGEXP fallback to URI::RFC2396_REGEXP.

ruby/uri#125 (comment)

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 a pull request may close this issue.

3 participants