Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update parquet-wasm to 0.6.0 #1178

Draft
wants to merge 12 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/actions/init-all/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ runs:
PB_REL: "https://github.com/protocolbuffers/protobuf/releases"
shell: bash

- name: Install wasm-pack
run: yarn global add wasm-pack
shell: bash

- name: Set up
run: make init
shell: bash
1 change: 1 addition & 0 deletions .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ jobs:
with:
node-version-file: .nvmrc
cache: 'yarn'
- run: yarn global add wasm-pack
- run: yarn install --frozen-lockfile

# We require protoc >= 3.20, but Ubuntu 22.04 - the OS that these Github
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
[submodule "streamlit"]
path = streamlit
url = https://github.com/whitphx/streamlit.git
[submodule "vendor/parquet-wasm"]
path = vendor/parquet-wasm
url = https://github.com/kylebarron/parquet-wasm.git
16 changes: 13 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ stlite-lib-wheel := packages/kernel/py/stlite-lib/dist/stlite_lib-0.1.0-py3-none
streamlit_proto := streamlit/frontend/lib/src/proto.d.ts
streamlit_wheel := packages/kernel/py/streamlit/lib/dist/streamlit-1.39.0-cp312-none-any.whl
streamlit_frontend_lib_prod := streamlit/frontend/lib/dist/*
parquet-wasm := vendor/parquet-wasm/pkg/*

export USE_CONSTRAINTS_FILE := false # https://github.com/streamlit/streamlit/blob/1.27.0/.github/workflows/release.yml#L67-L68

Expand All @@ -18,7 +19,7 @@ all: init mountable sharing sharing-editor


.PHONY: init
init: git_submodules venv node_modules
init: git_submodules venv yarn_install

VENV := ./.venv
NODE_MODULES := ./node_modules
Expand All @@ -30,7 +31,7 @@ venv: requirements.dev.txt streamlit/lib/dev-requirements.txt
@echo "\nPython virtualenv has been set up. Run the command below to activate.\n\n. $(VENV)/bin/activate"

.PHONY: yarn_install
yarn_install: git_submodules $(NODE_MODULES)
yarn_install: git_submodules $(parquet-wasm) $(NODE_MODULES)
$(NODE_MODULES):
yarn install --frozen-lockfile

Expand Down Expand Up @@ -142,9 +143,18 @@ $(streamlit_wheel): venv $(streamlit_proto) streamlit/lib/streamlit/**/*.py stre
mkdir -p $(dir $(streamlit_wheel)) && \
cp streamlit/lib/dist/$(notdir $(streamlit_wheel)) $(streamlit_wheel)

.PHONY: parquet-wasm
parquet-wasm: $(parquet-wasm)
$(parquet-wasm): vendor/parquet-wasm/src/*
cd vendor/parquet-wasm && \
wasm-pack build \
--release \
--target bundler \
--no-default-features --features reader

.PHONY: streamlit-frontend-lib
streamlit-frontend-lib: $(streamlit_frontend_lib_prod)
$(streamlit_frontend_lib_prod): yarn_install $(kernel) $(streamlit_proto) streamlit/frontend/lib/src/**/*.ts streamlit/frontend/lib/src/**/*.tsx streamlit/frontend/lib/package.json streamlit/frontend/lib/tsconfig.json
$(streamlit_frontend_lib_prod): yarn_install $(kernel) $(streamlit_proto) $(parquet-wasm) streamlit/frontend/lib/src/**/*.ts streamlit/frontend/lib/src/**/*.tsx streamlit/frontend/lib/package.json streamlit/frontend/lib/tsconfig.json
$(MAKE) -C streamlit frontend-lib-prod

clean:
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"streamlit/frontend",
"streamlit/frontend/app",
"streamlit/frontend/lib",
"vendor/*",
"packages/desktop/samples/*"
],
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion streamlit
1 change: 1 addition & 0 deletions vendor/parquet-wasm
Submodule parquet-wasm added at a41a0d
6 changes: 2 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -17285,10 +17285,8 @@ parenthesis@^3.1.5:
resolved "https://registry.yarnpkg.com/parenthesis/-/parenthesis-3.1.8.tgz#3457fccb8f05db27572b841dad9d2630b912f125"
integrity sha512-KF/U8tk54BgQewkJPvB4s/US3VQY68BRDpH638+7O/n58TpnwiwnOtGIOsT2/i+M78s61BBpeC83STB88d8sqw==

parquet-wasm@^0.4.0:
version "0.4.0"
resolved "https://registry.yarnpkg.com/parquet-wasm/-/parquet-wasm-0.4.0.tgz#1ecbba337d742948b67f8a097ba1d997aaecec4c"
integrity sha512-oAKBE8CE88u/iKfW8afxogZAF/K9CvM9ttENkMuZvSSbXvwVdWa9p3gvHR8eaGwAG4hlakk1v0A2/UrjeLiJog==
parquet-wasm@./vendor/parquet-wasm/pkg:
version "0.6.1"

parse-entities@^2.0.0:
version "2.0.0"
Expand Down
Loading