#Steve Sizer

1 messages · Page 1 of 1 (latest)

inland daggerBOT
old trellis
#

Hello

#

Not aware of anything changing specifically. Can you give me an example and more details?

hollow hornet
#

evt_1MEGUqCrlUC0RmrTaY9Cj4WY

and this is the error message in AppSignal

Timed out connecting to Stripe (https://api.stripe.com/). Please check your internet connection and try again. If this problem persists, you should check Stripe's service status at https://status.stripe.com/, or let us know at support@stripe.com.

(Network error: execution expired)

old trellis
#

Hmm are you responding to the Event immediately before doing any other async processes?

hollow hornet
#

This is on my rails server

#

specifically in app/webhooks/invoice_paid.rb:5

#

invoice = event.data.object
if invoice.charge
charge = Stripe::Charge.retrieve(invoice.charge)
end

#

everything has been working just fine no issues and today bam!!! so many timeouts

old trellis
#

Hmm so you are waiting to retrieve the Charge before responding to the Webhook though?

hollow hornet
#

That is in the webhook

old trellis
#

Right that is within the endpoint. I'm just asking at what point you send back a 200 stating you have received the Event

hollow hornet
#

At the end

old trellis
#

The recommended route here is to do that immediately, before anything else, otherwise you can run into a timeout since the timeout window is pretty short. That said it is odd you weren't seeing this before today. Looking more to see if I can tell anything from my end

hollow hornet
#

Thats only one instance. I get a timeout in the following controller also:

app/controllers/api/v1/setup_intent_controller.rb:11 create

old trellis
#

Yep the timeout just means your server didn't respond to the incoming Webhook fast enough

hollow hornet
#

class Api::V1::SetupIntentController < ApplicationController
def create
if @current_user.stripe_id.blank?
customer = Stripe::Customer.create(
email: @current_user.email,
name: @current_user.name
)
@current_user.update(stripe_id: customer.id)
end

@intent = Stripe::SetupIntent.create({
    customer: @current_user.stripe_id,
  })

end
end

#

I wouldnt have thought i would of got a timeout in the above though

indigo jay
#

Where is the actual successful response coming from?

#

Any kind of processing you want to perform, we suggest doing that after you respond to the webhook delivery request

hollow hornet
#

The above controller is for a different timeout which isn't connected to a webhook

#

see image above

indigo jay
#

Ok that's different

#

That looks like your server is having trouble reaching ours.

hollow hornet
#

I can logon to the server and make a call using the rails console and connect

indigo jay
#

It's possible for it to work most of the time / intermittently if you've allowed IP addresses but say a new one isn't listed

hollow hornet
#

have any of these ip addresses been added recently? It seems weird how everything has been working up until today

indigo jay
#

Not in some time (a couple of years ago)

hollow hornet
#

Yeah this is so weird wonder why i'm having all the issues....

indigo jay