Librería para guardar registros de errores y warnings personalizados en json
Project description
Error Visor
Que es?
Es un proyecto destinado a guardar registros personalizados en un archivo json que será utilizado más tarde para visualizarse en una app web de forma localizada y ordenada. Solo es necesaria una sentencia y listo, ya tienes el registro del error en tu app.
Cómo funciona?
Primero instalamos con:
pip install error-visor
Importamos el módulo:
import error_visor as EV
Luego localizamos el lugar desde donde queremos mandar el log. Por ejemplo un bloque exception
y
colocamos el siguiente código:
except Exception as ex:
EV.Logger.err(
EV.Error(
description='Error de muestra',
ex=ex,
priority=EV.Priority.HIGH
)
)
Para una advertencia
/warning
:
except Exception as ex:
EV.Logger.warn(
EV.Warning(
description='Advertencia de muestra',
ex=ex,
follow_me=True
)
)
Y listo, tendremos el registro en un json!
CHANGELOG
v0.0.3
- Fixed: Making of new
logs
dir when that not exists. Really work now! - Added: Warning Type
- Modified: RTypes have have new format to use. RTypes are like:
EV.Error
,EV.Warning
, etc.
v0.0.2
- Fixed: Making of new
logs
dir when that not exists
v0.0.1
- First upload
Project details
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
File details
Details for the file error_visor-0.0.3.tar.gz
.
File metadata
- Download URL: error_visor-0.0.3.tar.gz
- Upload date:
- Size: 3.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a79207d8cc9faab5deb7007604829d6b7680935fab8f34e31e17c90a675658ee |
|
MD5 | 5f84acd98326d6e672edb1ad5c738d1c |
|
BLAKE2b-256 | 10915b3963d7b270c202719376094efe5136d865db596a1ebee663ea03528451 |
File details
Details for the file error_visor-0.0.3-py3-none-any.whl
.
File metadata
- Download URL: error_visor-0.0.3-py3-none-any.whl
- Upload date:
- Size: 3.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 68f5164d1aa5bde2d7391e070eaef1399f5a0e9041e45f633d4a69ffb02b5684 |
|
MD5 | ab9d4ffdbf94eb01f93f5421a7b5b23b |
|
BLAKE2b-256 | 2cf0b2559b980e692ed6c3f60ef828c9ba0b333fdb58a2467377775bb32bcfb3 |