Matthew Coolbeth
Matthew Coolbeth
Something like this function should wrap it for you. ``` (defn deferred->completable-future [d] (let [fut (new CompletableFuture)] (on-realized d #(.complete fut %) #(.completeExceptionally fut %)))) ```
Out of curiosity, what's the reason for `query` returning `List[Either[Error, Record]]` rather than `Either[Error, List[Record]]`?
Do core devs have a preferred strategy for closing this issue? I need this capability for a project at work so I'm thinking about taking a stab at a PR.
Actually it seems like this might be just about as solved as it is ever going to be in Pydantic v2. @ubipo 's code above does indeed raise an exception....