FastAPI Request Helper
Project description
FastAPI Request helper
How to use
- Set a variable
# user_service.py
from fastapi import FastAPI
from fastapi_global_variable import GlobalVariable
app = FastAPI(title="Application")
GlobalVariable.set('app', app)
- Use variable
from fastapi_global_variable import GlobalVariable
print(GlobalVariable.get_or_fail('app'))
print(GlobalVariable.get('app'))
How to test in testpypi
- Increase the version in
pyproject.toml
- Run command
$ . ./build_and_test.sh
How to publish new version
- Increase the version in
pyproject.toml
- Run command
$ . ./build_and_publish.sh
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for fastapi_request_helper-0.0.6.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | dd60271a4de8ed4b2e372aa993d21cad7123bc12440cd00098db832fc205595b |
|
MD5 | 9a23e10491446e7ad11b4debc37914ca |
|
BLAKE2b-256 | e26841e7af64a9f45afd7a13b6bc7e733ce2f59521b14de529513f5078a4d453 |
Close
Hashes for fastapi_request_helper-0.0.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2e517809e17fc71cf31b17b4ade663c4c971f050416b9b4d2148454e8e5e1e9f |
|
MD5 | 00c75e36d0daee9e3dd3c5a1310e20a5 |
|
BLAKE2b-256 | 4a5bb81cc123909ce2d56215fd879f4dee06d1c9896bce8b4a9835c2bc6c4468 |