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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix "audio used before assigned" bug #2898

Merged
merged 9 commits into from Dec 29, 2022
Merged

Conversation

FelixDombek
Copy link
Contributor

@FelixDombek FelixDombek commented Dec 28, 2022

audio_from_file did not correctly handle the case where the file cannot be opened. This PR fixes e.g. the crash mentioned in TheAlly's Riffusion tutorial.

Description

Please include:

  • relevant motivation
  • a summary of the change
  • which issue is fixed.
  • any additional dependencies that are required for this change.

Closes: # (issue)

Checklist:

  • I have performed a self-review of my own code
  • I have added a short summary of my change to the CHANGELOG.md
  • My code follows the style guidelines of this project
  • I have commented my code in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

A note about the CHANGELOG

Hello 馃憢 and thank you for contributing to Gradio!

All pull requests must update the change log located in CHANGELOG.md, unless the pull request is labeled with the "no-changelog-update" label.

Please add a brief summary of the change to the Upcoming Release > Full Changelog section of the CHANGELOG.md file and include
a link to the PR (formatted in markdown) and a link to your github profile (if you like). For example, "* Added a cool new feature by [@myusername](link-to-your-github-profile) in [PR 11111](https://github.com/gradio-app/gradio/pull/11111)".

If you would like to elaborate on your change further, feel free to include a longer explanation in the other sections.
If you would like an image/gif/video showcasing your feature, it may be best to edit the CHANGELOG file using the
GitHub web UI since that lets you upload files directly via drag-and-drop.

audio_from_file did not correctly handle the case where the file cannot be opened. This PR fixes e.g. the crash mentioned in [TheAlly's Riffusion tutorial](https://theally.notion.site/theally/Quick-n-Dirty-Riffusion-txt2audio-Tutorial-18e57df9ef214c3280efc5998bbf774d).
Copy link
Collaborator

@freddyaboulton freddyaboulton left a comment

Choose a reason for hiding this comment

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

Thank you @FelixDombek ! Will merge once CI passes

@freddyaboulton freddyaboulton merged commit 5c10845 into gradio-app:main Dec 29, 2022
@abidlabs
Copy link
Member

Thanks for the contribution to the library @FelixDombek!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants