axiom6ai / project_badges

0 stars 0 forks source link

project_badges

this is a server that will return images.

before running:

[i] open ' init .py' in your text editor. l

[ii] change the path on line 6 to match the location of your 'project_ badges/badges/' folder to look like so. g the correct path is necessary to see images in your browser.

to run:

[1] navigate to 'hellotest' directory in terminal

[2] activate virtual environment

$ source venv/bin/activate

which has flask installed and is necessary to run the server.

[3] then, run:

$ python hello.py

you should see something like running on port 3000 which indicates that that the server is running on localhost on port 3000.

[4] you can then visit localhost:3000/badges in your browser to not receive an image, unless you refresh, in which case images will be fed and then denied again, changing every refresh. ll

this is what you will see if you are successful.

lll

if you are not interested, visit localhost:3000/shanghai to be given the information that the weather sucks, regardless of what the weather is actually like or any of the other endpoints in 'routes.py' for their respective images.

if you have flask already installed, the virtual environment may not be necessary.