Jake Smith

Joined

3,370 Experience
32 Lessons Completed
0 Questions Solved

Activity

Posted in Realtime Nested Comments: Part 3 Discussion

Unfortunately, with Rails 7, the forms with action-text text-areas are having the issue outlined here: https://github.com/hotwired/turbo-rails/issues/243

Posted in Hotwire missing template on form submission

Hey Francisco. Just ran into this myself, not sure if you are still looking into this, but my problem was with a render call I was making in the controller

Bad syntax:

render turbo_stream.replace(
dom_id_for_records(@commentable, @comment),
partial: 'comments/form',
locals: { comment: @comment, commentable: @commentable }
)

Good syntax:

render turbo_stream: turbo_stream.replace(
dom_id_for_records(@commentable, @comment),
partial: 'comments/form',
locals: { comment: @comment, commentable: @commentable }
)

...difference being the turbo_stream: after render

Posted in Realtime Nested Comments: Part 1 Discussion

I saw this, but after upgrading versions, I'm still not seeing any object errors because the array is empty each time.

Posted in Realtime Nested Comments: Part 1 Discussion

Chris G., I'm having the same issue. But I'm noticing that it is because the POST request is not sending a turbo request, the format seems to be HTML. Not sure why it isn't using turbo for this...

Posted in How to use Hotwire in Rails Discussion

The gem foreman will help you here. It helps get your multiple processes started in one command

Posted in How to use Hotwire in Rails Discussion

Are you running an installed version of redid on your development machine?

Posted in How to use Hotwire in Rails Discussion

No problem 😊

Posted in How to use Hotwire in Rails Discussion

This works with either the asset pipeline or webpacker. The point of showcasing it in the asset pipeline and not with the use of webpacker, I think, is to underline the fact that this is supposed to be minimizing the javascript needed to be written for these features. Why use something as overwhelming as webpack if you aren't going to use it for much (rhetorical)? But it works in either case. Check out the readme: https://github.com/hotwired/turbo-rails (hotwire-rails just packages up turbo-rails and stimulus-rails together for you).

Posted in How to use Hotwire in Rails Discussion

I laughed too hard when you took your jab at Twitter with editing tweets.

Posted in How to use ActionText in Rails 6 Discussion

This didn't resolve me issue either. I'm still getting the following errors on save:

MiniMagick::Error (magick convert /tmp/ActiveStorage-16-20201214-20428-b3u29b.jpeg[0] -auto-orient -resize 1024x768> /tmp/image_processing20201214-20428-1ce1eqd.jpeg failed with error:
convert: no decode delegate for this image format JPEG' @ error/constitute.c/ReadImage/572.
convert: no images defined
/tmp/image_processing20201214-20428-1ce1eqd.jpeg' @ error/convert.c/ConvertImageCommand/3285.
):

If I go to the edit page of my model, the image shows up in the trix editor just fine. But showing the content shows this error

Posted in How to use ActionText in Rails 6 Discussion

This is the first time I'm running into this, but I can't seem to get images I've uploaded in the rich_text to show in the view. I don't see this issue with active storage outside of actiontext, but I get the following error with any image I attach to the rich_text:

MiniMagick::Error (magick convert /tmp/ActiveStorage-16-20201214-20428-b3u29b.jpeg[0] -auto-orient -resize 1024x768> /tmp/image_processing20201214-20428-1ce1eqd.jpeg failed with error:
convert: no decode delegate for this image format JPEG' @ error/constitute.c/ReadImage/572.
convert: no images defined
/tmp/image_processing20201214-20428-1ce1eqd.jpeg' @ error/convert.c/ConvertImageCommand/3285.
):

This is with any image I try. Any ideas?

Posted in Inbound SMS in Rails with Twilio Discussion

Did anyone else run into this issue?

Posted in Inbound SMS in Rails with Twilio Discussion

Hey Chris, when I do a User.find_by(phone: params[:From]), I was hoping that it would use a Phonelib object comparison, but it doesn't, so if my user saved their phone number as 3033033003, it is comparing to a text message coming in (twilio_controller.rb) coming from a number with +1 in front. What is the a clean and performent way to make this query work?

Just getting back to this. Is this something that I put in development.rb/production.rb? This says it defaults to action_mailbox_routing, and I don't see it specified anywhere in my project, searching for config.action_mailbox.queues.routing. I'll keep investigating myself and let you know if I figure it out

This is what I have in my ApplicationMailbox class

class ApplicationMailbox < ActionMailbox::Base
  # routing /something/i => :somewhere

  routing RepliesMailbox::MATCHER => :replies
end

I think I've missed something, but I'm attempting this tutorial and I can't seem to get any of my InboundEmails to move from pending to processing. It kinda just happened on its own in the video from what I can tell, but my inbound emails are not moving past the pending stage. I'm not sure where to look since I didn't see any mention of configuration in the video. Might have missed it though.

Posted in Rails 6 Form remote: true Error

Nvm, seems like I just didn't know enough about the new @rails/ujs stuff. Been doing too much Angular and not staying on top of the latest way of doing Javascript in Rails ;-)

Posted in Rails 6 Form remote: true Error

I get this same error. I'm not sure what is causing it, but I'm in the same situation you outlined. Any luck?