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

dataset().has crashes #57

Open
jeswr opened this issue May 14, 2022 · 0 comments
Open

dataset().has crashes #57

jeswr opened this issue May 14, 2022 · 0 comments

Comments

@jeswr
Copy link

jeswr commented May 14, 2022

Hi @blake-regalia - thanks for resolving #55. I just tried running an evaluation on the new release - but am running into some problems.

I should note that this problem occurs regardless of whether or not I have added the relevant quad to the dataset.

Code:

const dataset = require('@graphy/memory.dataset.fast');
import { Quad, NamedNode } from 'n3';

const d = dataset();

d.has(
  new Quad(
    new NamedNode('http://eulersharp.sourceforge.net/2009/12dtb/test#ind'),
    new NamedNode('http://www.w3.org/1999/02/22-rdf-syntax-ns#type'),
    new NamedNode('http://eulersharp.sourceforge.net/2009/12dtb/test#N0'),
  )
);

Error

jeswr@debian:~/newn/rdfjs-reasoner$ ts-node graphy-test.ts 
/home/jeswr/newn/rdfjs-reasoner/node_modules/@graphy/memory.dataset.fast/main.js:2728
                let svt_graph = g_quad.graph.concise();
                               ^
TypeError: g_quad.graph.concise is not a function
    at FastDataset.has (/home/jeswr/newn/rdfjs-reasoner/node_modules/@graphy/memory.dataset.fast/main.js:2728:32)
    at Object.<anonymous> (/home/jeswr/newn/rdfjs-reasoner/graphy-test.ts:23:3)
    at Module._compile (node:internal/modules/cjs/loader:1105:14)
    at Module.m._compile (/home/jeswr/.nvm/versions/node/v18.1.0/lib/node_modules/ts-node/src/index.ts:1455:23)
    at Module._extensions..js (node:internal/modules/cjs/loader:1159:10)
    at Object.require.extensions.<computed> [as .ts] (/home/jeswr/.nvm/versions/node/v18.1.0/lib/node_modules/ts-node/src/index.ts:1458:12)
    at Module.load (node:internal/modules/cjs/loader:981:32)
    at Function.Module._load (node:internal/modules/cjs/loader:827:12)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:77:12)
    at phase4 (/home/jeswr/.nvm/versions/node/v18.1.0/lib/node_modules/ts-node/src/bin.ts:567:12)

Node Version

jeswr@debian:~/newn/rdfjs-reasoner$ node --version
v18.1.0

Dependency versions

  "dependencies": {
    "@graphy/memory.dataset.fast": "^4.3.5",
    "asynciterator": "^3.4.0",
    "n3": "^1.16.2",
    "rdf-terms": "^1.8.2"
  },
  "devDependencies": {
    "@rdfjs/types": "^1.1.0",
    "@types/jest": "^27.5.1",
    "@types/n3": "^1.10.4",
    "jest": "^28.1.0",
    "pre-commit": "^1.2.2",
    "ts-jest": "^28.0.2",
    "typescript": "^4.6.4"
  }
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

1 participant