📝 Bug: AsyncAPI documentation fails when Confluent uses oauth bearer authentication (#2774)
Describe the bug
When using Confluent Kafka with oauthbearer authentication, the generated AsyncAPI schema is:
"securitySchemes":{"oauthbearer":{"type":"oauth2","$ref":""}}
An empty $ref: "" causes the AsyncAPI React component to attempt file resolution via readFile. This is a FastStream bug in schema generation.
How to reproduce
Include source code:
from faststream.confluent import KafkaBroker
broker = KafkaBroker(
config={ ...config... },
security=SASLOAuthBearer(use_ssl=True)
)
...
Expected behavior
AsyncAPI documentation is correctly generated.
Observed behavior
It fails with a file cannot be read error.
Screenshots
If applicable, attach screenshots to help illustrate the problem.
Environment
Running FastStream 0.6.5 with CPython 3.13.11 on Darwin
Additional context
#bug #good_first_issue #faststream #ag2ai
sent via relator