[python] Split examples in Python and enforce executability in CI for python examples#610
[python] Split examples in Python and enforce executability in CI for python examples#610charlesdong1991 wants to merge 4 commits into
Conversation
|
@fresh-borzoni @leekeiabstraction let me know what you think 🙏 |
leekeiabstraction
left a comment
There was a problem hiding this comment.
Thank you @charlesdong1991 for the PR, great idea.
QQ as I do not have access atm: with the proposed changes, what happens if i) method signatures doesn't match and II) assertion fails?
fresh-borzoni
left a comment
There was a problem hiding this comment.
@charlesdong1991 Ty for the PR, makes sense overall, let me merge test changes from python MAP/ROW PR first then
also shall we wire stubtest to test .pyi drift? Probably not in this PR, but since we are talking about drift in examples :)
WDYT?
… bugs Co-authored-by: Cursor <cursoragent@cursor.com>
assertion failures and method signatures mismatches will be caught at run time, to catch signature drift statically (including unexcercised ones), we can use .pyi drift testing... i also add assertions explicitly... wdyt? @leekeiabstraction
yeah, we can do it, nice idea! there are 2 stub issues that are fixed in this PR, and wiring it to pass cleanly needs a bit more work as there are quite some diffs (a bit more than 100)... i can create a focused follow-up pr then if you are fine with that @fresh-borzoni |
@charlesdong1991 I'm fine with this 👍 |
|
added! @fresh-borzoni thanks! PTAL! 🙏 @leekeiabstraction @fresh-borzoni |
fresh-borzoni
left a comment
There was a problem hiding this comment.
@charlesdong1991 Thank you, LGTM 👍
Purpose
Code examples in the Python binding were never executed in CI, so they could silently rot and mislead users learning the system.
This splits the monolithic example into focused, standalone-runnable scripts and adds an automated executability check.
Linked issue: close #607
Tests
All tests passed locally
API and Format
Documentation