Metadata-Version: 2.1
Name: fastapi_exception
Version: 0.0.1
Summary: FastAPI Event
Project-URL: Homepage, https://github.com/megatron-global/fastapi-exception
Project-URL: Bug Tracker, https://github.com/megatron-global/fastapi-event/issues
Author-email: Dzung Nguyen <dung@megatron-solutions.com>
License-File: LICENSE
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.10
Description-Content-Type: text/markdown

# FastAPI Exception

### Setup python environment

```shell
python3 -m venv venv
```

### Active the python environemt

```shell
. venv/bin/activate
```

### Install requirements

```shell
pip install -r requirements.txt
```

## How to use

1. Set global app env

```python
from fastapi import FastAPI
from fastapi_global_variable import GlobalVariable

app = FastAPI(title="Application")

GlobalVariable.set('app', app)
```

2. Init FastAPI

```python
from config.i18n import i18n_service
from fastapi_exception import FastApiException

FastApiException.init(i18n_service)
```
