prey / gdpr_rails

Rails Engine for the GDPR compliance
https://preyproject.com
MIT License
626 stars 62 forks source link

No such file to load -- paperclip.rb #43

Closed mrsweaters closed 5 years ago

mrsweaters commented 5 years ago

Upgrading to 0.5+ keeps the app from running with the following error:

5: from /home/ubuntu/app/shared/bundle/ruby/2.6.0/gems/gdpr_rails-0.5.1/app/models/policy_manager/concerns/paperclip_behavior.rb:2:in `<main>'
4: from /home/ubuntu/app/shared/bundle/ruby/2.6.0/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `require'
3: from /home/ubuntu/app/shared/bundle/ruby/2.6.0/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:291:in `load_dependency'
2: from /home/ubuntu/app/shared/bundle/ruby/2.6.0/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `block in require'
1: from /home/ubuntu/app/shared/bundle/ruby/2.6.0/gems/skylight-core-4.1.2/lib/skylight/core/probes.rb:118:in `require'
/home/ubuntu/app/shared/bundle/ruby/2.6.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:33:in `require': No such file to load -- paperclip.rb (LoadError)

Any ideas on how to debug this?

I tried setting paperclip to false in the config, but that didn't seem to help. I use ActiveStorage.

mrsweaters commented 5 years ago

Since you have paperclip referenced on line 2: https://github.com/prey/gdpr_rails/blob/master/app/models/policy_manager/concerns/paperclip_behavior.rb#L2

Wouldn't this cause an issue with autoloading in Zeitwerk if I don't have the paperclip gem installed?

mrsweaters commented 5 years ago

I can confirm that adding paperclip to my Gemfile resolves the issue. We should be able to use the ActiveStorage version without paperclip installed.

michelson commented 5 years ago

Hi @mrsweaters , did you tried 0.5.1 ? I will close this since this issue was reported in #42 and fix released as 0.5.1 . Feel free to reopen if it's not working for you best

mrsweaters commented 5 years ago

@michelson I'm getting the error with the 0.5.1 release.

mrsweaters commented 4 years ago

This is still an issue with the newest version.

AfroDevGirl commented 4 years ago

I am also running into this issue on the latest release. I also had to specifically add the aws-sdk-s3 gem but that may not have been because of this particular issue.