pinky-streamlit 0.1.0.dev1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pinky_streamlit-0.1.0.dev1/.github/workflows/ci.yml +37 -0
- pinky_streamlit-0.1.0.dev1/.github/workflows/publish.yml +32 -0
- pinky_streamlit-0.1.0.dev1/.github/workflows/release.yml +37 -0
- pinky_streamlit-0.1.0.dev1/.gitignore +50 -0
- pinky_streamlit-0.1.0.dev1/.pre-commit-config.yaml +125 -0
- pinky_streamlit-0.1.0.dev1/.secrets.baseline +127 -0
- pinky_streamlit-0.1.0.dev1/AGENT.md +133 -0
- pinky_streamlit-0.1.0.dev1/CONTEXT.md +17 -0
- pinky_streamlit-0.1.0.dev1/LICENSE +21 -0
- pinky_streamlit-0.1.0.dev1/PKG-INFO +106 -0
- pinky_streamlit-0.1.0.dev1/README.md +53 -0
- pinky_streamlit-0.1.0.dev1/demo/app/.streamlit/config.toml +9 -0
- pinky_streamlit-0.1.0.dev1/demo/app/db.py +306 -0
- pinky_streamlit-0.1.0.dev1/demo/app/icons.py +20 -0
- pinky_streamlit-0.1.0.dev1/demo/app/session.py +35 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/DMSans.woff2 +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_icon-anthropic.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_icon-apple.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_icon-custom.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_icon-duckdb.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_icon-github.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_icon-pinky.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_icon-pythia.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_icon-python.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_icon-streamlit.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_img-anthropic.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_img-apple.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_img-custom.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_img-duckdb.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_img-github.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_img-pinky.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_img-pythia.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_img-python.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/logo_img-streamlit.png +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/static/video_sample.mp4 +0 -0
- pinky_streamlit-0.1.0.dev1/demo/app/streamlit_app.py +34 -0
- pinky_streamlit-0.1.0.dev1/demo/app/streamlit_pages/home.py +444 -0
- pinky_streamlit-0.1.0.dev1/docs/adr/0001-module-scoped-css.md +19 -0
- pinky_streamlit-0.1.0.dev1/docs/adr/0002-streamlit-plotly-version-pin.md +21 -0
- pinky_streamlit-0.1.0.dev1/docs/adr/0003-sks-import-alias.md +22 -0
- pinky_streamlit-0.1.0.dev1/docs/adr/0004-get-session-transparent-resolution.md +22 -0
- pinky_streamlit-0.1.0.dev1/docs/adr/0005-dm-sans-bundled-font.md +40 -0
- pinky_streamlit-0.1.0.dev1/docs/adr/0006-container-runtime-config-toml.md +82 -0
- pinky_streamlit-0.1.0.dev1/docs/explanation/design.md +97 -0
- pinky_streamlit-0.1.0.dev1/docs/explanation/features.md +89 -0
- pinky_streamlit-0.1.0.dev1/docs/index.md +27 -0
- pinky_streamlit-0.1.0.dev1/docs/reference/design_system.md +173 -0
- pinky_streamlit-0.1.0.dev1/docs/reference/design_system_core.md +311 -0
- pinky_streamlit-0.1.0.dev1/docs/reference/design_system_palette.md +274 -0
- pinky_streamlit-0.1.0.dev1/docs/reference/design_system_ui.md +352 -0
- pinky_streamlit-0.1.0.dev1/docs/reference/generated/api/constants.md +5 -0
- pinky_streamlit-0.1.0.dev1/docs/reference/generated/api/db.md +5 -0
- pinky_streamlit-0.1.0.dev1/docs/reference/generated/api/page.md +5 -0
- pinky_streamlit-0.1.0.dev1/docs/reference/generated/api/session.md +5 -0
- pinky_streamlit-0.1.0.dev1/mkdocs.dev.yml +3 -0
- pinky_streamlit-0.1.0.dev1/mkdocs.yml +42 -0
- pinky_streamlit-0.1.0.dev1/pyproject.toml +100 -0
- pinky_streamlit-0.1.0.dev1/scripts/gen_docs.sh +30 -0
- pinky_streamlit-0.1.0.dev1/scripts/hooks/check-docs-up-to-date +53 -0
- pinky_streamlit-0.1.0.dev1/scripts/hooks/check_forbidden_keywords.py +104 -0
- pinky_streamlit-0.1.0.dev1/scripts/hooks/check_typed_api.py +138 -0
- pinky_streamlit-0.1.0.dev1/scripts/hooks/check_zws.py +39 -0
- pinky_streamlit-0.1.0.dev1/scripts/hooks/commit-msg +142 -0
- pinky_streamlit-0.1.0.dev1/src/pinky_streamlit/__init__.py +70 -0
- pinky_streamlit-0.1.0.dev1/src/pinky_streamlit/core/__init__.py +52 -0
- pinky_streamlit-0.1.0.dev1/src/pinky_streamlit/core/constants.py +467 -0
- pinky_streamlit-0.1.0.dev1/src/pinky_streamlit/core/db.py +285 -0
- pinky_streamlit-0.1.0.dev1/src/pinky_streamlit/core/page.py +284 -0
- pinky_streamlit-0.1.0.dev1/src/pinky_streamlit/core/session.py +103 -0
- pinky_streamlit-0.1.0.dev1/src/pinky_streamlit/core/static/fonts/DMSans.woff2 +0 -0
- pinky_streamlit-0.1.0.dev1/src/pinky_streamlit/core/static/style.css +311 -0
- pinky_streamlit-0.1.0.dev1/src/pinky_streamlit/ui_components/__init__.py +3 -0
- pinky_streamlit-0.1.0.dev1/tests/__init__.py +0 -0
- pinky_streamlit-0.1.0.dev1/tests/test_constants.py +256 -0
- pinky_streamlit-0.1.0.dev1/tests/test_db.py +276 -0
- pinky_streamlit-0.1.0.dev1/tests/test_package.py +35 -0
- pinky_streamlit-0.1.0.dev1/tests/test_page.py +99 -0
- pinky_streamlit-0.1.0.dev1/tests/test_page_telemetry.py +123 -0
- pinky_streamlit-0.1.0.dev1/tests/test_session.py +54 -0
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main, develop]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main, develop]
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
ci:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
|
|
13
|
+
steps:
|
|
14
|
+
- uses: actions/checkout@v4
|
|
15
|
+
|
|
16
|
+
- name: Set up Python 3.11
|
|
17
|
+
uses: actions/setup-python@v5
|
|
18
|
+
with:
|
|
19
|
+
python-version: "3.11"
|
|
20
|
+
|
|
21
|
+
- name: Install dependencies
|
|
22
|
+
run: pip install -e ".[dev]"
|
|
23
|
+
|
|
24
|
+
- name: Lint
|
|
25
|
+
run: ruff check src/ tests/
|
|
26
|
+
|
|
27
|
+
- name: Format check
|
|
28
|
+
run: ruff format --check src/ tests/
|
|
29
|
+
|
|
30
|
+
- name: Type check
|
|
31
|
+
run: mypy src/pinky_streamlit/
|
|
32
|
+
|
|
33
|
+
- name: Security scan
|
|
34
|
+
run: bandit -r src/pinky_streamlit/ -ll
|
|
35
|
+
|
|
36
|
+
- name: Tests
|
|
37
|
+
run: pytest
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
name: Publish to PyPI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- "v*.dev*"
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
publish:
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
env:
|
|
12
|
+
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
|
|
13
|
+
permissions:
|
|
14
|
+
contents: read
|
|
15
|
+
id-token: write # required for trusted publishing (OIDC)
|
|
16
|
+
|
|
17
|
+
steps:
|
|
18
|
+
- uses: actions/checkout@v4
|
|
19
|
+
|
|
20
|
+
- name: Set up Python 3.11
|
|
21
|
+
uses: actions/setup-python@v5
|
|
22
|
+
with:
|
|
23
|
+
python-version: "3.11"
|
|
24
|
+
|
|
25
|
+
- name: Install build
|
|
26
|
+
run: pip install build
|
|
27
|
+
|
|
28
|
+
- name: Build wheel and sdist
|
|
29
|
+
run: python -m build
|
|
30
|
+
|
|
31
|
+
- name: Publish to PyPI
|
|
32
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
on:
|
|
3
|
+
push:
|
|
4
|
+
branches: [main]
|
|
5
|
+
jobs:
|
|
6
|
+
release:
|
|
7
|
+
runs-on: ubuntu-latest
|
|
8
|
+
env:
|
|
9
|
+
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
|
|
10
|
+
permissions:
|
|
11
|
+
contents: write
|
|
12
|
+
id-token: write
|
|
13
|
+
steps:
|
|
14
|
+
- uses: actions/checkout@v4
|
|
15
|
+
- name: Read version
|
|
16
|
+
id: version
|
|
17
|
+
run: echo "version=$(grep '^version' pyproject.toml | cut -d'"' -f2)" >> $GITHUB_OUTPUT
|
|
18
|
+
- name: Guard — no .dev version on main
|
|
19
|
+
run: |
|
|
20
|
+
if [[ "${{ steps.version.outputs.version }}" == *".dev"* ]]; then
|
|
21
|
+
echo "❌ version .dev sur main — bumper la version avant de merger"
|
|
22
|
+
exit 1
|
|
23
|
+
fi
|
|
24
|
+
- name: Create tag
|
|
25
|
+
run: |
|
|
26
|
+
git tag "v${{ steps.version.outputs.version }}"
|
|
27
|
+
git push origin "v${{ steps.version.outputs.version }}"
|
|
28
|
+
- name: Set up Python 3.11
|
|
29
|
+
uses: actions/setup-python@v5
|
|
30
|
+
with:
|
|
31
|
+
python-version: "3.11"
|
|
32
|
+
- name: Install build
|
|
33
|
+
run: pip install build
|
|
34
|
+
- name: Build
|
|
35
|
+
run: python -m build
|
|
36
|
+
- name: Publish to PyPI
|
|
37
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
# Python
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*.pyo
|
|
5
|
+
*.pyd
|
|
6
|
+
*.egg
|
|
7
|
+
*.egg-info/
|
|
8
|
+
dist/
|
|
9
|
+
build/
|
|
10
|
+
.eggs/
|
|
11
|
+
*.whl
|
|
12
|
+
.venv/
|
|
13
|
+
env/
|
|
14
|
+
venv/
|
|
15
|
+
|
|
16
|
+
# Testing & coverage
|
|
17
|
+
.pytest_cache/
|
|
18
|
+
.coverage
|
|
19
|
+
.coverage.*
|
|
20
|
+
htmlcov/
|
|
21
|
+
|
|
22
|
+
# Pre-commit
|
|
23
|
+
.pre-commit-cache/
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
# Type checking
|
|
27
|
+
.mypy_cache/
|
|
28
|
+
|
|
29
|
+
# Ruff
|
|
30
|
+
.ruff_cache/
|
|
31
|
+
|
|
32
|
+
# IDEs
|
|
33
|
+
.vscode/
|
|
34
|
+
.idea/
|
|
35
|
+
*.swp
|
|
36
|
+
*.swo
|
|
37
|
+
|
|
38
|
+
# macOS
|
|
39
|
+
.DS_Store
|
|
40
|
+
**/.DS_Store
|
|
41
|
+
|
|
42
|
+
# Conda
|
|
43
|
+
.conda/
|
|
44
|
+
|
|
45
|
+
# Logs
|
|
46
|
+
*.log
|
|
47
|
+
|
|
48
|
+
# MkDocs
|
|
49
|
+
docs/assets/
|
|
50
|
+
site/
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
---
|
|
2
|
+
# =============================================================================
|
|
3
|
+
# .pre-commit-config.yaml — snowflake-kit-streamlit
|
|
4
|
+
# =============================================================================
|
|
5
|
+
# Install:
|
|
6
|
+
# pip install pre-commit
|
|
7
|
+
# pre-commit install
|
|
8
|
+
# pre-commit install --hook-type commit-msg
|
|
9
|
+
#
|
|
10
|
+
# Update standard hooks:
|
|
11
|
+
# pre-commit autoupdate
|
|
12
|
+
# =============================================================================
|
|
13
|
+
default_install_hook_types: [pre-commit, commit-msg]
|
|
14
|
+
|
|
15
|
+
repos:
|
|
16
|
+
# ── Formatting: trailing spaces + newline ─────────────────────────────────
|
|
17
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
18
|
+
rev: v6.0.0
|
|
19
|
+
hooks:
|
|
20
|
+
- id: trailing-whitespace
|
|
21
|
+
- id: end-of-file-fixer
|
|
22
|
+
- id: check-yaml
|
|
23
|
+
- id: check-toml
|
|
24
|
+
- id: check-merge-conflict
|
|
25
|
+
- id: debug-statements
|
|
26
|
+
|
|
27
|
+
# ── Formatting: Markdown ──────────────────────────────────────────────────
|
|
28
|
+
- repo: local
|
|
29
|
+
hooks:
|
|
30
|
+
- id: mdformat
|
|
31
|
+
name: mdformat
|
|
32
|
+
entry: mdformat
|
|
33
|
+
language: system
|
|
34
|
+
files: ^README\.md$
|
|
35
|
+
|
|
36
|
+
# ── Security: secrets & forbidden files ──────────────────────────────────
|
|
37
|
+
- repo: https://github.com/gitleaks/gitleaks
|
|
38
|
+
rev: v8.30.0
|
|
39
|
+
hooks:
|
|
40
|
+
- id: gitleaks
|
|
41
|
+
|
|
42
|
+
# ── Security: alternative secret detection ────────────────────────────────
|
|
43
|
+
- repo: https://github.com/Yelp/detect-secrets
|
|
44
|
+
rev: v1.5.0
|
|
45
|
+
hooks:
|
|
46
|
+
- id: detect-secrets
|
|
47
|
+
args: ["--baseline", ".secrets.baseline"]
|
|
48
|
+
exclude: ^docs/
|
|
49
|
+
|
|
50
|
+
# ── Python: ruff lint + format ────────────────────────────────────────────
|
|
51
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
52
|
+
rev: v0.15.9
|
|
53
|
+
hooks:
|
|
54
|
+
- id: ruff-check
|
|
55
|
+
args: [--no-fix]
|
|
56
|
+
- id: ruff-format
|
|
57
|
+
args: [--check]
|
|
58
|
+
|
|
59
|
+
# ── Python: type checking ─────────────────────────────────────────────────
|
|
60
|
+
- repo: local
|
|
61
|
+
hooks:
|
|
62
|
+
- id: mypy
|
|
63
|
+
name: mypy
|
|
64
|
+
entry: mypy
|
|
65
|
+
language: system
|
|
66
|
+
types: [python]
|
|
67
|
+
args: [--ignore-missing-imports]
|
|
68
|
+
files: ^src/
|
|
69
|
+
|
|
70
|
+
# ── Python: security ─────────────────────────────────────────────────────
|
|
71
|
+
- repo: local
|
|
72
|
+
hooks:
|
|
73
|
+
- id: bandit
|
|
74
|
+
name: bandit
|
|
75
|
+
entry: bandit
|
|
76
|
+
language: system
|
|
77
|
+
pass_filenames: false
|
|
78
|
+
args: [-r, src/, -ll]
|
|
79
|
+
|
|
80
|
+
# ── Zero-width spaces (copy-paste from Outlook/Teams) ────────────────────
|
|
81
|
+
- repo: local
|
|
82
|
+
hooks:
|
|
83
|
+
- id: check-zws
|
|
84
|
+
name: "[ZWS] Invisible characters (zero-width)"
|
|
85
|
+
entry: python scripts/hooks/check_zws.py
|
|
86
|
+
language: system
|
|
87
|
+
pass_filenames: true
|
|
88
|
+
|
|
89
|
+
# ── Python: typed API guard ───────────────────────────────────────────────
|
|
90
|
+
- repo: local
|
|
91
|
+
hooks:
|
|
92
|
+
- id: check-typed-api
|
|
93
|
+
name: "[TYPED-API] Blocked raw composite annotations in public API"
|
|
94
|
+
entry: python scripts/hooks/check_typed_api.py
|
|
95
|
+
language: system
|
|
96
|
+
types: [python]
|
|
97
|
+
files: ^src/
|
|
98
|
+
|
|
99
|
+
# ── Security: employer keyword filter ────────────────────────────────────
|
|
100
|
+
- repo: local
|
|
101
|
+
hooks:
|
|
102
|
+
- id: check-forbidden-keywords
|
|
103
|
+
name: "[FORBIDDEN] Employer keyword filter"
|
|
104
|
+
entry: python scripts/hooks/check_forbidden_keywords.py
|
|
105
|
+
language: system
|
|
106
|
+
pass_filenames: true
|
|
107
|
+
|
|
108
|
+
# ── Docs up-to-date check ─────────────────────────────────────────────────
|
|
109
|
+
- repo: local
|
|
110
|
+
hooks:
|
|
111
|
+
- id: check-docs-up-to-date
|
|
112
|
+
name: Docs up-to-date (README + AGENT.md + pdoc)
|
|
113
|
+
entry: scripts/hooks/check-docs-up-to-date
|
|
114
|
+
language: script
|
|
115
|
+
stages: [pre-commit]
|
|
116
|
+
pass_filenames: false
|
|
117
|
+
|
|
118
|
+
# ── Commit message format ─────────────────────────────────────────────────
|
|
119
|
+
- repo: local
|
|
120
|
+
hooks:
|
|
121
|
+
- id: commit-msg-format
|
|
122
|
+
name: Commit message format
|
|
123
|
+
entry: scripts/hooks/commit-msg
|
|
124
|
+
language: script
|
|
125
|
+
stages: [commit-msg]
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": "1.5.0",
|
|
3
|
+
"plugins_used": [
|
|
4
|
+
{
|
|
5
|
+
"name": "ArtifactoryDetector"
|
|
6
|
+
},
|
|
7
|
+
{
|
|
8
|
+
"name": "AWSKeyDetector"
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
"name": "AzureStorageKeyDetector"
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"name": "Base64HighEntropyString",
|
|
15
|
+
"limit": 4.5
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
"name": "BasicAuthDetector"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"name": "CloudantDetector"
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"name": "DiscordBotTokenDetector"
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"name": "GitHubTokenDetector"
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"name": "GitLabTokenDetector"
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"name": "HexHighEntropyString",
|
|
34
|
+
"limit": 3.0
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"name": "IbmCloudIamDetector"
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"name": "IbmCosHmacDetector"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"name": "IPPublicDetector"
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
"name": "JwtTokenDetector"
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
"name": "KeywordDetector",
|
|
50
|
+
"keyword_exclude": ""
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"name": "MailchimpDetector"
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
"name": "NpmDetector"
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"name": "OpenAIDetector"
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"name": "PrivateKeyDetector"
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"name": "PypiTokenDetector"
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"name": "SendGridDetector"
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
"name": "SlackDetector"
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"name": "SoftlayerDetector"
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
"name": "SquareOAuthDetector"
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
"name": "StripeDetector"
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
"name": "TelegramBotTokenDetector"
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
"name": "TwilioKeyDetector"
|
|
87
|
+
}
|
|
88
|
+
],
|
|
89
|
+
"filters_used": [
|
|
90
|
+
{
|
|
91
|
+
"path": "detect_secrets.filters.allowlist.is_line_allowlisted"
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"path": "detect_secrets.filters.common.is_ignored_due_to_verification_policies",
|
|
95
|
+
"min_level": 2
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"path": "detect_secrets.filters.heuristic.is_indirect_reference"
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
"path": "detect_secrets.filters.heuristic.is_likely_id_string"
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
"path": "detect_secrets.filters.heuristic.is_lock_file"
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"path": "detect_secrets.filters.heuristic.is_not_alphanumeric_string"
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
"path": "detect_secrets.filters.heuristic.is_potential_uuid"
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
"path": "detect_secrets.filters.heuristic.is_prefixed_with_dollar_sign"
|
|
114
|
+
},
|
|
115
|
+
{
|
|
116
|
+
"path": "detect_secrets.filters.heuristic.is_sequential_string"
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"path": "detect_secrets.filters.heuristic.is_swagger_file"
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
"path": "detect_secrets.filters.heuristic.is_templated_secret"
|
|
123
|
+
}
|
|
124
|
+
],
|
|
125
|
+
"results": {},
|
|
126
|
+
"generated_at": "2026-05-11T21:20:12Z"
|
|
127
|
+
}
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
# AGENT.md — pinky-streamlit
|
|
2
|
+
*Update date : 2026-06-04*
|
|
3
|
+
|
|
4
|
+
Reusable Streamlit in Snowflake components.
|
|
5
|
+
Consumer of `snowflake-kit` (uses `pinky_core.fmt`).
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## What this repo is
|
|
10
|
+
|
|
11
|
+
`pinky-streamlit` is a **Python package** (`src/` layout) providing
|
|
12
|
+
shared building blocks for all Streamlit in Snowflake dashboards in the suite.
|
|
13
|
+
|
|
14
|
+
**Do not duplicate** formatting functions — use `from pinky_core.fmt import ...` directly.
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
## Repository structure
|
|
19
|
+
|
|
20
|
+
Module naming follows the Streamlit API categories — import functions with `sks_` alias to avoid shadowing `st.*`.
|
|
21
|
+
|
|
22
|
+
```
|
|
23
|
+
pinky-streamlit/
|
|
24
|
+
├── src/
|
|
25
|
+
│ └── pinky_streamlit/ ← Python package (one sub-package = one concern)
|
|
26
|
+
│ ├── __init__.py ← public API (re-exports)
|
|
27
|
+
│ └── <sub-package>/ ← each directory is one pure, importable module group
|
|
28
|
+
├── demo/app/ ← standalone demo Streamlit app (app/ convention)
|
|
29
|
+
├── docs/ ← see docs/INDEX.md for the full map
|
|
30
|
+
│ ├── explanation/ ← design.md · features.md
|
|
31
|
+
│ ├── reference/ ← design_system*.md · generated/api/ (never hand-edit)
|
|
32
|
+
│ ├── adr/
|
|
33
|
+
│ ├── how-to/
|
|
34
|
+
│ ├── tutorials/
|
|
35
|
+
│ └── templates/ ← pdoc template (--template-dir)
|
|
36
|
+
├── tests/ ← unit tests (test_<module>.py per module)
|
|
37
|
+
├── scripts/hooks/ ← custom pre-commit hooks
|
|
38
|
+
├── .pre-commit-config.yaml
|
|
39
|
+
├── pyproject.toml
|
|
40
|
+
└── AGENT.md ← this file
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## Stack
|
|
46
|
+
|
|
47
|
+
- Python 3.11
|
|
48
|
+
- `streamlit==1.52.2` — pinned, CSS design system validated on this version
|
|
49
|
+
- `plotly==5.24.1` — pinned, available in Snowflake package catalog
|
|
50
|
+
- `snowflake-snowpark-python` — session and DataFrame API
|
|
51
|
+
- `snowflake-kit` — shared utilities (fmt, security…)
|
|
52
|
+
|
|
53
|
+
<important>
|
|
54
|
+
`streamlit` and `plotly` versions are pinned and validated together.
|
|
55
|
+
Do not upgrade without re-validating the full CSS design system and chart rendering.
|
|
56
|
+
</important>
|
|
57
|
+
|
|
58
|
+
---
|
|
59
|
+
|
|
60
|
+
## Key constraints
|
|
61
|
+
|
|
62
|
+
### Streamlit in Snowflake (SiS) context
|
|
63
|
+
|
|
64
|
+
<important>
|
|
65
|
+
- No file system access beyond `/tmp/`
|
|
66
|
+
- No top-level network calls
|
|
67
|
+
- Session always via `get_active_session()` in production
|
|
68
|
+
- Local dev via `LocalSessionConfig` + `~/.snowflake/connections.toml`
|
|
69
|
+
</important>
|
|
70
|
+
|
|
71
|
+
### Dependency on snowflake-kit
|
|
72
|
+
|
|
73
|
+
<important>
|
|
74
|
+
All date/number/string formatting: use `from pinky_core.fmt import ...`
|
|
75
|
+
Never re-implement what's already in `pinky_core.fmt`.
|
|
76
|
+
</important>
|
|
77
|
+
|
|
78
|
+
### CSS design system
|
|
79
|
+
|
|
80
|
+
<important>
|
|
81
|
+
- `PALETTE` in `constants.py` is the single source of truth for colors
|
|
82
|
+
- Synchronize with the consumer app's `style.css :root` when changing colors
|
|
83
|
+
- CSS class names (e.g. `{accent}-lighter-bg`, `text-sm`) must match `style.css`
|
|
84
|
+
</important>
|
|
85
|
+
|
|
86
|
+
### Deprecated Streamlit properties
|
|
87
|
+
|
|
88
|
+
<important>
|
|
89
|
+
`use_container_width` is deprecated — do not use it in any component.
|
|
90
|
+
Replace with `width="stretch"` for equivalent behavior.
|
|
91
|
+
|
|
92
|
+
```python
|
|
93
|
+
# ❌ Deprecated
|
|
94
|
+
st.dataframe(df, use_container_width=True)
|
|
95
|
+
|
|
96
|
+
# ✅ Current
|
|
97
|
+
st.dataframe(df, width="stretch")
|
|
98
|
+
```
|
|
99
|
+
</important>
|
|
100
|
+
|
|
101
|
+
---
|
|
102
|
+
|
|
103
|
+
## Commit convention
|
|
104
|
+
|
|
105
|
+
Format: `<emoji> <type>(<scope>): <description>`
|
|
106
|
+
|
|
107
|
+
Scopes: `setup` | `core` | `ui` | `demo` | `docs` | `ci` | `tests`
|
|
108
|
+
|
|
109
|
+
See workspace-level CLAUDE.md for the full emoji ↔ type table.
|
|
110
|
+
|
|
111
|
+
---
|
|
112
|
+
|
|
113
|
+
## Agents available (in pinky workspace)
|
|
114
|
+
|
|
115
|
+
| Command | What it does |
|
|
116
|
+
|---------|-------------|
|
|
117
|
+
| `/commit` | Analyse git diff → propose gitmoji commit message |
|
|
118
|
+
| `/yml_audit` | Audit YAML files (comments + PII tags) |
|
|
119
|
+
| `/code_comments` | Add English comments to Python source |
|
|
120
|
+
| `/enrich_readme` | Complete README placeholders |
|
|
121
|
+
| `/explain` | Explain the repo (dev / archi / infra profile) |
|
|
122
|
+
| `/clean_history` | Rewrite git history with clean commits |
|
|
123
|
+
|
|
124
|
+
---
|
|
125
|
+
|
|
126
|
+
## Branch strategy
|
|
127
|
+
|
|
128
|
+
```
|
|
129
|
+
main ← stable, PR required, CI required, no direct push
|
|
130
|
+
develop ← integration, PR required from feature/*, no direct push
|
|
131
|
+
feature/* ← one task = one branch, short-lived
|
|
132
|
+
hotfix/* ← urgent fix branched from main
|
|
133
|
+
```
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# CONTEXT.md — pinky-streamlit
|
|
2
|
+
*Update date : 2026-05-31 13:30*
|
|
3
|
+
|
|
4
|
+
Single source of truth for naming in this repo.
|
|
5
|
+
|
|
6
|
+
| Term (preferred) | Avoid | Definition |
|
|
7
|
+
|---|---|---|
|
|
8
|
+
| `sks_` | — | Import alias prefix for all `pinky_streamlit` functions — avoids shadowing `st.*` |
|
|
9
|
+
| `setup_page()` | `init_page`, `configure_page` | Entry point of every SiS page — injects CSS, font, palette, runs loaders |
|
|
10
|
+
| `get_session()` | `create_session`, `session_factory` | Transparent session resolver: `get_active_session()` in SiS, `LocalSessionConfig` locally |
|
|
11
|
+
| `load_static` | `load_reference` | Cache pattern for data that never changes (lookup tables, static config) |
|
|
12
|
+
| `load_analytic` | `load_kpi`, `load_aggregate` | Cache pattern for aggregates — stale OK for 10 min |
|
|
13
|
+
| `load_crud` | `load_editable` | Cache pattern for editable grids — invalidated on write |
|
|
14
|
+
| `load_nocache` | `load_realtime` | No cache — real-time or post-write refresh |
|
|
15
|
+
| palette | theme, skin | A `Palette` instance from `PALETTES.*` — primary, secondary, tertiary + auto dark variant |
|
|
16
|
+
| `PINKY_LOCAL` | `LOCAL`, `DEV_MODE` | Env var that switches `get_session()` to local DuckDB mode |
|
|
17
|
+
| SiS | SIS, Streamlit Cloud | Streamlit in Snowflake — the Snowflake-hosted Streamlit runtime |
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 pinky-and-co
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: pinky-streamlit
|
|
3
|
+
Version: 0.1.0.dev1
|
|
4
|
+
Summary: Reusable Streamlit in Snowflake components for the pinky suite
|
|
5
|
+
Project-URL: Homepage, https://github.com/pinky-and-co/pinky-streamlit
|
|
6
|
+
Project-URL: Repository, https://github.com/pinky-and-co/pinky-streamlit
|
|
7
|
+
Project-URL: Issues, https://github.com/pinky-and-co/pinky-streamlit/issues
|
|
8
|
+
Author: pinky-and-co
|
|
9
|
+
License: MIT License
|
|
10
|
+
|
|
11
|
+
Copyright (c) 2026 pinky-and-co
|
|
12
|
+
|
|
13
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
14
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
15
|
+
in the Software without restriction, including without limitation the rights
|
|
16
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
17
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
18
|
+
furnished to do so, subject to the following conditions:
|
|
19
|
+
|
|
20
|
+
The above copyright notice and this permission notice shall be included in all
|
|
21
|
+
copies or substantial portions of the Software.
|
|
22
|
+
|
|
23
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
24
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
25
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
26
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
27
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
28
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
29
|
+
SOFTWARE.
|
|
30
|
+
License-File: LICENSE
|
|
31
|
+
Keywords: dashboard,data-engineering,snowflake,streamlit,streamlit-in-snowflake
|
|
32
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
33
|
+
Classifier: Operating System :: OS Independent
|
|
34
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
35
|
+
Classifier: Topic :: Database
|
|
36
|
+
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
37
|
+
Requires-Python: >=3.11
|
|
38
|
+
Requires-Dist: openpyxl
|
|
39
|
+
Requires-Dist: pinky-core
|
|
40
|
+
Requires-Dist: plotly==5.24.1
|
|
41
|
+
Requires-Dist: snowflake-snowpark-python
|
|
42
|
+
Requires-Dist: streamlit==1.52.2
|
|
43
|
+
Provides-Extra: dev
|
|
44
|
+
Requires-Dist: bandit; extra == 'dev'
|
|
45
|
+
Requires-Dist: mkdocs-material>=9.0; extra == 'dev'
|
|
46
|
+
Requires-Dist: mkdocstrings[python]>=0.25; extra == 'dev'
|
|
47
|
+
Requires-Dist: mypy; extra == 'dev'
|
|
48
|
+
Requires-Dist: pre-commit; extra == 'dev'
|
|
49
|
+
Requires-Dist: pytest; extra == 'dev'
|
|
50
|
+
Requires-Dist: pytest-cov; extra == 'dev'
|
|
51
|
+
Requires-Dist: ruff; extra == 'dev'
|
|
52
|
+
Description-Content-Type: text/markdown
|
|
53
|
+
|
|
54
|
+
# pinky-streamlit
|
|
55
|
+
|
|
56
|
+
*Update date : 2026-06-04*
|
|
57
|
+
|
|
58
|
+
Reusable Streamlit in Snowflake components for the pinky suite — session, data loading, palette, UI components.
|
|
59
|
+
|
|
60
|
+
Part of the [pinky-and-co](https://github.com/pinky-and-co) suite.
|
|
61
|
+
|
|
62
|
+
## Install
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
pip install pinky-streamlit
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## Quick start
|
|
69
|
+
|
|
70
|
+
```python
|
|
71
|
+
from pinky_streamlit import get_session, setup_page, PALETTES
|
|
72
|
+
from pinky_streamlit import load_analytic as sks_load_analytic
|
|
73
|
+
|
|
74
|
+
session = get_session()
|
|
75
|
+
messages, main, df = setup_page(
|
|
76
|
+
session=session,
|
|
77
|
+
loaders=[sks_load_analytic],
|
|
78
|
+
palette=PALETTES.PYTHIA,
|
|
79
|
+
)
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## Docs
|
|
83
|
+
|
|
84
|
+
**Explanation**
|
|
85
|
+
|
|
86
|
+
- [Design](docs/explanation/design.md)
|
|
87
|
+
- [Features & roadmap](docs/explanation/features.md)
|
|
88
|
+
|
|
89
|
+
**Design system**
|
|
90
|
+
|
|
91
|
+
- [Overview](docs/reference/design_system.md)
|
|
92
|
+
- [Palette & tokens](docs/reference/design_system_palette.md)
|
|
93
|
+
- [Core (session, db, page)](docs/reference/design_system_core.md)
|
|
94
|
+
- [UI components](docs/reference/design_system_ui.md)
|
|
95
|
+
|
|
96
|
+
**API reference**
|
|
97
|
+
|
|
98
|
+
- [Generated API docs](docs/reference/generated/api/)
|
|
99
|
+
|
|
100
|
+
**Decisions**
|
|
101
|
+
|
|
102
|
+
- [ADRs](docs/adr/)
|
|
103
|
+
|
|
104
|
+
______________________________________________________________________
|
|
105
|
+
|
|
106
|
+
MIT License
|