fluent / fluent/fluent-logger-python
emit() does not call handleError on exception.
- Linguagem predominante
- Python
- Estrelas
- 457
- Forks
- 138
- Métricas de merge de PRs
- Nenhum PR com merge em 30d
Descrição
The [documentation](https://docs.python.org/3.8/library/logging.html#logging.Handler.handleError) for the `handleError` function of `logging.Handler` implies that exceptions should be caught by `emit` and handled by invoking `handleError`. This allows the environment to customer how logging errors are handled.
The fluent logger Handler does not do this: https://github.com/fluent/fluent-logger-python/blob/d1b81bafe442f9cd3059fa07da1fd8de4e92716c/fluent/handler.py#L237
The net result is that exceptions triggered when running the fluent logger (either in format or otherwise) are raised, as opposed to log, which is inconsistent with the rest of the logging Handlers.
The fluent logger should call handleError.
Guia de contribuição
Nenhum guia de contribuição indexado para este repositório
Direção de pesquisa
Comece em fluent/handler.py por volta da linha 237 e compare o comportamento de emit de Handler com a documentação de Python logging.Handler.handleError. Rastreie as exceções levantadas durante a formatação ou o registro e, em seguida, verifique se o fluent logger chama handleError em vez de propagá-las.
Escrita pelo modelo de indexação a partir do texto da issue.
Avaliação
- Stack de tecnologia
- python
- Domínio
- observability
- Tipo de issue
- Bug
- Dificuldade
- 2/5
- Tempo estimado
- 1-3 horas
- Status de atividade
- Estagnada
- Clareza
- Claramente especificada
- Facilidade para iniciantes
- 48/100