5 ms·
`request` itself isn't an awaitable, whereas the `data` property and `get_json` method both return awaitables (https://gitlab.com/pgjones/quart/blob/master/quar
by pgjones 8y ago
`request` itself isn't an awaitable, whereas the `data` property and `get_json` method both return awaitables (https://gitlab.com/pgjones/quart/blob/master/quart/wrappers/request.py#L142 https://gitlab.com/pgjones/quart/blob/master/quart/wrappers/...). I think these are probably things that become second nature through usage.
The routes don't have to be async as Quart will wrap them in a coroutine anyway. However I'm not sure there is any advantage to not adding the async keyword.
Thanks, I need to learn how pipenv works.
- bb88 8y agoPipenv is not bad. I switched to it in about 30 minutes. To start a new project: pipenv --three To add packages: pipenv install <package> pipenv install -d <development packages> pipenv install -r requirements.txt Then check in your Pipfile and Pipfile.lock. When someone makes a fresh checkout, they cd to where the Pipfile and Pipfile.lock are and run: pipenv install When you're ready to update your dependencies do the following: rm Pipfile.lock pipenv update (-d to load development packages) To get a shell, cd to where the Pipfile of your project is: pipenv shell To run something in the virtualenv when the virtualenv is not activated: pipenv run <command>