#mattwoberts-test-clock-invoice

1 messages ยท Page 1 of 1 (latest)

pure sailBOT
obtuse dew
#

Hi there ๐Ÿ‘‹ happy to talk through that.

vital crescent
#

Ok thanks ๐Ÿ™‚

#

I have a customer with a sub, in a test clock: cus_MYHI6gppXJAB9M

#

I set the sub up with a trial and a card that will fail, and then advanced to the end of the trial.
On the hosted invoice page I then added a new card (4242) to pay that invoice.
I then advanced to the 6th December to see if that new card would be used for subsequenct invoices, and now - although I'm on the 6th December in the test clock, the invoice is in "draft" mode, even though it was created on the 3rd december?

#

How can that be - why would it be sat there in draft even though it was effectively created 3 days ago

#

(Invoice is in_1LpAoTJVmZSXgBWSJz1ng4Ob)

#

I think this screenshot shows the confusion:

obtuse dew
#

I'm looking, but nothing is jumping out at me so far.

vital crescent
#

Ok... thanks... I could just advance it another hour to see if that "wakes it up" ๐Ÿคทโ€โ™‚๏ธ

obtuse dew
#

I don't see any currently, but want to confirm, did you have a webhook endpoint listening for invoice.created events in test mode when the Invoice was created?

vital crescent
#

Hmm - do you mean did stripe send me an event for invoice.created? No - doesn't look like it... here's all the events I got starting from when I last advanced the clock:

#

Sorry - there IS an invoice.created in there

obtuse dew
#

No, I'm more specifically interested if you had a webhook endpoint listening for that event. If there is and that event is not received successfully, then finalization of the Invoice can be delayed for up to 72 hours while that event is trying to be delivered. I don't think that happened here, but was trying to rule it out.

#

mattwoberts-test-clock-invoice

vital crescent
#

Ok so I'm using the stripe CLI, and I'm not filtering out the webhook events so it's sending all of them - so there will be a invoice.created - they've all been received successfully though

#

I just advanced the clock another hour and it then processed that draft invoice btw - not sure why / what that means ๐Ÿ™‚

obtuse dew
#

Glad to hear it's unstuck! Still looking to see if I can spot why it stalled.

vital crescent
#

Yeah it's a funny one - it's like a managed to "trip" the test clock

obtuse dew
#

It moving forward when you advanced the time clock to 72 hours after the creation time seems too coincidental.

bleak orbit
#

Hello ๐Ÿ‘‹
Taking over as toby needs to step away

#

have you been able to reproduce this if you create another subscription with test clocks?

vital crescent
#

I haven't tried, would you like me to?

bleak orbit
#

Yeah, would help for sure. I tried this on my end but haven't been able to reproduce this behavior.

vital crescent
#

OK - I'll do it soon and report back.

#

Ok I've got it all setup - cus_MYJED3DAEndbKo is my new customer - my next step is to advance the clock 15 days, that will take you past the next invoice date, and should cause the invoice to be finalised and paid... you ready for me to advance it 15 days?

bleak orbit
#

yup

vital crescent
#

Same end result - new invoice is in draft mode even though I'm well past the invoice date now cus_MYJED3DAEndbKo

#

Feels like I've hit a small bug in the test clock logic?

bleak orbit
#

Interesting.. Seems like I'd need some more time to dig deeper
Can you write into our support team (support@stripe.com) and mention that you spoke with hanzo on discord as well as provide as much as details as you can
I'll grab the ticket and make sure to respond as soon as I find something

vital crescent
#

Yeah sure

bleak orbit
#

Let me know once you've written in

vital crescent
#

Ok I've just sent it now

bleak orbit
#

Got it. Thanks again ๐Ÿ™‚

vital crescent
#

I'm hoping for some swag if I did indeed find a bug ๐Ÿ˜‰

bleak orbit
#

I'll archive this thread now as I need to step away soon ๐Ÿ‘‹
Thanks again for your patience