Custom component to perform chunked upload in Streamlit. Based on streamlit-chunked-upload by Ryuya Matsumoto.
Project description
streamlit-chunked-upload
This is a custom component that allows you to split files and send them from your browser to Streamlit.
Installation instructions
pip install streamlit-chunked-upload
Usage instructions
import streamlit as st
from streamlit_chunked_upload import uploader
file = uploader("uploader", key="chunk_uploader", chunk_size=32)
st.write(file)
if file is not None:
st.download_button(
"download",
data=file,
file_name=file.name,
type="primary",
)
About chunk size
When a file is uploaded, a Python script slices the file at the specified chunk size on the browser side and sends it as multiple files to the backend.
It's important to note that chunk size and request size are different.
If you have a constraint such as client_max_body_size, you should set it to a value slightly smaller than the constraint size, such as 31MB if the constraint size is 32MB.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file streamlit_chunked_upload-1.0.2.tar.gz.
File metadata
- Download URL: streamlit_chunked_upload-1.0.2.tar.gz
- Upload date:
- Size: 1.8 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
71495bfbc6e5148925d1450989607f911488ff321c39db08be8388fb38a80c7e
|
|
| MD5 |
fd1daed5f355f2718376edd986c96fa7
|
|
| BLAKE2b-256 |
5d8248fcbb3194b1336184cf2bdd6db4452c3d62b445a4f4aaf25a04761bec8c
|
Provenance
The following attestation bundles were made for streamlit_chunked_upload-1.0.2.tar.gz:
Publisher:
publish.yml on mirzaahmergull/streamlit-chunked-upload
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
streamlit_chunked_upload-1.0.2.tar.gz -
Subject digest:
71495bfbc6e5148925d1450989607f911488ff321c39db08be8388fb38a80c7e - Sigstore transparency entry: 164863488
- Sigstore integration time:
-
Permalink:
mirzaahmergull/streamlit-chunked-upload@86b1422c5269d7ad69a61ab70d2e672f7203a814 -
Branch / Tag:
refs/tags/v1.0.2 - Owner: https://github.com/mirzaahmergull
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@86b1422c5269d7ad69a61ab70d2e672f7203a814 -
Trigger Event:
release
-
Statement type:
File details
Details for the file streamlit_chunked_upload-1.0.2-py3-none-any.whl.
File metadata
- Download URL: streamlit_chunked_upload-1.0.2-py3-none-any.whl
- Upload date:
- Size: 1.8 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3662e5dcd411e17078f840375ec5a062a80b45de3be35c2dccda951245441bab
|
|
| MD5 |
3eec0858f3556ea5506719f52374a2be
|
|
| BLAKE2b-256 |
c12f4ccbcd5edce549cfb6abac811eba8d3507cb9b002d880132195f3c946dda
|
Provenance
The following attestation bundles were made for streamlit_chunked_upload-1.0.2-py3-none-any.whl:
Publisher:
publish.yml on mirzaahmergull/streamlit-chunked-upload
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
streamlit_chunked_upload-1.0.2-py3-none-any.whl -
Subject digest:
3662e5dcd411e17078f840375ec5a062a80b45de3be35c2dccda951245441bab - Sigstore transparency entry: 164863494
- Sigstore integration time:
-
Permalink:
mirzaahmergull/streamlit-chunked-upload@86b1422c5269d7ad69a61ab70d2e672f7203a814 -
Branch / Tag:
refs/tags/v1.0.2 - Owner: https://github.com/mirzaahmergull
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@86b1422c5269d7ad69a61ab70d2e672f7203a814 -
Trigger Event:
release
-
Statement type: