-
Notifications
You must be signed in to change notification settings - Fork 1
156 lines (132 loc) · 3.77 KB
/
Copy pathperformance.yml
File metadata and controls
156 lines (132 loc) · 3.77 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
name: Performance Validation
on:
workflow_dispatch:
inputs:
e2e_rows:
description: "Large-load E2E row count"
required: true
default: "100000"
type: choice
options:
- "100000"
- "250000"
e2e_suite:
description: "Isolated E2E suite to run"
required: true
default: "data"
type: choice
options:
- data
- interactions
- toolbar
- all-isolated
schedule:
- cron: "0 8 * * 1"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-performance
cancel-in-progress: true
jobs:
frontend-bench:
runs-on: ubuntu-latest
defaults:
run:
shell: bash
steps:
- name: Checkout streamlit-pivot-table code
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: "recursive"
fetch-depth: 2
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "npm"
cache-dependency-path: "**/package-lock.json"
- name: Install frontend dependencies
run: |
cd streamlit_pivot/frontend
npm ci
- name: Run frontend bench regression check
run: |
cd streamlit_pivot/frontend
npm run bench:check
python-perf:
runs-on: ubuntu-latest
defaults:
run:
shell: bash
steps:
- name: Checkout streamlit-pivot-table code
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: "recursive"
fetch-depth: 2
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: "pip"
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -e ".[devel,with-streamlit]"
- name: Run Python performance harness
run: python tests/perf_benchmark.py
large-e2e:
runs-on: ubuntu-latest
if: github.event_name == 'workflow_dispatch' || github.event_name == 'schedule'
defaults:
run:
shell: bash
steps:
- name: Checkout streamlit-pivot-table code
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: "recursive"
fetch-depth: 2
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "npm"
cache-dependency-path: "**/package-lock.json"
- name: Install frontend dependencies
run: |
cd streamlit_pivot/frontend
npm ci
- name: Build frontend
run: |
cd streamlit_pivot/frontend
npm run build
- name: Build the package
run: |
python -m venv venv
source venv/bin/activate
pip install --upgrade pip setuptools wheel build
python -m build
- name: Install Python test dependencies
run: |
source venv/bin/activate
pip install --upgrade pip
pip install -r e2e_playwright/test-requirements.txt
python -m playwright install --with-deps
- name: Run isolated large-load E2E
run: |
source venv/bin/activate
rows="${{ github.event.inputs.e2e_rows }}"
suite="${{ github.event.inputs.e2e_suite }}"
if [[ -z "$rows" ]]; then
rows="100000"
fi
if [[ -z "$suite" ]]; then
suite="data"
fi
python scripts/run_large_e2e_matrix.py --rows "$rows" --suite "$suite"