-
Notifications
You must be signed in to change notification settings - Fork 526
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
[Xamarin.Android.Build.Tasks] Improve XA1011 error wording #4779
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Context: https://developercommunity.visualstudio.com/content/problem/1043110/xamarin-%E9%A1%B9%E7%9B%AE%E5%9C%A8vs165%E7%89%88%E6%9C%AC%E7%BC%96%E8%AF%91%E6%AD%A3%E5%B8%B8%E5%8D%87%E7%BA%A7%E5%88%B0vs166%E6%97%A0%E6%B3%95%E7%BC%96%E8%AF%91%E8%BF%90%E8%A1%8C.html Seeing the localized version of the message for XA1011 in context from a real user's build made @brendanzagaeski realize that the original wording he wrote for that message was problematic. One issue was that messages for Xamarin.Android build errors are not currently accompanied by their numbered error codes when they appear in the Error List in Visual Studio. This means that users who see a localized translation for a message will likely search online using the localized text instead of the numbered code and will have a more challenging time finding corresponding release notes and documentation pages. Another problem was that the error message used "`$(AndroidLinkTool)`" as a kind of abbreviation for "`AndroidLinkTool` MSBuild property". The idea was that `$(AndroidLinkTool)` matched the MSBuild syntax for retrieving a property value and would therefore indicate that `AndroidLinkTool` was an MSBuild property, but Xamarin.Android users don't typically need to interact too much with MSBuild syntax, so they wouldn't necessarily recognize the meaning of the abbreviation. On top of that, in user projects, `AndroidLinkTool` would be more likely to appear in an XML tag like `<AndroidLinkTool>` than in a property retrieval like `$(AndroidLinkTool)`, so the use of `$(AndroidLinkTool)` in the error message could potentially cause some confusion. To help address these problems, adjust the wording of the XA1011 error. In addition to replacing "`$(AndroidLinkTool)`" with "`AndroidLinkTool` MSBuild property", make the message more actionable by adding information about how to change the corresponding code shrinker setting in the Visual Studio project property pages. [A number of the messages from the dotnet/sdk repo][0] use similar wording to refer to MSBuild properties. One difference is that those messages say "property" instead of "MSBuild property." @brendanzagaeski prefers "MSBuild property" because he believes it will help prevent ambiguity, especially in the localized translations. TODO: Audit all of the other errors and warnings that currently use the `$()` syntax, and make similar changes as appropriate. [0]: https://github.com/dotnet/sdk/blob/1ce8d7029b267c335bf606c591a97bfb9824ece1/src/Tasks/Common/Resources/Strings.resx
brendanzagaeski
requested review from
dellis1972,
jonathanpeppers and
jonpryor
as code owners
June 6, 2020 02:29
There might be another wave of users who will see this XA1011 message in d16-7 if they change their DEX compiler after seeing the new warning about DX from 2662fd1. So if this wording change looks good, it could be a good candidate to cherry-pick to d16-7. |
jonathanpeppers
approved these changes
Jun 8, 2020
jonpryor
pushed a commit
that referenced
this pull request
Jun 9, 2020
Context: https://developercommunity.visualstudio.com/content/problem/1043110/xamarin-androidlinktool-dx.html Seeing the localized version of the message for XA1011 in context from a real user's build made @brendanzagaeski realize that the original wording he wrote for that message was problematic. One issue was that messages for Xamarin.Android build errors are not currently accompanied by their numbered error codes when they appear in the Error List in Visual Studio. This means that users who see a localized translation for a message will likely search online using the localized text instead of the numbered code and will have a more challenging time finding corresponding release notes and documentation pages. Another problem was that the error message used "`$(AndroidLinkTool)`" as a kind of abbreviation for "the `AndroidLinkTool` MSBuild property". The idea was that `$(AndroidLinkTool)` matched the MSBuild syntax for retrieving a property value and would therefore indicate that `AndroidLinkTool` was an MSBuild property, but Xamarin.Android users don't typically need to interact too much with MSBuild syntax, so they wouldn't necessarily recognize the meaning of the abbreviation. On top of that, in user projects, `AndroidLinkTool` would be more likely to appear in an XML tag like `<AndroidLinkTool>` than in a property retrieval like `$(AndroidLinkTool)`, so the use of `$(AndroidLinkTool)` in the error message could potentially cause some confusion. To help address these problems, adjust the wording of the XA1011 error. In addition to replacing "`$(AndroidLinkTool)`" with "`AndroidLinkTool` MSBuild property", make the message more actionable by adding information about how to change the corresponding code shrinker setting in the Visual Studio project property pages. [A number of the messages from the dotnet/sdk repo][0] use similar wording to refer to MSBuild properties. One difference is that those messages say "property" instead of "MSBuild property." @brendanzagaeski prefers "MSBuild property" because he believes it will help prevent ambiguity, especially in the localized translations. TODO: Audit all of the other errors and warnings that currently use the `$()` syntax, and make similar changes as appropriate. [0]: https://github.com/dotnet/sdk/blob/1ce8d7029b267c335bf606c591a97bfb9824ece1/src/Tasks/Common/Resources/Strings.resx
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Context: https://developercommunity.visualstudio.com/content/problem/1043110/xamarin-%E9%A1%B9%E7%9B%AE%E5%9C%A8vs165%E7%89%88%E6%9C%AC%E7%BC%96%E8%AF%91%E6%AD%A3%E5%B8%B8%E5%8D%87%E7%BA%A7%E5%88%B0vs166%E6%97%A0%E6%B3%95%E7%BC%96%E8%AF%91%E8%BF%90%E8%A1%8C.html
Seeing the localized version of the message for XA1011 in context from a
real user's build made @brendanzagaeski realize that the original
wording he wrote for that message was problematic.
One issue was that messages for Xamarin.Android build errors are not
currently accompanied by their numbered error codes when they appear in
the Error List in Visual Studio. This means that users who see a
localized translation for a message will likely search online using the
localized text instead of the numbered code and will have a more
challenging time finding corresponding release notes and documentation
pages.
Another problem was that the error message used "
$(AndroidLinkTool)
"as a kind of abbreviation for "
AndroidLinkTool
MSBuild property". Theidea was that
$(AndroidLinkTool)
matched the MSBuild syntax forretrieving a property value and would therefore indicate that
AndroidLinkTool
was an MSBuild property, but Xamarin.Android usersdon't typically need to interact too much with MSBuild syntax, so they
wouldn't necessarily recognize the meaning of the abbreviation. On top
of that, in user projects,
AndroidLinkTool
would be more likely toappear in an XML tag like
<AndroidLinkTool>
than in a propertyretrieval like
$(AndroidLinkTool)
, so the use of$(AndroidLinkTool)
in the error message could potentially cause some confusion.
To help address these problems, adjust the wording of the XA1011 error.
In addition to replacing "
$(AndroidLinkTool)
" with "AndroidLinkTool
MSBuild property", make the message more actionable by adding
information about how to change the corresponding code shrinker setting
in the Visual Studio project property pages.
A number of the messages from the dotnet/sdk repo use similar
wording to refer to MSBuild properties. One difference is that those
messages say "property" instead of "MSBuild property." @brendanzagaeski
prefers "MSBuild property" because he believes it will help prevent
ambiguity, especially in the localized translations.
TODO: Audit all of the other errors and warnings that currently use the
$()
syntax, and make similar changes as appropriate.