Remote Mock Testing for API Hub Specs fails when deployed to Cloud Run from VS Code: HTTP 412 Error

Hi i am using Cloud Code VS Studio Code Remote Explorer launched through GCP Console.

I have created a Sample Specs for Blog Management as mentioned in the url - Tutorial: Using Gemini Code Assist to design, develop, and test APIs in Apigee and Cloud Code | Google Cloud and want to create a mock Cloud Run Service for same.

I am not able to change the region here from VS Studio Code and it’s coming as us-central1.

When i click deploy button i encounter an error as below (

ERROR: (gcloud.run.deploy) HTTPError 412: ‘us’ violates constraint ‘constraints/gcp.resourceLocations’)

I am unable to change the location and when i query Gemini code assist on this issue here is the response (us -multi region is not supported). All this is managed through internal commands i am stuck. How can i do remote mock testing or if someone has tested this in past let me know.

thanks,

Aakash

Hello @aakashsharmaa5 , we appreciate you posting this question and your patience as we monitor the conversation. We’re inviting our community members to chime in with their suggestions. Rest assured, we’re here to help you get a response.

Thanks @AlexET
Hi @aakashsharmaa5 Thanks for your post I will investigate and get back asap. Apologies for the inconvenience and thanks for your patience :slightly_smiling_face:

1 Like

Hi @aakashsharmaa5 I have discussed your question with our product team. It looks like from your error that there is a restriction on your account deploying to the us-central1 region.

  • Unfortunately during public preview we don’t allow selection of another region other than us-central1 from the IDE deployment.

If you remove the region restriction (if you are allowed) then it should deploy fine to us-central1. :+1:

thanks @christopherkarl let me check with my infra team.

best regards, Aakash