-
Notifications
You must be signed in to change notification settings - Fork 560
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
Issue 2283: Add type-review support for SPARQL query results from Graph.query #2320
base: main
Are you sure you want to change the base?
Conversation
This patch is known to be an incomplete implementation. Running `mypy test/test_typing.py` before this patch raised 0 type errors. After just adding the two new tests, 3. After starting the subclasses of Query, 30. References: * RDFLib#2283 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
PRs to V6 is closed until further notice. See this for more details: |
We will be open for PRs again once this is resolved: |
@ajnelson-nist do you want to continue with this PR not that v7.x is out and we are merging PRs again? |
Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
Potentially, adding an assert() addresses the subclass type review, per `@classmethod` docs: > ... If a class method is called for a derived class, the derived class > object is passed as the implied first argument. This patch also reverts the first-draft change to `Graph.query`. References: * https://docs.python.org/3/library/functions.html#classmethod * RDFLib#2283 (comment) Suggested-by: Iwan Aucamp <aucampia@gmail.com> Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
References: * RDFLib#2283 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
I've given this a nudge. Following @aucampia 's suggestion looks promising, but it runs into a circular import issue bringing in The class |
I'm pausing working on this for the time being. Suggestions are welcome. |
Summary of changes
Checklist
the same change.
SELECT
andCONSTRUCT
queriesDESCRIBE
andASK
queries./examples
for new features.CHANGELOG.md
).so maintainers can fix minor issues and keep your PR up to date.