Version 3.16.0
New Features:
Send custom progress updates by adding a gr.Progress
argument after the input arguments to any function. Example:
def reverse(word, progress=gr.Progress()):
progress(0, desc="Starting")
time.sleep(1)
new_string = ""
for letter in progress.tqdm(word, desc="Reversing"):
time.sleep(0.25)
new_string = letter + new_string
return new_string
demo = gr.Interface(reverse, gr.Text(), gr.Text())
Progress indicator bar by @aliabid94 in PR 2750.
- Added
title
argument toTabbedInterface
by @MohamedAliRashad in #2888 - Add support for specifying file extensions for
gr.File
andgr.UploadButton
, usingfile_types
parameter (e.ggr.File(file_count="multiple", file_types=["text", ".json", ".csv"])
) by @dawoodkhan82 in #2901 - Added
multiselect
option toDropdown
by @dawoodkhan82 in #2871
With multiselect
set to true
a user can now select multiple options from the gr.Dropdown
component.
gr.Dropdown(["angola", "pakistan", "canada"], multiselect=True, value=["angola"])
Bug Fixes:
- Fixed bug where an error opening an audio file led to a crash by @FelixDombek in PR 2898
- Fixed bug where setting
default_enabled=False
made it so that the entire queue did not start by @freddyaboulton in PR 2876 - Fixed bug where csv preview for DataFrame examples would show filename instead of file contents by @freddyaboulton in PR 2877
- Fixed bug where an error raised after yielding iterative output would not be displayed in the browser by
@JaySmithWpg in PR 2889 - Fixed bug in
blocks_style
demo that was preventing it from launching by @freddyaboulton in PR 2890 - Fixed bug where files could not be downloaded by @freddyaboulton in PR 2926
Documentation Changes:
- Added a Guide on using Google Sheets to create a real-time dashboard with Gradio's
DataFrame
andLinePlot
component, by @abidlabs in PR 2816 - Add a components - events matrix on the docs by @aliabd in PR 2921
Testing and Infrastructure Changes:
- Deployed PRs from forks to spaces by @freddyaboulton in PR 2895
Breaking Changes:
No changes to highlight.
Full Changelog:
- The
default_enabled
parameter of theBlocks.queue
method has no effect by @freddyaboultonin PR 2876 - Added typing to several Python files in codebase by @abidlabs in PR 2887
- Excluding untracked files from demo notebook check action by @aliabd in PR 2897
- Optimize images and gifs by @aliabd in PR 2922
- Updated typing by @1nF0rmed in PR 2904
Contributors Shoutout:
- @JaySmithWpg for making their first contribution to gradio!
- @MohamedAliRashad for making their first contribution to gradio!
- @1nF0rmed for making their first contribution to gradio!