Conversation
- Stub abstract methods, JSON-LD/RDF classes, and `CONTEXT_URLS` - Fix `VERSION` type - Add `__all__` to reduce export from 122 to 79 - Drop allowlist from 82 to 0 Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
bact
marked this pull request as draft
September 21, 2026 07:23
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Coverage reportClick to see where and how coverage changed
This report was generated by python-coverage-comment-action |
||||||||||||||||||||||||
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
bact
marked this pull request as ready for review
September 22, 2026 09:18
JPEWdev
reviewed
Sep 22, 2026
|
|
||
| # fmt: off | ||
| """Format Guard{{ '"' }}{{ '"' }}{{ '"' }} | ||
| __all__ = [ |
Owner
There was a problem hiding this comment.
Is this enforced? Like if we forget one, or add an extra does it make an error?
Collaborator
Author
There was a problem hiding this comment.
Not by Python or by the generated binding itselft, but by the test at test_model_all_matches_public_symbols (new in this PR).
stubtestcatch missing stubtest_model_all_matches_public_symbolscatch missing exports or leaking imports
I hope I getting it right this time. We have fixing this several times. The test should help use catching that.
The idea is import * from of the generated binding should only import things specifically from the binding, and not other things like imports (standard lib or rdflib that the binding happens to import for its internal use) or internal variables (prefixed with _).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
CLOSEDandONTOLOGYto reserved wordsCONTEXT_URLSVERSIONtype__all__to avoid reexport of rdflib and Python's own standard library--
Also replace
@functools.total_orderingwith explicit__le__,__gt__,__ge__:NotImplemented=NotImplementeddefault argument.Allowlist dropped from 82 to 0.
--
model.pyi.j2stub template has to mirrormodel.py.j2template. Tests are added to capture the drift during development.