KitwareMedical / vtk.js-examples

These are a few examples for vtk.js
28 stars 21 forks source link

Can't run the example #7

Open GiovanniTurri opened 7 months ago

GiovanniTurri commented 7 months ago

Hi, thank you so much for this great repo! standalone.html works, but after the npm install (that said there were 157 vulnerabilities (4 low, 52 moderate, 79 high, 22 critical) ), I've tried both '''npm run dev:cone''' and '''npm run dev:image-slicing''' but had this block: '''

vtkjs-example@1.0.0 dev:cone EXAMPLE=cone.js webpack-dev-server --mode=development

(node:5157) [DEP0111] DeprecationWarning: Access to process.binding('http_parser') is deprecated. (Use node --trace-deprecation ... to show where the warning was created) (node:5157) [DEP0111] DeprecationWarning: Access to process.binding('http_parser') is deprecated. ℹ 「wds」: Project is running at http://localhost:8080/ ℹ 「wds」: webpack output is served from / ℹ 「wds」: Content not from webpack is served from /home/tesla/EsempioVtkGit/vtk.js-examples/dist node:internal/crypto/hash:68 this[kHandle] = new _Hash(algorithm, xofLen); ^

Error: error:0308010C:digital envelope routines::unsupported at new Hash (node:internal/crypto/hash:68:19) at Object.createHash (node:crypto:138:10) at module.exports (/home/tesla/EsempioVtkGit/vtk.js-examples/node_modules/webpack/lib/util/createHash.js:90:53) at NormalModule._initBuildHash (/home/tesla/EsempioVtkGit/vtk.js-examples/node_modules/webpack/lib/NormalModule.js:386:16) at handleParseError (/home/tesla/EsempioVtkGit/vtk.js-examples/node_modules/webpack/lib/NormalModule.js:434:10) at /home/tesla/EsempioVtkGit/vtk.js-examples/node_modules/webpack/lib/NormalModule.js:466:5 at /home/tesla/EsempioVtkGit/vtk.js-examples/node_modules/webpack/lib/NormalModule.js:327:12 at /home/tesla/EsempioVtkGit/vtk.js-examples/node_modules/loader-runner/lib/LoaderRunner.js:373:3 at iterateNormalLoaders (/home/tesla/EsempioVtkGit/vtk.js-examples/node_modules/loader-runner/lib/LoaderRunner.js:214:10) at Array. (/home/tesla/EsempioVtkGit/vtk.js-examples/node_modules/loader-runner/lib/LoaderRunner.js:205:4) { opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ], library: 'digital envelope routines', reason: 'unsupported', code: 'ERR_OSSL_EVP_UNSUPPORTED' }

Node.js v21.5.0 '''

Do you think it depends on my version of nodeJs?

Thank you for the help

finetjul commented 7 months ago

What about npm run example Cone ?

GiovanniTurri commented 7 months ago

Thank you @finetjul ! Unfortunately it doesn't work neither. As npm run shows that only "dev:" are available :(

floryst commented 7 months ago

The examples haven't been updated in a while. I will do that when I get the time. In the meantime, you should run the commands like so: NODE_OPTIONS=--openssl-legacy-provider npm run dev:...

MattiaMontanari commented 3 months ago

@floryst I couldn't get it to work. It's unfortunate that this repo is not maintained anymore. I find a bit difficult to find good elementary references for vtk.js. Are you planning to revise this repo? are the any other public repos that replace this one?

floryst commented 3 months ago

I'll update the repo for the newer webpack versions, but the examples won't be updated as much because they're associated with existing tutorials.

MattiaMontanari commented 3 months ago

I'll update the repo for the newer webpack versions, but the examples won't be updated as much because they're associated with existing tutorials.

Are the tutorials available online or only during Kitware official trainings? I guess my question then boils down to: What's the best place to start learning? :-)