Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Remove async-convert #316

Closed
ifsheldon opened this issue Jan 11, 2025 · 2 comments · Fixed by #317
Closed

Remove async-convert #316

ifsheldon opened this issue Jan 11, 2025 · 2 comments · Fixed by #317
Labels
enhancement New feature or request

Comments

@ifsheldon
Copy link
Contributor

As in my commit to the downstream fork async-openai-wasm, it's possible to remove async-convert crate. Without async-convert, we don't need to use async-trait either, which remove extra boxing. This also shrinks binary size. I would be happy to upstream this change in a PR.

@64bit
Copy link
Owner

64bit commented Jan 11, 2025

Thanks for suggestion, PR is welcome!

Also MSRV for this crate will need to change to 1.75? https://blog.rust-lang.org/2023/12/28/Rust-1.75.0.html#whats-in-1750-stable

I don't follow why it shrinks binary size?

@64bit 64bit added the enhancement New feature or request label Jan 11, 2025
@ifsheldon
Copy link
Contributor Author

Also MSRV for this crate will need to change to 1.75?

Yes

I don't follow why it shrinks binary size?

This is my guess with some ground. If you cargo-expand to see the result of an impl block by #[async_trait::async_trait], you'll see some complicated code that is just for boxing, not for the application logic. By removing these auxiliary code, the binary size should be smaller.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants