-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Detect references to non-existant messages in Fluent resources #107096
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
Conversation
r? @Nilstrieb (rustbot has picked a reviewer for you, use r? to override) |
cc @davidtwco, @compiler-errors, @JohnTitor, @estebank, @TaKO8Ki |
cc @davidtwco, @compiler-errors, @JohnTitor, @estebank, @TaKO8Ki |
dbf751e
to
9d9b242
Compare
This comment has been minimized.
This comment has been minimized.
@clubby789, is it possible for you to commit a test for this? Maybe with a bad fluent file in https://github.com/rust-lang/rust/tree/master/tests/run-make/translation ? |
9d9b242
to
22e34ce
Compare
Added the test to |
This comment has been minimized.
This comment has been minimized.
4c99ac9
to
e8d335d
Compare
☔ The latest upstream changes (presumably #107187) made this pull request unmergeable. Please resolve the merge conflicts. |
e8d335d
to
bd43c07
Compare
bd43c07
to
89b1f39
Compare
Something like #92565 would help to generate nicer diagnostics but a reference to the file/offending messages is probably the best we can do for now |
I'm happy with this as-is. Thanks for implementing this! @bors r+ |
…=compiler-errors Detect references to non-existant messages in Fluent resources Should help with cases like rust-lang#107091, where `{variable}` (a message reference) is accidentally typed, rather than `{$variable}` (a variable reference) `@rustbot` label +A-translation
Failed in rollup: #107341 (comment) |
89b1f39
to
0ae0d87
Compare
HashMap -> Vec to avoid query instability |
@bors r=compiler-errors |
…=compiler-errors Detect references to non-existant messages in Fluent resources Should help with cases like rust-lang#107091, where `{variable}` (a message reference) is accidentally typed, rather than `{$variable}` (a variable reference) Fixes rust-lang#107370 `@rustbot` label +A-translation
…=compiler-errors Detect references to non-existant messages in Fluent resources Should help with cases like rust-lang#107091, where `{variable}` (a message reference) is accidentally typed, rather than `{$variable}` (a variable reference) Fixes rust-lang#107370 ``@rustbot`` label +A-translation
…iaskrgr Rollup of 9 pull requests Successful merges: - rust-lang#104012 (Improve unexpected close and mismatch delimiter hint in TokenTreesReader) - rust-lang#104252 (Stabilize the const_socketaddr feature) - rust-lang#105524 (Replace libc::{type} with crate::ffi::{type}) - rust-lang#107096 (Detect references to non-existant messages in Fluent resources) - rust-lang#107355 (Add regression test for rust-lang#60755) - rust-lang#107384 (Remove `BOOL_TY_FOR_UNIT_TESTING`) - rust-lang#107385 (Use `FallibleTypeFolder` for `ConstInferUnifier` not `TypeRelation`) - rust-lang#107391 (rustdoc: remove inline javascript from copy-path button) - rust-lang#107398 (Remove `ControlFlow::{BREAK, CONTINUE}`) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
…iaskrgr Rollup of 9 pull requests Successful merges: - rust-lang#104012 (Improve unexpected close and mismatch delimiter hint in TokenTreesReader) - rust-lang#104252 (Stabilize the const_socketaddr feature) - rust-lang#105524 (Replace libc::{type} with crate::ffi::{type}) - rust-lang#107096 (Detect references to non-existant messages in Fluent resources) - rust-lang#107355 (Add regression test for rust-lang#60755) - rust-lang#107384 (Remove `BOOL_TY_FOR_UNIT_TESTING`) - rust-lang#107385 (Use `FallibleTypeFolder` for `ConstInferUnifier` not `TypeRelation`) - rust-lang#107391 (rustdoc: remove inline javascript from copy-path button) - rust-lang#107398 (Remove `ControlFlow::{BREAK, CONTINUE}`) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Should help with cases like #107091, where
{variable}
(a message reference) is accidentally typed, rather than{$variable}
(a variable reference)Fixes #107370
@rustbot label +A-translation