-
Notifications
You must be signed in to change notification settings - Fork 25
NoMethodError after upgrading to 0.3.0 #33
Comments
@rbclark it seems that our test suite is missing something big. Would you be able to provide a spec that breaks under the new version? |
hi. got this errror too after
steps to reproduce
Rails 5.1, Ruby 2.4.4
|
i figured it out. DB field should be only string, not oid or integer. You can close the issue |
It seems in my case the problem is due to rails fixtures. With the old version of this gem I was able to declare my fixtures without including my file fields at all and everything worked fine. Now with 0.3.0 any attempts to actually save my object to the database result in a |
Even with your fix it's actually do not working. Checked on your patch-1 pull request carrierwave version. Problems with oid column type. |
@nononoy Is this happening in test fixtures for you or somewhere else? I have mainly seen the problem in my test fixtures I believe however if you are seeing it somewhere else it may be helpful for the maintainers to know. |
This is happening im my app during instance update, not during tests.
So version 0.3.0 only works with string table columns. It's not working even with your PR to carrierwave gem. |
@nononoy Is the |
I have found the problem. The problem is that on carrierwave, they use Changing
|
Thank you, monkey patching helped. |
I've fix this with the following patch: CarrierWave::Mounter.prepend(Module.new do
def remove_previous(before = nil, after = nil)
before &&= Array.new(before).map(&:to_s)
after &&= Array.new(after).map(&:to_s)
super(before, after)
end
end) |
Hello,
My test suite is failing after upgrading to version 0.3.0 of this gem. It seems something goes wrong every time I try to save an object which has a
postgresql_lo
uploader mounted on it. The error isThis did not previously happen with the 0.2.0 version of the gem. Let me know if there's anything else I can do to help debug and fix this, I'd imagine it is just a breaking change in the upgraded version of carrierwave.
The text was updated successfully, but these errors were encountered: