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

BlankNodes have value undefinedNaN #55

Open
smessie opened this issue Oct 30, 2024 · 3 comments · Fixed by rdfjs/N3.js#467
Open

BlankNodes have value undefinedNaN #55

smessie opened this issue Oct 30, 2024 · 3 comments · Fixed by rdfjs/N3.js#467
Labels
bug Something isn't working

Comments

@smessie
Copy link
Contributor

smessie commented Oct 30, 2024

When dereferencing some file with blank nodes, the blank nodes have value undefinedNaN:

Quad {
  termType: 'Quad',
  value: '',
  subject: BlankNode { termType: 'BlankNode', value: 'undefinedNaN' },
  predicate: NamedNode {
    termType: 'NamedNode',
    value: 'http://www.w3.org/1999/02/22-rdf-syntax-ns#rest'
  },
  object: BlankNode { termType: 'BlankNode', value: 'undefinedNaN' },
  graph: DefaultGraph { termType: 'DefaultGraph', value: '' }
}

Small reproducible example:

const { rdfDereferencer } = require("rdf-dereference");

async function main() {
    const {data} = await rdfDereferencer.dereference(
        "https://raw.githubusercontent.com/TREEcg/extract-cbd-shape/refs/heads/main/tests/01%20-%20fetching%20a%20shacl%20shape/shacl-shacl.ttl",
        {localFiles: true},
    )

    data.on('data', (quad) => console.log(quad))
        .on('error', (error) => console.error(error))
        .on('end', () => console.log('All done!'));

}

main().catch(console.error);

This contains quads that have blank nodes with value undefinedNaN like the above one.

@rubensworks
Copy link
Owner

@surilindur Didn't we also see errors like these in the VAIA exercises?
Could you have a look at it as well?

@rubensworks
Copy link
Owner

I can reproduce it in comunica with just a construct query, so there's definitely an underlying issue.

@rubensworks
Copy link
Owner

For reference, tracked this down as a problem in N3.js: rdfjs/N3.js#466

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants