fix info request in js client (#4271)

* fix info request in js client

* changelog
This commit is contained in:
pngwn 2023-05-19 15:58:42 +01:00 committed by GitHub
parent 7145327058
commit 1151c52535
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 1 deletions

View File

@ -0,0 +1,5 @@
---
"@gradio/client": patch
---
Ensure the full root path is always respected when making requests to a gradio app server.

View File

@ -5,6 +5,7 @@ No changes to highlight.
## Bug Fixes:
- Fixed the behavior of the `run_on_click` parameter in `gr.Examples` by [@abidlabs](https://github.com/abidlabs) in [PR 4258](https://github.com/gradio-app/gradio/pull/4258).
- Ensure js client respcts the full root when making requests to the server by [@pngwn](https://github.com/pngwn) in [PR 4271](https://github.com/gradio-app/gradio/pull/4271)
## Other Changes:

View File

@ -655,7 +655,7 @@ export async function client(
}
);
} else {
response = await fetch(`${http_protocol}//${host}/info`, {
response = await fetch(`${config.root}/info`, {
headers
});
}