Firelit
🔥👑 FireLit: Streamlit App with Firebase Authentication
Installation
You can install Firelit as a pip package.
pip install firelit
You can check the installation by running the following command in your terminal.
python -c "import firelit as ft; print(ft.__version__)"
Getting started
Configuration
Firelit needs to be connected to a firebase Web App.
You can create a new Web App in your Firebase project by following the steps below.
- TODO
The configuration file can be provided as a firelit_config.yml file in the root directory of your Streamlit app.
apiKey: <apiKey>
authDomain: <authDomain>
databaseURL: <databaseURL>
projectId: <projectId>
storageBucket: <storageBucket>
messagingSenderId: <messagingSenderId>
appId: <appId>
measurementId: <measurementId>
or can be passed to the FirebaseAdmin class as a python dictionary or as a path to the desired configuration file.
import firelit as ft
ft.FirebaseAdmin(config="firelit_config.yml")
or
import firelit as ft
from firelit.utils import load_yaml
config_dict = load_yaml("firelit_config.yml")
Using Firelit (backend)
import firelit as ft
user_info = dict(email="user@gmail.com",
password="firelit")
admin = ft.admin.FirebaseAdmin()
admin.login(user_info["email"], user_info["password"])
Using Firelit (frontend)
import streamlit as st
from firelit.frontend import firelit_login_form
if __name__ == "__main__":
st.set_page_config(
page_title="Firelit Demo App",
page_icon="🔥",
layout="wide",
)
st.title("🔥 Firelit Demo App")
st.subheader("This is a demo app for the Firelit package")
sidebar = st.toggle("Show login form in the sidebar", key="sidebar_login")
admin = firelit_login_form(sidebar=sidebar)
if not admin.authentication_status:
st.write("Please login to continue")
else:
st.write("You are logged in")
st.balloons()
Metadata
Release files for firelit 0.1.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| firelit-0.1.5.tar.gz | 4.6 kB | Without provenance | Details for firelit-0.1.5.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| firelit-0.1.5-py3-none-any.whl | Python 3 | none | any | Details for firelit-0.1.5-py3-none-any.whl |
Total release size: 10.2 kB
Release files / firelit-0.1.5.tar.gz
| Download URL | firelit-0.1.5.tar.gz |
|---|---|
| Size | 4.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
04c88b745526c12c84f66df3e83bd398adcfce2dd82bb044de6fbdc608740898
|
|
BLAKE2b-256 checksum How to use checksums |
fd47dbf3e94f13780891ade5ff0e25a95cc403eb0043678d0ca178405f4685e5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.6.0 CPython/3.11.4 Darwin/22.6.0
|
Release files / firelit-0.1.5-py3-none-any.whl
| Download URL | firelit-0.1.5-py3-none-any.whl |
|---|---|
| Size | 5.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
86286152249c4fd01821b540d7d3f1db3888a2fedba90f9d9d3a711a678ff759
|
|
BLAKE2b-256 checksum How to use checksums |
7bd2cd80cfc12598851931e3ce9b16467605634fea96d575cf95ba03f50ba41b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.6.0 CPython/3.11.4 Darwin/22.6.0
|
Security for firelit 0.1.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.