Comments (20)
A good idea can be making compatibility for personal use on Windows. We can still stick with the existing design since we aimed at a production level web app. Is it possible to disable some trouble functions if Windows platform is detected? Most windows users only need to activate the web app and visualize the topology.
After looking into this, Windows does not have any support for production level WSGI. Or rather, the WSGI do not have any support for windows. What I can do is add the ability to run AGVis in a developer mode, which should work on windows just fine for personal use. It just won't be suitable for a production level environment. I will get back to you on the correct commands to use.
Yes, we can get the OS the user is running with python and create wrappers around certain sections to disable their functionality based on the OS.
from agvis.
After looking into this, Windows does not have any support for production level WSGI. Or rather, the WSGI do not have any support for windows. What I can do is add the ability to run AGVis in a developer mode, which should work on windows just fine for personal use. It just won't be suitable for a production level environment. I will get back to you on the correct commands to use.
from agvis.
A good idea can be making compatibility for personal use on Windows. We can still stick with the existing design since we aimed at a production level web app.
Is it possible to disable some trouble functions if Windows platform is detected? Most windows users only need to activate the web app and visualize the topology.
After looking into this, Windows does not have any support for production level WSGI. Or rather, the WSGI do not have any support for windows. What I can do is add the ability to run AGVis in a developer mode, which should work on windows just fine for personal use. It just won't be suitable for a production level environment. I will get back to you on the correct commands to use.
from agvis.
Navigating into the agvis directory (the one with app.py) and running flask run -p 8810
works on windows. This command does not use the gunicorn server, but instead the built in flask development server.
from agvis.
I can make the agvis run command grab the OS, and run the production server if it is on linux, or the development server if it is being run from Windows, so the user input will be the same no matter what platform.
from agvis.
I can use following command to host the web app:
cd /Users/jinningwang/Documents/work/agvis/agvis/static
python3 -m http.server 8810
but I cannot find file app.py
in AGVis directory.
Navigating into the agvis directory (the one with app.py) and running
flask run -p 8810
works on windows. This command does not use the gunicorn server, but instead the built in flask development server.
from agvis.
You are almost in the right directory. app.py is in the directory above static.
Using cd /Users/jinningwang/Documents/work/agvis/agvis
should get you there.
from agvis.
My bad, I was using the develop
branch...
Maybe you can sync the master and develop? It is more common for develop get ahead of master rather than instead.
You are almost in the right directory. app.py is in the directory above static.
Using
cd /Users/jinningwang/Documents/work/agvis/agvis
should get you there.
from agvis.
My bad, I was using the
develop
branch... Maybe you can sync the master and develop? It is more common for develop get ahead of master rather than instead.
I do not believe I have permissions to sync the develop branch.
from agvis.
Actually, I believe I should have the permissions, I just am not seeing the button I am used to syncing with on the github site. I can just do it manually.
from agvis.
No worry, I've done it manually this time. Later we can do work on develop first and then merge develop into master.
^-^
Actually, I believe I should have the permissions, I just am not seeing the button I am used to syncing with on the github site. I can just do it manually.
from agvis.
Yes, I can do that haha.
from agvis.
Another error on my end,
"An unexpected error has occured while trying to start AGVis: [Errno 2] No such file or directory: 'gunicorn'"
from agvis.
Is this on Windows or Linux?
from agvis.
Is this on Windows or Linux?
Darwin, so I guess it's a unix-like one. I'm using MacOS with conda.
from agvis.
I was told by Nicholas that we did not support MacOS. Did AGVis work on MacOS in the past?
Can you try running the flask command flask run -p 8810
? This will tell me if it is an issue with gunicorn specifically.
You should be able to run the AGVis environment through docker as well without problems in the mean time. It loads a Debian distribution in the container so there are no OS conflicts. I have included instructions if you need. Since I am not used to MacOS commands, the actual commands might differ.
From the agvis directory:
- Run
./go.sh build
- Run
tmux
- Run
./go.sh dev2
- Go to
http://localhost:8810/
in your browser - Run the loaded ANDES command in the bottom panel
- When finished, run
tmux detach
- Then clean the docker images and open ports with
./go.sh clean
Here is the youtube tutorial if you need Tutorial
from agvis.
It could also be that the required packages haven't been installed. Gunicorn requires a new package. I included this in the requirements.txt folder, so running python3 -m pip install -e .
or pip install -r requirements.txt
might do the trick.
from agvis.
Zack, thanks. After reinstalling the dependencies, it works well now.
from agvis.
Awesome! I am happy to know it works correctly on MacOS too.
from agvis.
I am going to close this issue since it has been solved.
from agvis.
Related Issues (20)
- UI: Static Results (AMS) - Visualization enhancement HOT 8
- Visualization enhancement: Customized buttons label HOT 1
- Functionality: Using Python Code for Interactive AGVis Web Sessions
- Documentation: AGVis Animations
- Functionality: Low performance with MS Edge browser HOT 3
- UI: Add Legend Bar to Dynamic Results Visualization
- Add Transparency Options for Animations
- Functionality: Integrate with Leaflet flexibility HOT 2
- UI: Overall UI for MultiLayer
- Visualization Enhancement: Add loading indicator when generating simulation
- Multilayer attempts to use playback bar before it is initialized. HOT 1
- Documentation: Compress Image File Size
- Documentation: Javascript File Commenting
- Visualization Enhancement: support Toggle Bus Labels through MultiLayer
- Does AGVIS support substation oneline diagram? HOT 2
- Docker usage issue with version 3.2.1.post46+g8f69adc HOT 6
- Improve Agvis GitHub Workflow HOT 1
- Add Unittests to the agvis test function
- Visualization enhancement: base-map switch and map zoom-in limitation HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from agvis.