Skip to content

Transactions not propagating from middleware #1581

@tekumara

Description

@tekumara

Transactions are not propagating from middleware to the route in FastAPI applications using newer versions of uvicorn or uvloop. This results in the name of the middleware appearing in APM (eg: WebTransaction/Function/main:CanonicalLogMiddleware) rather than the route, and no tracing of the route itself.

The issue is present when using uvicorn>0.35.0 or uvloop>0.21.0. Possibly relevant changes are:

A full repro is available at https://github.com/tekumara/newrelic-bug

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugIncorrect or flawed agent behavior.needs-triageRequires initial review by maintainers.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions