-
Notifications
You must be signed in to change notification settings - Fork 185
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
WIP: Improved Python bindings #3829
Merged
Merged
Commits on Oct 14, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 68a00c4 - Browse repository at this point
Copy the full SHA 68a00c4View commit details
Commits on Oct 15, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 9d3c682 - Browse repository at this point
Copy the full SHA 9d3c682View commit details -
New: Enable "fastdeps" in SWIG
This option generates a Python binding that executes the proxied C++ code faster. Adding the "olddeps" option generates a Python proxy with the correct method signatures so that calling code can treat it like Python, but the actual call is done with the proxied property. Note that another option, "builtin" was also tried, but this broke existing implementations so it was not suitable. For a comparison of the different methods see: https://www.swig.org/Doc4.2/Python.html#Python_optimization
Configuration menu - View commit details
-
Copy full SHA for e821671 - Browse repository at this point
Copy the full SHA e821671View commit details -
Unlike the verovio.i file, where the type hints were in the proxy, but no other "direct" methods were typed, the .pyi file contains type hints for all the methods in the Python Verovio binding. The py.typed file signals that this package is typed. See: https://peps.python.org/pep-0561/
Configuration menu - View commit details
-
Copy full SHA for 2d90bda - Browse repository at this point
Copy the full SHA 2d90bdaView commit details -
Fixed: Modify the SWIG bindings
- Added a few methods to ignore that were anyway broken in the Python package and that used ostream arguments (difficult to know what type of data Python expects here) - The first argument for class methods is, by convention, 'self'. Modified this since the .pyi file used self for the "automatically" proxied code, and "toolkit" for the ones from the .i file. - Made "xml_id" consistent with "xmlId" arguments in the automatically-proxied code. - Added a proxy for "ValidatePAEFile" that turns the return string into a Python dictionary (same as "ValidatePAE")
Configuration menu - View commit details
-
Copy full SHA for 442ed3e - Browse repository at this point
Copy the full SHA 442ed3eView commit details -
Configuration menu - View commit details
-
Copy full SHA for 3d69d1f - Browse repository at this point
Copy the full SHA 3d69d1fView commit details -
Configuration menu - View commit details
-
Copy full SHA for d1fcace - Browse repository at this point
Copy the full SHA d1fcaceView commit details -
As far as we know, this is no longer necessary?
Configuration menu - View commit details
-
Copy full SHA for 4be3859 - Browse repository at this point
Copy the full SHA 4be3859View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4068b7d - Browse repository at this point
Copy the full SHA 4068b7dView commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.