Closed abrisse closed 9 years ago
A bug was introduced in sparql 1.1.7. See the script below:
sparql
require 'sparql' query = <<-eos PREFIX ext:<http://ext.com/1.0#> CONSTRUCT { ?x ?prop ?obj . ?obj rdf:type ext:Subject . } WHERE { ?x rdf:type ext:Subject ; ?prop ?obj . } eos SPARQL::Grammar.parse(query).to_sxp
(prefix ((ext: <http://ext.com/1.0#>)) (construct ((triple ?x ?prop ?obj) (triple ?obj rdf:type ext:Subject)) (bgp (triple ?x rdf:type ext:Subject) (triple ?x ?prop ?obj))))
(prefix ((ext: <http://ext.com/1.0#>)) (construct ((triple ?x ?prop ?obj) (triple ?obj rdf:type ext:Subject)) (bgp (triple ?x rdf:type ext:Subject) (triple ?x <type[#<RDF::Query::Variable:0x1fa12b0(?prop)>]> ?obj))))
See if that fixes the issue you're seeing and I'll push out 1.1.8.
@gkellogg :+1:
A bug was introduced in
sparql
1.1.7. See the script below:1.1.6 - OK
(prefix ((ext: <http://ext.com/1.0#>)) (construct ((triple ?x ?prop ?obj) (triple ?obj rdf:type ext:Subject)) (bgp (triple ?x rdf:type ext:Subject) (triple ?x ?prop ?obj))))
1.1.7 - KO
(prefix ((ext: <http://ext.com/1.0#>)) (construct ((triple ?x ?prop ?obj) (triple ?obj rdf:type ext:Subject)) (bgp (triple ?x rdf:type ext:Subject) (triple ?x <type[#<RDF::Query::Variable:0x1fa12b0(?prop)>]> ?obj))))