-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Using the format!() macro with an async function makes the whole Future non-Send #101650
New issue
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
Comments
Notes:
I'll guess this is |
Fix get_connectivity_html and get_encrinfo futures not being Send. See rust-lang/rust#101650 for more information. Co-authored-by: jikstra <[email protected]>
Fix get_connectivity_html and get_encrinfo futures not being Send. See rust-lang/rust#101650 for more information. Co-authored-by: jikstra <[email protected]>
* add more functions, see changelog for details * add pr number to changelog * clarify doc comment * clarify usage of BasicChat and adjust properties acordingly r10s is right it should only contain what we need of the expensive calls * fix doc typos * run cargo fmt * jsonrpc: add connectivity functions * fix typo * fix typo * Add get_contact_encryption_info and get_connectivity_html Fix get_connectivity_html and get_encrinfo futures not being Send. See rust-lang/rust#101650 for more information. Co-authored-by: jikstra <[email protected]> * Update CHANGELOG * Update typescript files * remove todo from changelog Co-authored-by: jikstra <[email protected]>
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
triage: seems to have been fixed, now we just need someone to add this as a test. |
The issue of yield points in formatting arguments was actually already fixed by #93461, but that was already merged far before this issue was even opened. Looks like this specific issue is not triggered just by the And that was fixed by #107421 |
I tried this code: (minimal reproducible example; for the actual code see chatmail/core#3591)
Playground
Note that we are using,
in a context where the Future needs to be
Send
; only this line without thestring_builder
seems not to be able to reproduce the issue though.I expected to see this happen: That the code behaves the same as
Instead, this happened:
There are two error messages (about line 5 and line 7); this issue is about the first one:
The second error message didn't appear in the original issue in chatmail/core#3591, possibly because there the call to
Box::pin()
and theformat!()
call are in two different crates:Meta
rustc --version --verbose
Probably doesn't matter, anyway:
@rustbot label +A-fmt
The text was updated successfully, but these errors were encountered: