skrawcz opened a new issue, #607:
URL: https://github.com/apache/burr/issues/607

   # Current behavior
   When it's a union type it complains:
   ```
   union = MyModel1 | MyModel2
   
   @streaming_action.pydantic(
       reads=[...],
       writes=[...],
       state_input_type=..., 
       state_output_type=...
       stream_type=union, # type hint says this is invalid
   )
   ```
   
   because it is typed with :
   
   ```
   stream_type: Union[Type["BaseModel"], Type[dict]],
   ```
   
   ## Library & System Information
   Latest burr
   
   
   # Expected behavior
   It should be fine.
   
   # Additional context
   The fix I think is to expand that stream type to handle a union of BaseModel 
types.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to