Skip to main content

Uma coleção de utilitários para acelerar o desenvolvimento backend em Python com padrões reutilizáveis e produtivos

Project description

🐍 SnakeStack

Python Poetry Pipeline PyPI version License: MIT

Uma coleção de utilitários para acelerar o desenvolvimento backend em Python com padrões reutilizáveis e produtivos.


🎓 Visão Geral

O SnakeStack é uma biblioteca modular que fornece recursos para estruturar projetos Python com boas práticas, extensibilidade e produtividade. Seu primeiro módulo disponibiliza uma stack de logging configurável e extensível, ideal para projetos FastAPI, Flask ou scripts.


🚀 Principais Recursos (v0.1.0)

  • Configuração declarativa de logging com suporte a dictConfig
  • Classe LoggerConfigurator para aplicação e customização dinâmica
  • JsonFormatter pronto para produção (com request_id, trace_id, etc.)
  • Suporte a filtros customizados com ContextVars
  • Extensibilidade: adicione formatters, handlers ou filters personalizados

👀 Exemplo Rápido

import logging
from snakestack.logging import LoggerConfigurator

configurator = LoggerConfigurator()
configurator.apply()

logger = logging.getLogger("my.module")
logger.info("Logging simples funcionando.")

🔧 Instalação

Padrão:

pip install snakestack

Isso instala a lib com suporte a Redis assíncrono (redis>=4.2.0).

pip install snakestack[redis]

Via Poetry:

poetry add snakestack

🌐 Roadmap

Versão Feature
0.1.0 Stack de logging configurável
0.2.0 Decoradores de cache
0.3.0 Consumer com Pull
0.4.0 Consumer com Streaming Pull
0.5.0 Middleware e instrumentação com OpenTelemetry
0.6.0 Handler para exceções padronizadas
0.7.0 Publisher para Google Pub/Sub
0.8.0 Decoradores de Circuit Break

📚 Como contribuir

  1. Faça fork do projeto
  2. Crie uma branch: git checkout -b minha-feature
  3. Instale dependências com poetry install --with dev
  4. Rode os testes: make test
  5. Crie um PR ✨

🪜 Testes e Qualidade

make check     # mypy + ruff
make test      # pytest
make test-ci   # cobertura

✅ Licença

Este projeto é licenciado sob os termos da licença MIT. Veja o arquivo LICENSE para mais detalhes.

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

snakestack-0.11.0.tar.gz (21.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

snakestack-0.11.0-py3-none-any.whl (34.4 kB view details)

Uploaded Python 3

File details

Details for the file snakestack-0.11.0.tar.gz.

File metadata

  • Download URL: snakestack-0.11.0.tar.gz
  • Upload date:
  • Size: 21.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.13.5 Linux/6.11.0-1018-azure

File hashes

Hashes for snakestack-0.11.0.tar.gz
Algorithm Hash digest
SHA256 5c7f1f30f5d16da2c3d88faad39c561a78ed1042101509644a15740d002ff5b4
MD5 be170732967497922a563f6946dd19ca
BLAKE2b-256 aaec1e7097ca73b175a8c7e34c9ec81fcf24a81dbc9838962f46c5d0ef137637

See more details on using hashes here.

File details

Details for the file snakestack-0.11.0-py3-none-any.whl.

File metadata

  • Download URL: snakestack-0.11.0-py3-none-any.whl
  • Upload date:
  • Size: 34.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.13.5 Linux/6.11.0-1018-azure

File hashes

Hashes for snakestack-0.11.0-py3-none-any.whl
Algorithm Hash digest
SHA256 26597aae523daaf11d1cca2c413e2d3d8cef79f8bbd85e09430e5305edc3fdb5
MD5 42d3eaa84564cb3e84d03ec5d0503fba
BLAKE2b-256 2c636328a9bffc2dd247498e2e79aee2109c8d6e2640a607fad7755e835f6360

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page