FBscribeLogger

raw JSON →
0.1.7 verified Mon Apr 27 auth: no python

FBscribeLogger is a Python logging library that provides structured logging with support for Facebook's scribe logging system. It allows you to log messages in a key-value format and send them to scribe or other log aggregators. The current version is 0.1.7, with a release cadence that appears to be sporadic.

pip install fbscribelogger
error ModuleNotFoundError: No module named 'fbscribelogger'
cause Package not installed or misspelled (e.g., 'fbscribe_logger').
fix
Install correctly: pip install fbscribelogger
error TypeError: __init__() got an unexpected keyword argument 'host'
cause Using wrong class or outdated API. FBscribeLogger may not accept direct host/port.
fix
Check documentation; may need to pass a ScribeHandler or configure via a dict.
error AttributeError: module 'fbscribelogger' has no attribute 'FBscribeLogger'
cause Incorrect import path or version mismatch.
fix
Use: from fbscribelogger import FBscribeLogger
gotcha The library is not actively maintained. It has not been updated since 2020 and may have compatibility issues with newer Python or requests library versions.
fix Consider using a more modern structured logging library like structlog or python-json-logger.
breaking Requires Python >=3.8.1, but the library itself is written for Python 2/3 and may have unicode issues in Python 3.
fix Ensure your environment is Python 3.8.1+ and test logging of non-ASCII characters.
deprecated The Scribe protocol is deprecated at Facebook. The library may still work but is no longer recommended for new projects.
fix Use a standard logging handler or send logs via HTTP to a modern aggregator.

Basic usage: create an FBscribeLogger instance with host and port, then log with extra data.

import logging
from fbscribelogger import FBscribeLogger

logger = FBscribeLogger(host='scribe.example.com', port=1463)
logger.info('Test message', extra={'key': 'value'})