We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug
@dataclass class Input: value: int
@broker.subscriber("in1") async def handle_msg(a: Input) -> None: ...
@dataclass class Input: not_in_schema: str
@broker.subscriber("in2") async def please_good_schema(a: Input) -> None: ...
#/components/schemas
"schemas": { "Input": { "properties": { "value": { "title": "Value", "type": "integer" } }, "required": [ "value" ], "title": "Input", "type": "object" } }
Where is my Input.not_in_schema: str? For example, it will be a problem if I have the same named dataclasses in different packages
Input.not_in_schema: str
How to reproduce
from dataclasses import dataclass from faststream import FastStream from faststream.rabbit import RabbitBroker broker = RabbitBroker() app = FastStream(broker) @dataclass class Input: value: int @broker.subscriber("in1") async def handle_msg(a: Input) -> None: ... @dataclass class Input: not_in_schema: str @broker.subscriber("in2") async def please_good_schema(a: Input) -> None: ...
And/Or steps to reproduce the behavior:
Expected behavior I expect two payload in schema:
value: int
not_in_schema: str
Observed behavior Message "overriding" just ignored, in the schema all handlers use only the first definition of the message
Environment Running FastStream 0.5.15 with CPython 3.12.3 on Linux
Additional context Same problem in the case of handlers + args names duplication:
@broker.subscriber("in1") async def handle_msg(a: int) -> None: ... @broker.subscriber("in2") async def handle_msg(a: str) -> None: ...
"schemas": { "HandleMsg:Message:Payload": { "title": "HandleMsg:Message:Payload", "type": "integer" } }
The text was updated successfully, but these errors were encountered:
Warning should be good solution
Sorry, something went wrong.
No branches or pull requests
Describe the bug
#/components/schemas
Where is my
Input.not_in_schema: str
?For example, it will be a problem if I have the same named dataclasses in different packages
How to reproduce
And/Or steps to reproduce the behavior:
Expected behavior
I expect two payload in schema:
value: int
not_in_schema: str
Observed behavior
Message "overriding" just ignored, in the schema all handlers use only the first definition of the message
Environment
Running FastStream 0.5.15 with CPython 3.12.3 on Linux
Additional context
Same problem in the case of handlers + args names duplication:
The text was updated successfully, but these errors were encountered: