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

NoMethodError: undefined method `closed?' for nil:NilClass #2628

Closed
Mirk32 opened this issue Sep 12, 2022 · 5 comments
Closed

NoMethodError: undefined method `closed?' for nil:NilClass #2628

Mirk32 opened this issue Sep 12, 2022 · 5 comments

Comments

@Mirk32
Copy link

Mirk32 commented Sep 12, 2022

After updating to version 2.1.1 when trying to upload remote file by URL getting following error:

NoMethodError: undefined method `closed?' for nil:NilClass
from /Users/xxx/.rvm/rubies/ruby-2.6.2/lib/ruby/2.6.0/net/http/response.rb:333:in `stream_check'

In 2.1.0 version it works well.

@jules-w2
Copy link

@Mirk32 , #2625

@sailman
Copy link

sailman commented Sep 22, 2022

Same error:

NoMethodError: undefined method closed?' for nil:NilClass /home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/downloader/remote_file.rb:11:in initialize'
/home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/downloader/base.rb:41:in new' /home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/downloader/base.rb:41:in download'
/home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/uploader/download.rb:19:in download!' /home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/mounter.rb:98:in block (2 levels) in remote_urls='
/home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/mounter.rb:176:in handle_error' /home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/mounter.rb:96:in block in remote_urls='
/home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/mounter.rb:95:in each' /home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/mounter.rb:95:in remote_urls='
/home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/mount.rb:166:in remote_photo_url=' /home/sailman/apps/divatod.hu/shared/bundle/ruby/2.7.0/gems/carrierwave-2.2.2/lib/carrierwave/orm/activerecord.rb:21:in remote_photo_url='

@almaron
Copy link

almaron commented Oct 3, 2022

@jules-w2 Same error popping up after I updated an old pet project.
Seems to be an issue specifically with remote opening.

Is that fix from the mentioned issue released?

UPDATE

I tried using the gem from github master (83fcd75) but it's still the same error..

@harssh
Copy link

harssh commented Nov 18, 2022

Still getting this issue . Is there any targeted version which resolves this ?

si.file.download!(si.file.url)
NoMethodError: undefined method closed?' for nil:NilClass
from /Users/hshrivastava/.rvm/gems/ruby-2.7.6@sullivan_cotter/gems/net-http-0.3.0/lib/net/http/response.rb:507:in stream_check'

version gem 'carrierwave', '2.2.2'

@mshibuya
Copy link
Member

See #2638.

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

No branches or pull requests

6 participants