Skip to content

Commit abd1665

Browse files
python stubs working (#8035)
* commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * commit python types stubs Signed-off-by: Jessie Frazelle <[email protected]> * chore(stubs): auto-update PyO3 .pyi --------- Signed-off-by: Jessie Frazelle <[email protected]> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 parent 98afc38 commit abd1665

File tree

16 files changed

+1111
-276
lines changed

16 files changed

+1111
-276
lines changed

.github/workflows/update-python-stubs.yml

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -34,26 +34,15 @@ jobs:
3434
uses: PyO3/maturin-action@v1 # Rust + Python + maturin
3535
with:
3636
working-directory: rust/kcl-python-bindings
37-
- name: Install deps & dev-install the crate
38-
run: |
39-
pip install pyo3-stubgen
40-
pip install --no-cache-dir --editable ./rust/kcl-python-bindings
41-
# ------------------------------------------------------------
42-
# 2. Re-generate the .pyi
43-
# ------------------------------------------------------------
37+
- uses: taiki-e/install-action@just
4438
- name: Generate stubs
4539
run: |
46-
mkdir -p rust/kcl-python-bindings/stubs
47-
pyo3-stubgen kcl stubs
48-
ls -la stubs
49-
cp stubs/* rust/kcl-python-bindings/stubs/
50-
# ------------------------------------------------------------
51-
# 3. Commit & push if anything changed
52-
# ------------------------------------------------------------
40+
cd rust
41+
just python-stubs
5342
- name: Check for diff
5443
id: git-status
5544
run: |
56-
git add rust/kcl-python-bindings/stubs/*.pyi
45+
git add rust/kcl-python-bindings/*.pyi
5746
if git diff --cached --quiet; then
5847
echo "changed=false" >> "$GITHUB_OUTPUT"
5948
else

flake.lock

Lines changed: 52 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)