Skip to content
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

Change client submit API to be an AsyncIterable and support more platforms #8451

Merged
merged 46 commits into from
Jun 6, 2024

Conversation

pngwn
Copy link
Member

@pngwn pngwn commented Jun 4, 2024

Description

Please include a concise summary, in clear English, of the changes in this pull request. If it closes an issue, please mention it here.

Closes #8208.
Closes #8207.
Closes #4348

🎯 PRs Should Target Issues

Before your create a PR, please check to see if there is an existing issue for this change. If not, please create an issue before you create this PR, unless the fix is very small.

Not adhering to this guideline will result in the PR being closed.

Tests

  1. PRs will only be merged if tests pass on CI. To run the tests locally, please set up your Gradio environment locally and run the tests: bash scripts/run_all_tests.sh

  2. You may need to run the linters: bash scripts/format_backend.sh and bash scripts/format_frontend.sh

@gradio-pr-bot
Copy link
Contributor

gradio-pr-bot commented Jun 4, 2024

🪼 branch checks and previews

Name Status URL
Spaces ready! Spaces preview
Website ready! Website preview
Storybook ready! Storybook preview
🦄 Changes detected! Details

Install Gradio from this PR

pip install https://gradio-builds.s3.amazonaws.com/4cacbf3dd417dc5d9e0e363f90c29bc9acca0391/gradio-4.33.0-py3-none-any.whl

Install Gradio Python Client from this PR

pip install "gradio-client @ git+https://github.com/gradio-app/gradio@4cacbf3dd417dc5d9e0e363f90c29bc9acca0391#subdirectory=client/python"

Install Gradio JS Client from this PR

npm install https://gradio-builds.s3.amazonaws.com/4cacbf3dd417dc5d9e0e363f90c29bc9acca0391/gradio-client-0.20.1.tgz

@gradio-pr-bot
Copy link
Contributor

gradio-pr-bot commented Jun 4, 2024

🦄 change detected

This Pull Request includes changes to the following packages.

Package Version
@gradio/app patch
@gradio/client patch
@gradio/file patch
@gradio/spaces-test patch
gradio patch
  • Maintainers can select this checkbox to manually select packages to update.

With the following changelog entry.

Change client submit API to be an AsyncIterable and support more platforms

Maintainers or the PR author can modify the PR title to modify this entry.

Something isn't right?

  • Maintainers can change the version label to modify the version bump.
  • If the bot has failed to detect any changes, or if this pull request needs to update multiple packages to different versions or requires a more comprehensive changelog entry, maintainers can update the changelog file directly.

@pngwn pngwn changed the title 8207 fetch stream 2 Change client submit AQPI to be an AsyncIterable and support more platforms Jun 4, 2024
@pngwn pngwn changed the title Change client submit AQPI to be an AsyncIterable and support more platforms Change client submit API to be an AsyncIterable and support more platforms Jun 4, 2024
@pngwn
Copy link
Member Author

pngwn commented Jun 4, 2024

Docs etc will come in a separate PR.

@@ -29,7 +29,7 @@ describe("upload_files", () => {
expect(response.files[0]).toBe("lion.jpg");
});

it("should handle a server error when connected to a running app and uploading files", async () => {
it.skip("should handle a server error when connected to a running app and uploading files", async () => {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

file issue

client/js/src/types.ts Outdated Show resolved Hide resolved
client/js/src/client.ts Outdated Show resolved Hide resolved
client/js/src/utils/submit.ts Outdated Show resolved Hide resolved
client/js/src/types.ts Outdated Show resolved Hide resolved
Copy link
Collaborator

@hannahblair hannahblair left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tested and works great!! 🎉 awesome work @pngwn

@pngwn pngwn merged commit 9d2d605 into main Jun 6, 2024
8 checks passed
@pngwn pngwn deleted the 8207-fetch-stream-2 branch June 6, 2024 12:16
This was referenced Jun 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
5 participants