📽 Streamlit application powered by a PyScaffold project setup

Overview

Project generated with PyScaffold

streamlit-demo

Streamlit application powered by a PyScaffold project setup.

Work in progress: The idea of this repo is to demonstrate how to package a streamlit app using PyScaffold. Since streamlit currently doesn't support apps as proper Python packages, this example is still suboptimal. Following Github issue was created to improve the current situation.

The structure was created with:

putup --dsproject streamlit-demo -p git_overview \
      -d "Streamlit application powered by a PyScaffold project setup." \
      -u https://github.com/pyscaffold/streamlit-demo

then the actual code was taken from git-overview (MIT-licensed) and changed into a proper Python package layout.

The advantages over the original codebase are:

  1. wheel file for distribution can be easily build with tox -e build,
  2. unit tests can be easily added in the tests folder,
  3. extract-repo is now a shell command (available after installation) instead of a script repo.py,
  4. git_overview is a Python package that could be reused by other Python projects after installation,
  5. all the other advantages of a PyScaffold layout...

Installation & Running the dashboard

In order to set up the necessary environment:

  1. create and activate the environment streamlit-demo with the help of conda:
    conda env create -f environment.yml
    conda activate streamlit-demo
    or use environment.lock.yml to recreate an environment with pinned dependencies.

NOTE: The conda environment will have streamlit-demo installed in editable mode. Some changes, e.g. in setup.cfg, might require you to run pip install -e . again.

  1. run the dashboard with:

    streamlit run scripts/show_dashboard.py
  2. or (optionally) build a docker image and run it with:

    docker build -t local/streamlit-demo:latest .
    docker run -p 8501:8501 local/streamlit-demo:latest
  3. open the dashboard at http://localhost:8501.

Project Organization

├── AUTHORS.md              <- List of developers and maintainers.
├── CHANGELOG.md            <- Changelog to keep track of new features and fixes.
├── CONTRIBUTING.md         <- Guidelines for contributing to this project.
├── Dockerfile              <- Build a docker container with `docker build .`.
├── LICENSE.txt             <- License as chosen on the command-line.
├── README.md               <- The top-level README for developers.
├── docs                    <- Directory for Sphinx documentation in rst or md.
├── environment.yml         <- The conda environment file for reproducibility.
├── pyproject.toml          <- Build configuration. Don't change! Use `pip install -e .`
│                              to install for development or to build `tox -e build`.
├── scripts                 <- Entry-script `show_dashboard.py` for streamlit
├── setup.cfg               <- Declarative configuration of your project.
├── setup.py                <- [DEPRECATED] obsolete way of building and installation.
├── src
│   └── git_overview        <- Actual Python package `git-overview` with the main functionality.
│       ├── __init__.py
│       ├── dashboard.py    <- Layout-function of the actual dashboard.
│       ├── repo.py         <- Functions to download repo data.
│       └── utils.py        <- Some dashboard-related helpers
├── tests                   <- Unit tests which can be run with `pytest`.
├── .coveragerc             <- Configuration for coverage reports of unit tests.
├── .isort.cfg              <- Configuration for git hook that sorts imports.
└── .pre-commit-config.yaml <- Configuration of pre-commit git hooks.

This structure is in strong contrast to the original one:

├── app
│   ├── dashboard.py        <- Dashboard entry-point
│   ├── __init__.py
│   ├── repo.py             <- Script to download repo data
│   └── utils.py            <- Some dashboard-related helpers
├── Dockerfile
├── README.md
└── requirements.txt

Note

This project has been set up using PyScaffold 4.1.1.post1.dev28+g075b76f and the dsproject extension 0.6.1.post28+g91ab61a.

Owner
PyScaffold
Python project template generator with batteries included
PyScaffold
Your Google Recon is Now Automated

GRecon : GRecon (Greei-Conn) is a simple python tool that automates the process of Google Based Recon AKA Google Dorking The current Version 1.0 Run 7

adnane-tebbaa 189 Dec 21, 2022
An async API wrapper for Dress To Impress written in Python.

dti.py An async API wrapper for Dress To Impress written in Python. Some notes: For the time being, there are no front-facing docs for this beyond doc

Steve C 1 Dec 14, 2022
Paprika is a python library that reduces boilerplate. Heavily inspired by Project Lombok.

Image courtesy of Anna Quaglia (Photographer) Paprika Paprika is a python library that reduces boilerplate. It is heavily inspired by Project Lombok.

Rayan Hatout 55 Dec 26, 2022
This package tries to emulate the behaviour of syntax proposed in PEP 671 via a decorator

Late-Bound Arguments This package tries to emulate the behaviour of syntax proposed in PEP 671 via a decorator. Usage Mention the names of the argumen

Shakya Majumdar 0 Feb 06, 2022
Calculator in command line using python programming language

Calculator in command line using python programming language University of the People Python fundamental Chapter 5 Conditionals and recursion The main

mark sikaundi 3 Dec 09, 2021
Tie together `drf-spectacular` and `djangorestframework-dataclasses` for easy-to-use apis and openapi schemas.

Speccify Tie together drf-spectacular and djangorestframework-dataclasses for easy-to-use apis and openapi schemas. Usage @dataclass class MyQ

Lyst 4 Sep 26, 2022
TMTC Commander Core

This commander application was first developed by KSat for the SOURCE project to test the on-board software but has evolved into a more generic tool for satellite developers to perform TMTC (Telemetr

robamu 8 Dec 14, 2022
The Google Assistant on a rotary phone

Google Assistant Rotary Phone Shoutout to my dad who had this idea a year ago and I'm only now getting around to doing it. Notes This is the code used

rydercalmdown 10 Nov 04, 2022
A Classroom Engagement Platform

Project Introduction This is project introduction Setup Setting up Postgres This is the most tricky part when setting up the application. You will nee

Santosh Kumar Patro 1 Nov 18, 2021
A Blender addon to align the origin to the top, center or bottom of a mesh object

Align Origin Blender Addon. Align Origin Blender Addon. What? This simple addon lets you align the origin to the top, center or bottom of a mesh objec

VA79 7 Nov 30, 2022
Some shitty programs just to brush up on my understanding of binary conversions.

Binary Converters Some shitty programs just to brush up on my understanding of binary conversions. Supported conversions formats = "unsigned-binary" |

Tim 2 Jan 09, 2022
Subnet calculator script using python

subnetCalculator Subnet calculator script using python3 Interactive Version Define the subnet variable interactively Use: subnetDict = subnetCalculato

1 Feb 15, 2022
ColabFold / AlphaFold2_advanced on your local PC (or macOS)

LocalColabFold ColabFold / AlphaFold2_advanced on your local PC (or macOS) Installation For Linux Make sure curl and wget commands are already install

Yoshitaka Moriwaki 207 Dec 22, 2022
Functional collections extension functions for Python

pyfuncol pyfuncol Installation Usage API Documentation Compatibility Contributing License A Python functional collections library. It extends collecti

Andrea Veneziano 32 Nov 16, 2022
A self contained invitation management system for gatekeeping.

Invitease Description A self contained invitation management system for gatekeeping. Purpose Serves as a focal point for inviting guests to a venue pr

מעגן מיכאל 7 Jul 19, 2022
A subleq VM/interpreter created by me for no reason

What is Dumbleq? Dumbleq is a dumb Subleq VM/interpreter implementation created by me for absolutely no reason at all. What is Subleq? If you haven't

Phu Minh 2 Nov 13, 2022
an elegant datasets factory

rawbuilder an elegant datasets factory Free software: MIT license Documentation: https://rawbuilder.readthedocs.io. Features Schema oriented datasets

Mina Farag 7 Nov 12, 2022
Gba-free-fonts - Free font resources for GBA game development

gba-free-fonts Free font resources for GBA game development This repo contains m

28 Dec 30, 2022
An OBS script to fuze files together

OBS TEXT FUZE Fuze text files and inject the output into a text source. The Index file directory should be a list of file directorys for the text file

SuperZooper3 1 Dec 27, 2021
A python library what works with numbers.

pynum A python library what works with numbers. Prime Prime class have everithing you want about prime numbers. check_prime The check_prime method is

Mohammad Mahdi Paydar Puya 1 Jan 07, 2022