#romerocox - Stripe CLI Trigger Events

1 messages · Page 1 of 1 (latest)

primal monolith
#

Hello! What command is giving you that error?

woeful elm
#

Hi Rubeus, this happens when I try to run a customized event in VS Code

#

When I first installed, the JSON file was being opened, so I could edita few parameters.

#

Now, It doesn't open the JSON file

#

and it throws that error after I trigger the event

primal monolith
#

Can you remove and reinstall Stripe CLI and give it another try?

woeful elm
#

Already did

#

twice, restarted computer.

primal monolith
#

Does it work from the command line?

woeful elm
#

I haven't tried

#

I'm not sure how to run a custom event from there, can you please give me an example?

#

I can run regular default events no problem

primal monolith
woeful elm
#

Yes, it works from the command line

primal monolith
#

Okay, so it must be something amiss in VSCode. Unfortunately I don't have much familiarity with VSCode myself, so I'm not sure how much help I can be. Let me see if anyone else is around who may be able to help you out, one moment...

woeful elm
#

Thank you

#

I feel like I need to reinstall VS code itself

primal monolith
#

I'm wondering if VSCode doesn't have permission to open the JSON file?

#

Can you open the JSON file as a regular file in VSCode?

woeful elm
#

I don't know where the file should be located.

#

I'm reinstalling VS Code

#

and will see if I can find the json file

#

that json file should come with the extension itself.

#

but I did tried with admin privileges before.

#

Lets see if reinstalling vs code will fix it

primal monolith
#

I meant with your custom fixture.

woeful elm
#

so, when you choose custom fixture, from the menu, VS Code would open a JSON file including the parameters for that specific event

#

that fixture was not created by me

#

the only one I created was the test.json one, that worked fine in cmd line

#

didn't work with reinstalling 😦

primal monolith
#

Right, but can you open test.json in VSCode?

woeful elm
#

Yes.

primal monolith
#

Okay, but trying to trigger that custom event throws the JSON error you shared in your original message?

woeful elm
#

Nops, if I load the json, it works fine

#

changing to an older version to see if it fixes

#

no luck there

#

im installing into my other machine

primal monolith
#

So if you load the JSON first and then run it it works, but if you don't load the JSON first you get the error?

woeful elm
#

the expected behavior is to have the extension create and load the file.

#

with the pre-populated parameters

primal monolith
#

Right, I'm just making sure I understand what's happening.

woeful elm
#

yeah, its something wrong with my computer, maybe something stuck in regedit breaking the extension that does not gets deleted when reinstalling.

#

its working fine on my other computer

#

do you wanna see the video of the expected scenario?

primal monolith
#

Interesting. I'm guessing it's a permissions issue of some kind, especially since it works on that other computer as expected.

woeful elm
#

I'm also with the same thought even though I haven't changed anything at all

primal monolith
#

Strange that it would give a JSON parse error instead of a file access error though...

#

Do you have any VSCode extensions that could be causing the issue? Maybe try disabling them and try again?

woeful elm
#

Will try it

#

can you see if the default fixtures are supposed to be located in my computer?

#

cause I can't find them

#

o if this is something that comes from a cdn of some kind

primal monolith
#

I believe they're inside Stripe CLI itself and aren't accessible on purpose.

woeful elm
#

Well, I will just don't use the extension for that specific functionality then hehe

primal monolith
#

Yeah, if the command line works or opening the JSON directly works at least you have some workarounds.

woeful elm
#

Yup