-
Notifications
You must be signed in to change notification settings - Fork 993
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
fix: Read environment variable configs in hello_triangle example #6698
fix: Read environment variable configs in hello_triangle example #6698
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.
LGTM, pending accidental .lock changes
(Reminder: please re-request a review from me once the changes are addressed to make sure I see it!)
69b4842
to
d71abfa
Compare
I've removed the accidentally-queued lock file stuff. Might be worth adding another utils method for getting the whole instance descriptor, but we'll see. Not worth blocking this quick fix imho |
I had a spare couple of minutes so I factored the whole thing into the utilities package, hopefully that makes the examples a little more succinct. |
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.
Now that's chefs kiss
Head branch was pushed to by a user without write access
Apologies for re-requesting again. Just had to fix the clippy error |
No worries! |
…-rs#6698) * fix: Read environment variable configs in hello_triangle example * refactor: Add util method for creating entire instance descriptor from env * fix: Fix clippy error/warning about "unneeded `return` statement"
Connections
The hello_triangle doesn't support switching backends, leading to confusing errors like this one: #4247
Description
This adds support for the WGPU_* environment variables to the hello_triangle example, so that backend-specific issues can more quickly be narrowed down and fixes.
Testing
I've tested this manually, not sure if there is a better procedure for automatically testing these things
Checklist
cargo fmt
.taplo format
.cargo clippy
. If applicable, add:--target wasm32-unknown-unknown
--target wasm32-unknown-emscripten
cargo xtask test
to run tests.CHANGELOG.md
. See simple instructions inside file.