Skip to content

CORS errors in browser upon server errors (500) - what can we do about that? #2933

@Martinsos

Description

@Martinsos

We have a lot of people hitting the situation where they deploy the app and then get CORS error in the browser. And problem is not CORS at all, the problem is actually e.g. missing env var on the server, server returning 500 or something, and browser showing a CORS error.

This masks what the real problem is and people spend quite some time confused about this.

While we do now have "custom env var validations" as a Wasp feature, and that helps somewhat if employed, any other error can still cause this.

We will also have wasp build start soon which will make it easier to test built app locally, so that will also reduce these errors, but again they can happen.

We should look into ways to mitigate this. Ideal would be if we can show an actual error, not a CORS error. I am not sure if that is possible, or to which degree, but if not, then we should look into other ways to other avoid these errors or to inform the user sooner than later.

Metadata

Metadata

Assignees

No one assigned

    Labels

    dxshouldfixWe should do/fix this at some point

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions