Skip to content
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

Parsing sparql-10-2-2b.sparql produces results that do not match with sparql-10-2-2b.json #6

Closed
yamalight opened this issue Feb 17, 2015 · 1 comment
Assignees

Comments

@yamalight
Copy link
Contributor

So, parser for some reason omits UNDEF fields for VALUES.

Expected output:

"type": "values",
"values": [
  {
    "?title": "\"SPARQL Tutorial\"",
    "?book": "{undefined}"
  },
  {
    "?title": "{undefined}",
    "?book": "http://example.org/book/book2"
  }
]

Actual output:

"type": "values",
"values": [
  {
    "?title": "\"SPARQL Tutorial\"",
  },
  {
    "?book": "http://example.org/book/book2"
  }
]
@RubenVerborgh
Copy link
Owner

Thanks for reporting. The code behaves fine though. The expected output is actually:

"values": [
  {
    "?title": "\"SPARQL Tutorial\"",
    "?book": undefined
  },
  {
    "?title": undefined,
    "?book": "http://example.org/book/book2"
  }
]

But since undefined is not valid JSON (as you can see above), for the tests, we identify the value undefined by "{undefined}". This is restored back in the test code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants