graypy
Python logging handlers that send messages in the Graylog Extended Log Format (GELF).
Decision gist · record as of 2026-08-14
Yes, if you have a stable, older Graylog deployment and do not need active maintenance. The package is simple, dependency-free for basic use, and permissively licensed. No, if you require support for recent Python versions, current Graylog API changes, or active bug fixes—the dormant status since 2019 means you are on your own for compatibility issues.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires a Graylog server running and accessible at the specified host and port; RabbitMQ handler requires amqp extra and a configured RabbitMQ instance.
- Low install friction with no runtime dependencies for basic use.
- Package is dormant—last release was 2019-09-30 and last commit 2023-10-24—so expect no active maintenance or updates for newer Python versions or Graylog API changes.
License · maintenance · safety
BSD License (permissive) — BSD License (permissive) allows use in most projects without significant restriction, though you should review the full license text for your specific use case.
last release 2019-09-30 (2510 days) · last repo commit 2023-10-24 · 265 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 561,493 downloads/mo, #5,994 on PyPI
Alternatives
Verify before relying
pip install graypy
import logging
import graypy
my_logger = logging.getLogger('test_logger')
my_logger.setLevel(logging.DEBUG)
handler = graypy.GELFUDPHandler('localhost', 12201)
my_logger.addHandler(handler)
my_logger.debug('Hello Graylog.')- Whether the package works reliably with current Graylog versions (3.x and later) given the long dormancy since 2019.
- Compatibility with Python versions released after 2019 (classifiers only list up to 3.7).
- Whether UDP packet loss handling and chunking behavior meet production requirements.
What it is and what it does
graypy is a Python logging handler library that bridges the standard logging module to Graylog servers by formatting log records in GELF and forwarding them over the network. It provides five handler classes—GELFUDPHandler, GELFTCPHandler, GELFTLSHandler, GELFHTTPHandler, and GELFRabbitHandler—each supporting a different transport mechanism. The library automatically includes debugging fields (function name, process ID, thread name) in logs and supports custom fields via LoggerAdapter or Filter classes. It also handles exception tracebacks and GELF UDP message chunking with configurable overflow behavior.
The package has no runtime dependencies for basic UDP/TCP/HTTP use, making it lightweight to install. Optional AMQP support for RabbitMQ-based log forwarding requires the amqp extra. However, the project is dormant—the last release was in September 2019 and the last repository commit in October 2023—so it receives no active maintenance and may not work reliably with recent Graylog or Python versions.
Use it for
- Forward application logs from a Python service to a centralized Graylog server for aggregation and analysis.
- Integrate Django application logging with Graylog by configuring GELFUDPHandler in Django's logging dictConfig.
- Send logs via RabbitMQ instead of UDP to avoid packet loss in high-volume logging scenarios.
- Add custom contextual fields (user ID, request ID, etc.) to logs using LoggerAdapter before forwarding to Graylog.
- Capture and forward exception tracebacks to Graylog as full_message fields for debugging.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, if you have a stable, older Graylog deployment and do not need active maintenance.
The package is simple, dependency-free for basic use, and permissively licensed. No, if you require support for recent Python versions, current Graylog API changes, or active bug fixes—the dormant status since 2019 means you are on your own for compatibility issues.
Install
graypy on PyPI
Before you install
Low install friction with no runtime dependencies for basic use. Package is dormant—last release was 2019-09-30 and last commit 2023-10-24—so expect no active maintenance or updates for newer Python versions or Graylog API changes.
Requires a Graylog server running and accessible at the specified host and port; RabbitMQ handler requires amqp extra and a configured RabbitMQ instance.
License in practice
BSD License (permissive) allows use in most projects without significant restriction, though you should review the full license text for your specific use case.
Quickstart
pip install graypy
import logging
import graypy
my_logger = logging.getLogger('test_logger')
my_logger.setLevel(logging.DEBUG)
handler = graypy.GELFUDPHandler('localhost', 12201)
my_logger.addHandler(handler)
my_logger.debug('Hello Graylog.')
Verify before relying
- Whether the package works reliably with current Graylog versions (3.x and later) given the long dormancy since 2019.
- Compatibility with Python versions released after 2019 (classifiers only list up to 3.7).
- Whether UDP packet loss handling and chunking behavior meet production requirements.
Package facts
| License | BSD License permissive |
| Python support | Not specified |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | None |
| Maintenance | Dormant 2,510 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 561,493 / month, #5,994 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Intended Audience :: DevelopersLicense :: OSI Approved :: BSD LicenseProgramming Language :: PythonProgramming Language :: Python :: 2Programming Language :: Python :: 2.7Programming Language :: Python :: 3Programming Language :: Python :: 3.2Programming Language :: Python :: 3.3Programming Language :: Python :: 3.4Programming Language :: Python :: 3.5Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: Implementation :: CPythonProgramming Language :: Python :: Implementation :: PyPyTopic :: System :: Logging |
Evidence: graypy-2.1.0-py2.py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “graylog logging handler”
- graypyProvides Python logging handlers that format and send log messages to…
- pygelfProvides Python logging handlers that send log messages to Graylog…
- lib-log-richProvides Rich-styled colored console logging with structured…
Give your agent the search over MCP, or paste the wish link into any chat.
More Logging packages
Wraps any iterable to display a real-time progress bar in the terminal or Jupyter notebook, showing iteration count, elapsed time, and estimated time remaining.
Formats Python logging output as JSON, making logs machine-readable for parsing and ingestion into log aggregation tools.
Install it if you need JSON-formatted logs for aggregation or centralized monitoring.
structlog is a structured logging library that lets you emit logs as dictionaries with flexible output formats (JSON, logfmt, console) and integrates with Python's standard logging or runs standalone.
Install it if your application needs JSON or logfmt output, or if you want to add rich context to logs without string formatting.
Loguru provides a pre-configured logger that replaces Python's standard logging with a simpler, zero-boilerplate interface for writing log messages to stderr, files, or custom handlers.
Install it if you want logging to feel natural but with the power, structure that production code needs.
Adds colored output to Python's standard logging module using ANSI escape sequences, with automatic fallback support for Windows terminals.
However, it is abandoned and receives no maintenance, so it will not adapt to future Python changes or platform updates.
wandb is a machine learning experiment tracking and visualization platform that logs metrics, hyperparameters, datasets, and models to a centralized dashboard for monitoring and comparing training runs.
Install it if you need centralized experiment tracking, comparison, and visualization for machine learning projects; skip it if you prefer local-only logging or have…
See also pygelf · python3-logstash · python-logstash · libadvian · logtail-python · google-cloud-appengine-logging · logzio-python-handler · google-cloud-logging · lib-log-rich · cloudwatch