This app helps individuals, friends, and families with decision fatigue to quickly pick great restaurants to dine in, using simple user search input: location address or zipcode.
When a restaurant is picked, the result will display the restaurant name, reason why it's recommended, location of the restaurant, and a vivid picture of the food from the restaurant.
Proper error handling has been added to handle scenarios when there is no user input, and when there is not enough restaurant data from the user chosen location.
An example of this app running on Heroku servers can be found here: https://powerful-eyrie-98502.herokuapp.com/
Prerequisites: Install Python 3.6.
Install source code:
git clone https://github.com/jessicalee127/DineCision.git
cd DineCision/ # all commands below assume you are running them from this repository's root directory
Install package dependencies:
pipenv install -r requirements.txt # then run `pipenv shell` before continuing
# or...
pip3 install -r requirements.txt
# or...
pip install -r requirements.txt
Obtain a Yelp Fusion API Key and store the result in an environment variable called DINECISION_API_KEY
.
Run the app locally:
FLASK_APP=app FLASK_ENV=development flask run
Run DineCision.py
if you wish to run this app via command line only.
Run ui.py
if you wish to run the GUI version of the app from your localhost.
Prerequisites: register for a Heroku account, install the Heroku CLI, and login from the command-line (heroku login
).
One-time, first time only, to provision a new Heroku server:
heroku create
One-time, first time only, to configure environment variables on the server:
heroku config:set DINECISION_API_KEY="abc123" # where "abc123" is your Yelp API Key
Subsequent times, to deploy:
git push heroku master
To test the functions in this app, import pytest
package and run the pytest command line from within the test
directory.
The 5 unit tests covers the 5 functions defined in this app.