Skip to content

rdflib.Graph.query: Constant False ASK query returns True #3381

@lu-pl

Description

@lu-pl

The following "Constant False" ASK query returns True:

from rdflib import Graph

graph = Graph()
result = graph.query("ask where {filter(false)}")

assert not result.askAnswer

filter(false) should effectively negate the possibility of a solution, so I would consider a result.askAnswer of True actually incorrect.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions