Conversation
pelesh
left a comment
There was a problem hiding this comment.
The viz looks more refined and is significant improvement to what it was before.
However, with these changes, launcher cannot open selected case in the visualizer. It looks as if 200-bus case is hard-wired. That is starting from build and install from scratch.
| "scripts": { | ||
| "dev": "vite", | ||
| "start": "yarn dev", | ||
| "start": "node scripts/start.mjs", |
There was a problem hiding this comment.
Please undo this change as it breaks the launcher.
There was a problem hiding this comment.
@pelesh what do you see in launcher. It seemed work fine for me. I will explain it a bit later.
There was a problem hiding this comment.
It gives me default system instead of the one I selected.
There was a problem hiding this comment.
There are 4 scenarios that we can have.
-
You Open Launcher, Go to Visualization Tab, there is no
opflowout.jsonin the viz/data folder. You click Launch Visualization Server (not running opflow or choosing a file to visualize). You should see an empty USA map. (The URL should be like this: http://localhost:5174/) -
You Open Launcher, Go to Visualization Tab, there is an existing
opflowout.jsonin the viz/data folder. You click Launch Visualization Server (not running opflow or choosing a file to visualize). You should see the existingopflowout.jsonfile visualized in USA map. => If you want to remove this behavior I can do it. (the url should be like this: http://localhost:5174/) -
You Open Launcher, Go to Visualization Tab, regardless of there is an existing
opflowout.jsonor not you run opflow and then Click Launch Visualization Server. Aopflowout.jsonwill be created when opflow was running and visualization should show that visualization. (the url should be like this: http://localhost:5174/) -
You Open Launcher, Go to Visualization Tab, and choose Use Existing JSON, and select a json file. Then Click Launch Visualization Server. A visualization should show that json file. (the url should be like this: http://localhost:5176/?file=case_ACTIVSg10k.json when the file you choose was named case_ACTIVSg10k.json)
Please let me know if either of the scenario is providing you wrong outcome. Then I can fix it. Also, whenever a new visualization is launched, a new PORT can used. It does not always be http://localhost:5173/ . I am not sure how to update it in the launcher website after the visualization code is launched.
I have to look again and see if 200-bus case is hard-wired. As far as I remember, if trys to open the opflowout.json as default if nothing is provided. Otherwise it opens the json file provided as command line parameter. I will explain more later. |
I don't think it is desired behavior. If no input is provided, the launcher should open empty viz. In any case, please revert the change I flagged so we can merge. Once removed, we get an appropriate behavior of the launcher. |
Merge request type
Relates to
This MR updates
Summary
This PR fixes the issue when a visualization json file is uploaded (not using
opfllowand/orgicfile to create the visualization file) and it's name is different thanopflowout.json, the defaultvizdoes not render the file. The defaultvizlooks for a filenameopflowout.jsonby default and if it is not present no visualization is shown. So, when a new file is uploaded and named differently the default launch ofvizcannot use the file. To fix the issue, thevizhas been updated to take parameter calledfile=existing.jsonso the urlhttp://localhost:5173?file=existing.jsonlooks for the fileexisting.jsonwhich is uploaded to thedatafolder. This PR adds support to Launch the correct url pattern.