neat-otel
Runtime-attachment call-site attribution for NEAT.
neat-otel stamps the stable OpenTelemetry code attributes
(code.file.path / code.line.number / code.function.name) onto your
CLIENT / PRODUCER / SERVER spans, so NEAT can fuse a runtime span onto the
exact source file and line that issued it — at symbol grain.
It changes no code. You run your app under the standard OpenTelemetry
auto-instrumentation runner, and neat-otel loads its span processor through
the opentelemetry_post_instrument entry point:
pip install neat-otel
opentelemetry-bootstrap -a install # instrumentations for your libraries
opentelemetry-instrument python app.py # or: opentelemetry-instrument uvicorn app:app
That's it — no import, no edit to your entry point. Point NEAT's OTLP endpoint
at your app the usual way (OTEL_EXPORTER_OTLP_ENDPOINT), run it, and the
spans arrive already carrying their call site.
If you configure OpenTelemetry yourself
If you don't use opentelemetry-instrument, add the processor once, after your
tracer provider is set up:
import neat_otel
neat_otel.register()
register() is idempotent and attaches to the active tracer provider.
Notes
- Fork-safe. The processor is synchronous and holds no background thread, so gunicorn / uvicorn pre-fork workers inherit it without a post-fork hook.
- Fails safe. If OpenTelemetry isn't installed, or a frame can't be read, it degrades to a no-op rather than breaking your app.
- SERVER spans stay route-grained. A framework SERVER span is created before your handler runs, so it isn't attributed to a handler line — that's honest; the outbound CLIENT/PRODUCER spans your code issues carry the call site.
- Turn it off with
NEAT_CALLSITE_DISABLED=1.
Grain
neat-otel is the Python half of NEAT's attachment-first instrumentation
(ADR-232): symbol-grain runtime fusion, delivered without editing your source.
License
Apache-2.0
Metadata
Release files for neat-otel 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| neat_otel-0.1.0.tar.gz | 3.9 kB | Without provenance | Details for neat_otel-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| neat_otel-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for neat_otel-0.1.0-py3-none-any.whl |
Total release size: 8.4 kB
Release files / neat_otel-0.1.0.tar.gz
| Download URL | neat_otel-0.1.0.tar.gz |
|---|---|
| Size | 3.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
08283bf79ce2d59b1b44bf4ce166049d21d6056e554aefdca8f95d975386cea4
|
|
BLAKE2b-256 checksum How to use checksums |
e64948fa407a36eb571dca35252514c5f3d1879afa50e187c41070d38211a7d8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.6
|
Release files / neat_otel-0.1.0-py3-none-any.whl
| Download URL | neat_otel-0.1.0-py3-none-any.whl |
|---|---|
| Size | 4.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
feb4cb9455b4d9bbb2c2a33ab6eb9b7a5f7e98342a3ceda62e8593dfae3a6175
|
|
BLAKE2b-256 checksum How to use checksums |
11449db32909e0fb92c0bf495ffba2cfe412e7944a7473079a01142abf5fddff
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.6
|
Security for neat-otel 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.