Git Product home page Git Product logo

Comments (23)

vdaubry avatar vdaubry commented on August 16, 2024

I have the same problem after updating to Paperclip 3.5.2

Stack :
ruby 2.0.0p247
rails 3.2.16
paperclip 3.5.2
delayed_job_active_record 4.0.0

The problem is in delayed_paperclip/attachment.rb:16

@instance.class.paperclip_definitions[@name] now returns nil

I submitted a quick fix for this issue : #67

Can we have a comment from the author on this ?

from delayed_paperclip.

ScotterC avatar ScotterC commented on August 16, 2024

I feel like just nil checking it would be covering up a deeper issue. This method https://github.com/jrgifford/delayed_paperclip/blob/master/lib/delayed_paperclip.rb#L74 may have been broken with the latest Paperclip update.

from delayed_paperclip.

jrgifford avatar jrgifford commented on August 16, 2024

It might have been. I'll need to look, that method might be the root of some other problems people are experiencing...

from delayed_paperclip.

redbush avatar redbush commented on August 16, 2024

any word?

from delayed_paperclip.

jrgifford avatar jrgifford commented on August 16, 2024

I just merged in #67. I'll be aiming for a release in the next week or so with it.

from delayed_paperclip.

aripollak avatar aripollak commented on August 16, 2024

Does this code need to be kept in delayed_paperclip? It looks like it's covering up a problem with STI (as fixed in thoughtbot/paperclip#1331, not yet released in gem form).

from delayed_paperclip.

aripollak avatar aripollak commented on August 16, 2024

One more followup to this: using the latest code from paperclip master fixes the problem on 2.6.1 (and allows STI classes to work properly), so I think this patch should be reverted.

from delayed_paperclip.

ScotterC avatar ScotterC commented on August 16, 2024

@aripollak Thanks for getting to the bottom of this! @jrgifford agree that we should revert it?

from delayed_paperclip.

jrgifford avatar jrgifford commented on August 16, 2024

Sure. I might get to this today, but if someone does first, I'd be open to
merging it.

from delayed_paperclip.

jGRUBBS avatar jGRUBBS commented on August 16, 2024

I have a pull request that fixes this issue. See here:
#73

from delayed_paperclip.

jrgifford avatar jrgifford commented on August 16, 2024

Fixed by #73.

from delayed_paperclip.

julien-duponchelle avatar julien-duponchelle commented on August 16, 2024

Did you have plan to release a version on rubygems with this fix?

from delayed_paperclip.

ScotterC avatar ScotterC commented on August 16, 2024

I'm looking to release one shortly.

from delayed_paperclip.

ScotterC avatar ScotterC commented on August 16, 2024

Version 2.7 released.

from delayed_paperclip.

julien-duponchelle avatar julien-duponchelle commented on August 16, 2024

Thanks a lot

from delayed_paperclip.

aripollak avatar aripollak commented on August 16, 2024

It looks like the code from #67 is still in master, which is not necessary (and masks the problem) since the bug was fixed in paperclip.

from delayed_paperclip.

ScotterC avatar ScotterC commented on August 16, 2024

@aripollak your right. Can you make a PR to remove it please. Only the code that's necessary should exist in the repo

from delayed_paperclip.

aripollak avatar aripollak commented on August 16, 2024

Could you just run git revert 8c1c12b?

from delayed_paperclip.

ScotterC avatar ScotterC commented on August 16, 2024

We don't rewrite git history once it's in a published gem.

On Tuesday, March 4, 2014, Ari Pollak [email protected] wrote:

Could you just run git revert 8c1c12b?

Reply to this email directly or view it on GitHubhttps://github.com//issues/66#issuecomment-36702647
.

Scott Carleton
Artsicle, Co-Founder / CTO
[email protected]
C. 914 400 5085

from delayed_paperclip.

aripollak avatar aripollak commented on August 16, 2024

git revert doesn't rewrite history; it's not reset or rebase. https://www.kernel.org/pub/software/scm/git/docs/git-revert.html

from delayed_paperclip.

deivid-rodriguez avatar deivid-rodriguez commented on August 16, 2024

I'm still getting this error with last master... but I don't understand which revert is needed

git revert 8c1c12b

won't cleanly merge into master, and that check for nil is not done anymore.

from delayed_paperclip.

aripollak avatar aripollak commented on August 16, 2024

Oh whoops, you're right @deivid-rodriguez, I was looking at the wrong repository, so nothing further needs to happen on this issue. If you're still seeing this error, you might need to upgrade paperclip or delayed_paperclip (the latter due to #73).

from delayed_paperclip.

deivid-rodriguez avatar deivid-rodriguez commented on August 16, 2024

I'm running latest versions of both. I'll try to give more information if I find it again.

from delayed_paperclip.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.