-
Notifications
You must be signed in to change notification settings - Fork 27
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
Add web features to the parking_lot
dependency
#225
Conversation
Run local-wasm-pack in release mode *for speed*.
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.
I think the "proper" way to do this in cargo is for each of these crates to have their own wasm-bindgen features, and then to depend on those features only when building for wasm32-unknown-unknown
. That's going to be really painful though, so I'm thinking that we should probably switch from parking_lot
's locks to std::sync
's locks and avoid the issue altogether.
What do you think? I'm not sure parking_lot gets us much except for slightly more readable code.
Well this feature
Also i don't see how conditional compilation in rust is too complicated (please don't listen to me, I had C++ template meta-programing in my homework) |
Thank you again for this! It does locally resolve the chromedriver issue that is happening in CI, so I've cherry-picked these changes onto #226. Hopefully that will get CI unblocked. Replying:
Exactly -- since dyn-cache, moxie, and topo don't know whether they're being run on the web or not, forwarding the feature seems right. While the feature is a no-op on non-web targets right now, that could change. Don't worry about this, I'll take care of it in commits atop yours in #226. EDIT: done
Yep, I don't think stdweb would even work here.
I'm not sure starvation is actually what we want, but it's straightforward enough to pull this fix in and revisit later! |
Thank you again for finding this! I've landed #226 which includes these changes. |
Resolves #218.
The
parking_lot
for wasm32 on stable Rust will panic on attempt of parking thread. This makes it possible to rely on stable version ofparking_lot
either with or without theatomics
wasm32 target feature present. Therefore it is a step towards the stable toolchain (#221). Then the last step would be to disable (maybe conditionally) thenamed-profiles
cargo feature.While similar PR #219 conflicts with #223, this PR won't.