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

Allow multiple files to upload for Haystack UI #1323

Merged
merged 3 commits into from
Aug 6, 2021
Merged

Allow multiple files to upload for Haystack UI #1323

merged 3 commits into from
Aug 6, 2021

Conversation

MarkusSagen
Copy link
Contributor

When using Haystack UI and streamlit, the default behavior is to upload one file at at time. Trying to upload a new file will override any file one has already uploaded. Streamlit now supports uploading multiple files and may be more intuitive for users of Haystack to use it as the default behavior.

Return type for st.sidebar.file_uploader when accept_multiple_files=True is a list of the files and empty if no files are provided

Proposed changes:

  • Change st.sidebar.file_uploader to default to accept_multiple_files=True to allow for multiple files to be uploaded.

Status (please check what you already did):

  • First draft (up for discussions & feedback)
  • Final code

When using Haystack UI and streamlit, the default behavior is to upload one file at at time and override the file you have already uploaded. Streamlit now supports uploading multiple files and may be more intuitive for users of Haystack to use it as the default behavior.

Return type for `st.sidebar.file_uploader` when `accept_multiple_files=True` is a list of the files and empty if no files are provided
@tholor
Copy link
Member

tholor commented Aug 6, 2021

Great addition! Thanks @MarkusSagen

Streamlit now supports uploading multiple files

What's the minimum version that is needed here so that we can specify it in the requirements?

@MarkusSagen
Copy link
Contributor Author

Thank you @tholor!
Forgot to add that. I'm not quite sure, since they don't specify releases by the issues they resolve, making it a bit tricky to track.
It seems that at least v.0.68.0 would be needed for Streamlit
But there have been some reported issues with uploading multiple files and were resolved in Version 0.76.0

Copy link
Member

@tholor tholor left a comment

Choose a reason for hiding this comment

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

Ok great. That's then the required version is actually not too recent. I believe we had another feature that required 0.84 so I changed it to >= 0.84.0

Ready to merge :)

@MarkusSagen
Copy link
Contributor Author

Great! Thanks :)

@tholor tholor merged commit 60cce4e into deepset-ai:master Aug 6, 2021
@MarkusSagen MarkusSagen deleted the patch-1 branch August 7, 2021 20:36
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

2 participants