#b0otable - reset

1 messages · Page 1 of 1 (latest)

pine harbor
#

What do you mean by reset exactly?

merry jetty
#

I thought the cleanest option would be to delete my products and manually readd them each time I restart the emulator

#

however, you can't delete test products if they have been used in a test transaction, you can only archive them

#

This is going to get very messy if I can't reset the environment

pine harbor
#

Yeah that's not possible unfortunately

merry jetty
#

So you archive every test product transaction permanently ?

pine harbor
#

Yes. If it's been used, then archiving is the only option.

merry jetty
#

Seems odd

#

I'm really unsure how one is supposed to develop with the Stripe Extension utilizing the Emulator then

#

You restart the emulator or it crashes and all of a sudden your firestore database is completly out of sync with Stripe and there is no way to resync it

pine harbor
#

Yeah I'm not as familiar with the stripe-firebase-extensions, so not sure what the recommended path is for this. Let me check with a colleague and see if they have a suggestion.

#

One thing you could do is export data and then import when you restart the emulator

merry jetty
#

Yes, except that if the emulator crashes or if I want to load different data for different tests, its hard to keep the Stripe data seperate

pine harbor
#

Yeah that's the tricky thing with the firebase emulator

#

I think you'll have to wait for a response on that github issue

#

I'll flag to someone internally and see if someone can get eyes on it

merry jetty
#

It almost seems like it would have been better not to use the extension

pine harbor
#

Sorry about this. I flagged it internally, so hopefully someone does eventually get around to looking into the issue

merry jetty
#

thx

pine harbor
#

Another option could be to just not use the extension at all and implement your own Firebase functions

merry jetty
#

As in utilize the API an create a cloud function that did all of the necessary calls to support the Firebase extension?

#

The challenging thing is, I looked at the official Stripe API, and it would be fairly complex to build all of the required calls. On top of that, for whatever reason the structure of the items within the Firestore doesn't align with the Stripe API