I have two problems that I am trying to solve, and would appreciate your help.
I managed to customise PV glance and everything works fine in development mode.
But when I generate production build and open index.html I cannot load any other supported format except glance and getting error: “Only checked files will be loaded”. More precisely: ''Failed to construct ‘Worker’: Script at ‘file:///…/Paraview_Glance/paraview-glance/dist/itk/WebWorkers/Pipeline.worker.js’ cannot be accessed from origin ‘null’.
How can I fix this? I would expect that solution to this problem could lie in my 2nd question.
2nd question is how can I generate standalone html such as you are providing? I would like to use generated index.html for exporting scene files from Paraview.
Hi, just an update, I’ve generated standalone html, which now I see was rather silly question, but that still does not fix the main problem. Moreover if I try use generated standalone html for export in ParaView, I’m getting blank screen with message “glanceInstance.processURLArgs();”.
Any help with this would be appreciated.
On the first question, all the itk readers won’t be available from the standalone html file when loaded from the file system. Those require separate files that needs to be served via http.
If you run npm run bundle, that will produce that standalone (limited version) of PV Glance
To follow up Seb’s message, you need to host the files in “dist/” on a webserver. If you have Python 3 installed, you can do a quick test of this by going into your “dist/” folder and running “python3 -m http.server”, and then going to “http://localhost:8000”
As for your last problem, do you mean that the page is just a white page with the text “glanceInstance.processURLArgs();”?
Thank you for clarifications. I’ve use standalone-html module. I’ve tested it as Forrest suggested and all works fine, reading all supported formats.
Now only last problem still remains.
Thanks for expanding on Sebastien’s answer. I’ve tested it and it works as supposed to.
Regarding my last problem, yes the page is just white with “glanceInstance.processURLArgs();” text. I’ve generated standalone html with bundle and standalone commands, same result. Tried to export scene with latest stable and nightly build of ParaView, again same result. Do I need some other version?
I just talked to @Forrest_Li and we understand the issue. He is going to see if he can update the generated HTML so that when PV add the data to that file, it won’t insert it in the wrong location.
Thank you both, let me know when you update it. I will try to find some older version of standalone html that was working and see if I can locate where it fails in this newly generated one.