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 Exception: undefined method `set_attribute_was' for #955

Open
raviy06 opened this issue May 8, 2019 · 6 comments · Fixed by sin-to-jin/acts-as-taggable-on#1

Comments

@raviy06
Copy link

raviy06 commented May 8, 2019

rails: 6.0.0.rc1
set_attribute_was method has been removed from ActiveModel. Now previous changes are being tracked by ActiveModel::AttributeMutationTracker, I think.
Anyways, I just commented the set_attribute_was in a forked branch to make it work. This might have some consequences not sure how severe.

Do you want me to raise that request? or do you have any other suggestion as to How to handle this?

Please let me know, I'll be glad to help out.

@kangguru
Copy link

kangguru commented May 9, 2019

tried to understand how to recreate the old behavior with the new mutation tracker .... so far no luck :(

when the line in question is removed you won't see the actual change when using changes on the dirty object, it will always assume that the original value is nil

@raviy06
Copy link
Author

raviy06 commented May 9, 2019

@wildjcrt
Copy link

wildjcrt commented May 13, 2019

#set_attribute_was was removed in this PR rails/rails#35933

@stefankp
Copy link

Are there plans to fix this?

TurtleTony added a commit to TurtleTony/rails-image-board that referenced this issue Jul 9, 2019
This is partially also preparation for Rails 6. However the upgrade can
only be made once acts_as_taggable_on fixes #955
mbleigh/acts-as-taggable-on#955

Signed-off-by: Tristan <tristan.schoenhals@gmail.com>
TheRealNeil added a commit to TheRealNeil/acts-as-taggable-on that referenced this issue Aug 7, 2019
sin-to-jin pushed a commit to sin-to-jin/acts-as-taggable-on that referenced this issue Aug 19, 2019
To fix mbleigh#955
When the Rails version is 6.0.0, it becomes true, so I want to skip set_attribute_was.
champierre added a commit to HoloeyesInc/acts-as-taggable-on that referenced this issue Sep 2, 2019
@designcrumble
Copy link

Any updates on this?
I can attach tags to different models but the tag_list always appear to be nil.
When I do @model.tag_list , I can see the tags!

Thanks ❤️

@wildjcrt
Copy link

I tested and found #968 solved this issue!

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.

5 participants