api: add login_with_capabilities()#135
Conversation
7ce4649 to
6780a91
Compare
36f01ca to
e956d09
Compare
|
Similar change is possible for |
Hocuri
left a comment
There was a problem hiding this comment.
Looks plausible, though I don't really know this code
| loop { | ||
| let Some(res) = ok_or_unauth_client_err!(self.stream.try_next().await, self) else { |
There was a problem hiding this comment.
This loop will throw away any response that does is not a Done response with the matching id. Is this the expected behavior, or will some other code need these responses?
There was a problem hiding this comment.
Practically when you login there are no other commands pipelined, so nothing should arrive other than LOGIN response. Existing code in run_command_and_check_ok checks responses that have the wrong tag, but also consumes them. Likely the most correct option is to return an error on unexpected response and close the connection afterwards, but practically no server will send unexpected responses and if it does it's the server fault.
e956d09 to
c75f121
Compare
|
But actually, I'm wondering if this PR is needed? I mean, we want to get rid of the is_chatmail capability? |
|
Ah, I guess it's about the other capabilities like |
c75f121 to
33b73c8
Compare
|
There are at least |
Closes #134