webEasy, the webserver powered by flask.
remix for the best experience
We’re trying to make a webserver with a bit of help from @jarvis394. It can be found here at:
the source can be found at:
we’re aiming to make it like apache where possible- the purpose is to make web servers easy-to-use.
Why is the python version low?
This project uses requirements.txt, which installs packages using pip (2). So to use flask this way, we have to use python 2.
You can install by pip3 in the console and load with python3, up to you!
Command line options
-h = view available commands
-v = view software version
-c <filename.html> = serve a specific html file, must be inside the
3rd command example = python main.py -c hello.html
Welcome screen template from w3schools
It’s just stopped working - coming up with error:
failed to start application on webserver-test.glitch.me
This is most likely because your project has a code error.
Check your project logs, fix the error and try again.
This is just going to webserver-test.glitch.me.
oh sorry! i was just doing some testing- fixing…
@Pufferfish101007 test it now
I sound really stupid but what exactly does this do?
okay, ever heard of flask? it uses flask to serve html files (like glitch). But this has a small CLI inside main.py. And routes/IP/port options can be set inside the config file. Plus a status page giving you helpful information for debugging.
Not much so far, our plan is to make it like apache in many ways
Oh, I see! It’s like a basic server in nodejs that serves HTML files. This is actually pretty cool; I didn’t know you could set up webservers in Python.
Flask is very neat, its great for people who want to use a framework like express but use python.
Python 2 is reaching end of life so most people won’t use it when their machines support python 3 only, if your code has no print statements it might work.
It’s sad yes, and I know a few companies that are spending time converting code to work for python 3
There is some cool stuff such as optional types to make autocomplete/intelisense not stupid at times.
Luckily we have the 2to3 tool in glitch, so we can try that.
We only use python2 because requirements.txt annoyingly installs using pip2. Instead of 3
Yeah, and flask blueprints made routing in other files easy to use and set up.
If it has no print statements it might work.
Despite the python version being 2, it uses python 3 code. Just need to install using pip3 and it’ll work the same.