Unable to change environment

  • Goal: Change environments when the application does not use a resource

  • Steps: No steps needed to debug. The warning and user interface actions being blocked seem to be unnecessary.

  • Details: When a resource isn't in use within the application, I am unable to switch my environments. See the warning in the below image.

I am unsure why this limitation is in place, as I can access any environment configuration variable in any JavaScript query. A work around I have added in is by placing a dummy query that does nothing but link to a resource that has been configured (see the below image). This allows me to switch environment as needed.

  • Screenshots:
    image

  • App json export: This doesn't require an application to be exported to be replicated.

I'm curious why you need to switch environment when there is no resource? Is it because your app only use JS queries?

A work around I have added in is by placing a dummy query that does nothing but link to a resource that has been configured (see the below image)

Yeah this sounds like a reasonable workaround.

For my scenario, I'm using a HTTP client package from NPM to talk to a WideSky database. The client package is far more convenient to create HTTP requests, with other additional developer conveniences included, rather than manually creating POST/GET/PUT requests.

I see. Thank you. I think the workaround is reasonable for now. I'll file a task so that our engineer can fix this issue for the long term.

1 Like