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

Fix Chatbot Examples Error #9623

Merged
merged 6 commits into from
Oct 9, 2024
Merged

Fix Chatbot Examples Error #9623

merged 6 commits into from
Oct 9, 2024

Conversation

freddyaboulton
Copy link
Collaborator

Description

Fixes:

  • Chatbot examples were given "assistant" role instead of "user" as reported by @hysts
  • Clear button was not working properly with chatbot examples
  • Undo button was not working when there was only one message in the chat

Added e2e tests

🎯 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
Collaborator

gradio-pr-bot commented Oct 9, 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-pypi-previews.s3.amazonaws.com/58094e49dea51f9340a45447bb3d7d61a3169bab/gradio-5.0.0-py3-none-any.whl

Install Gradio Python Client from this PR

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

Install Gradio JS Client from this PR

npm install https://gradio-npm-previews.s3.amazonaws.com/58094e49dea51f9340a45447bb3d7d61a3169bab/gradio-client-1.6.0.tgz

Use Lite from this PR

<script type="module" src="https://gradio-lite-previews.s3.amazonaws.com/58094e49dea51f9340a45447bb3d7d61a3169bab/dist/lite.js""></script>

@gradio-pr-bot
Copy link
Collaborator

gradio-pr-bot commented Oct 9, 2024

🦄 change detected

This Pull Request includes changes to the following packages.

Package Version
@gradio/chatbot patch
gradio patch
  • Maintainers can select this checkbox to manually select packages to update.

With the following changelog entry.

Fix Chatbot Examples Error

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.

@freddyaboulton freddyaboulton added the v: patch A change that requires a patch release label Oct 9, 2024
@freddyaboulton freddyaboulton marked this pull request as ready for review October 9, 2024 20:15
@freddyaboulton freddyaboulton requested review from dawoodkhan82, abidlabs, aliabid94 and hysts and removed request for dawoodkhan82 October 9, 2024 20:15
@freddyaboulton
Copy link
Collaborator Author

The e2e tests pass locally for me - pnpm test:browser -g "test_chatinterface_examples

Copy link
Collaborator

@aliabid94 aliabid94 left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link
Member

@abidlabs abidlabs left a comment

Choose a reason for hiding this comment

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

LGTM nice one @freddyaboulton!

@abidlabs
Copy link
Member

abidlabs commented Oct 9, 2024

will merge in in case there are conflicts with @aliabid94's PR.

@abidlabs abidlabs merged commit 5923c67 into main Oct 9, 2024
18 of 23 checks passed
@abidlabs abidlabs deleted the chatbot-examples-error branch October 9, 2024 20:53
@freddyaboulton
Copy link
Collaborator Author

Thanks all!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
v: patch A change that requires a patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants