failing to pass variable from app.py to json