-
-
Notifications
You must be signed in to change notification settings - Fork 11k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unexpected 'Unsupported protocol' error for relative URLs containing colon (:) character #4633
Comments
Added unit tests;
Nothing to do with Axios. The colon needs to be encoded... axios.get("/api/resource%3AcustomVerb") |
@philBrown Are you sure? Source? I'm not intimately familiar with the standards in play for this but the following suggest it is valid without encoding: |
@cduff My mistake, this is an Axios-specific problem. Encoding the colon is a valid work-around though |
I have the same issue with Axios version |
Describe the bug
For some REST API endpoints we use Google Cloud API Custom Methods URL design like
/api/resource:customVerb
.These worked with
axios
prior to 0.27.1 but now they result in an error like:AxiosError { message: "Unsupported protocol /api/resource:', code: "ERR_BAD_REQUEST", ... }
To Reproduce
Try to have
axios
get a relative URL with a colon in it, e.g.Expected behavior
Should continue working as it did before version 0.27.1.
Environment
Additional context/Screenshots
n/a
The text was updated successfully, but these errors were encountered: