David Kimura PRO
Joined 7/18/2015
Drifting Ruby Owner
Ruby Rogues Panelist
David Kimura PRO said over 3 years ago on StimulusJS, Active Storage and DropzoneJS :
The blob that comes back looks like it's not set. Did ActiveStorage store it? (check the Rails logs) 

David Kimura PRO said over 3 years ago on StimulusJS, Active Storage and DropzoneJS :
When it made the post to your direct upload endpoint, it errored out with a 422. The Rails logs may help. Have you tried testing direct upload without any stimulus or anything else? You may have another underlying issue. 

David Kimura PRO said over 3 years ago on StimulusJS, Active Storage and DropzoneJS :
Can't verify CSRF token authenticity.

This does seem to be the issue. What does the form and stimulus controller look like? 

David Kimura PRO said over 3 years ago on StimulusJS, Active Storage and DropzoneJS :
Try changing the user avatar file field to a direct upload and see if you get the same issue.
If you revert back to ERB, do you get the same issue?

David Kimura PRO said over 3 years ago on StimulusJS, Active Storage and DropzoneJS :
I just pulled down the source for this episode and tried things out. It worked (once I updated an unrelated issue sass-rails). What ActiveStorage storage mechanism are you using?