pallets / quart

An async Python micro framework for building web applications.
https://quart.palletsprojects.com
MIT License
3.01k stars 164 forks source link

AttributeError: 'Config' object has no attribute 'from_json' #314

Closed khteh closed 10 months ago

khteh commented 10 months ago
import quart_flask_patch, json, logging, os
from quart import Quart, request
    app = Quart(__name__, template_folder='view/templates', static_url_path='', static_folder='view/static')
    app.config.from_json("/etc/pythonrestapi_config.json", "r")

Environment:

pgjones commented 10 months ago

from_json was deprecated a while back, use from_file("/etc/pythonrestapi_config.json", json.load) instead