-
Notifications
You must be signed in to change notification settings - Fork 974
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
deps: use web-time
instead of instant
#5347
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this Darius! Only one remark
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is also a usage of std::time
in protocols/kad/src/kbucket.rs
and misc/memory-connection-limits/src/lib.rs
that should be replaced with wasm-compatible time implementation. Could you handle those in scope of this PR?
Hi. In |
The issue with |
Nice catch on that! |
sorry for the offtop, but do you happen to know if there is any plan for the release which will include this? Or maybe some backport for 0.53? It crashes our node occasionally and since we're on crates already I'd like to avoid git dependencies |
I can imagine a patch release can be done for majority of the crates here while others like kad may fall under 0.54. A PR could be done to backport the web-time change too |
By the way, I included those without checking if they indeed support wasm, but my thinking is that it doesn't hurt to add it, eventually it may end up being useful and it's probably much easier to maintain if every |
This pull request has merge conflicts. Could you please resolve them @dariusc93? 🙏 |
sorry @dariusc93 can you rebase again one last time? |
So after some hours of investigation I found why CI was failing. The
After the above PRs are merged and a new |
Interesting but good catch. Im curious on why there wasnt an error with yamux at runtime when it attempts to use |
…libp2p into refactor/web-time-switch
I think because of these two reasons:
|
…libp2p into refactor/web-time-switch
@jxs Isn't it better to update |
sorry Yianis, I did not understand, van you elaborate? |
Now I'm saying we should do this change: diff --git a/muxers/yamux/Cargo.toml b/muxers/yamux/Cargo.toml
index ddb942489..4d6d655e3 100644
--- a/muxers/yamux/Cargo.toml
+++ b/muxers/yamux/Cargo.toml
@@ -16,7 +16,7 @@ futures = { workspace = true }
libp2p-core = { workspace = true }
thiserror = "1.0"
yamux012 = { version = "0.12.1", package = "yamux" }
-yamux013 = { version = "0.13.1", package = "yamux" }
+yamux013 = { version = "0.13.3", package = "yamux" }
tracing = { workspace = true }
[dev-dependencies] |
This pull request has merge conflicts. Could you please resolve them @dariusc93? 🙏 |
bcd8e51
to
9f95ecb
Compare
web-time
instead of instant
web-time
instead of instant
9f95ecb
to
ed0ce1a
Compare
ah right, thanks! |
thanks for the initiative @dariusc93 and @oblique for investing time into debugging <3 |
See sebcrozet/instant#52 Pull-Request: libp2p#5347.
Description
See sebcrozet/instant#52
Notes & open questions
Change checklist