Skip to content
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

Provide MSB5009 error with project's name and it's GUID #5835

Commits on Oct 23, 2020

  1. Add Project's name and it's GUID to MSB5009 error

    The MSB5009 - SolutionParseNestedProjectError has been printed for a
    certain project but without specifying the project's name or even GUID
    which was making this issue difficult to debug.
    To make it more developer/user friendly, the MSB5009 error has been
    provided with the invalid project's name and GUID embedded in the error
    message.
    Message is extended by string arguments separate for ProjectName and
    ProjectGUID, so from now on it's required to add them as a
    BuildEventFileInfo constructor arguments.
    
    NOTE: Though error message is automaticaly generated for each language,
    some are still not translated.
    BartoszKlonowski committed Oct 23, 2020
    Configuration menu
    Copy the full SHA
    8f8ab62 View commit details
    Browse the repository at this point in the history
  2. Separate original MSB5009 error message from the extended one

    The extended MSB5009 error message requires ProjectName and ProjectGuid
    as arguments otherwise raw "{0}" will be displayed to the console in
    case of error.
    The MSB5009 error messsage is used in other places than the one covered
    in the extension implementation, so each place using this error has to
    be covered with the changes.
    
    NOTE: The only exception is the SolutionFile.ParseNestedProjects() method
    which uses the MSB5009 error too, but at the point of calling this error,
    there are no project's name nor GUID available to display, so it should
    continue to use the original error message string.
    To make it possible:
     - the original error string has been kept,
     - while the extended one has been renamed to
       "SolutionParseNestedProjectErrorWithNameAndGuid"
       to indicate it's extended content and required arguments
    
    Leaving the MSB5009 error message in the original form for
    SolutionFile.ParseNestedProject() method doesn't mean that no
    information will be given to developer/user.
    Note that it already calls the BuildEventFileInfo constructor with full
    path and current line's number, which will ease the debugging in case of
    having MSB5009 error.
    BartoszKlonowski committed Oct 23, 2020
    Configuration menu
    Copy the full SHA
    47d7b68 View commit details
    Browse the repository at this point in the history

Commits on Oct 26, 2020

  1. Cover additional MSB5009 error variant with unit test

    New unit test covering the enhanced MSB5009 error checks whether:
     - MSB5009 error is thrown for incorrectly nested project in solution
     - error contains the name of incorrectly nested project
     - error contains the GUID of incorrectly nested project
    
    NOTE: The solution file used for this unit test is the original solution
    file given as an example of the original error which these changes fix.
    Please see: dotnet#4835
    BartoszKlonowski committed Oct 26, 2020
    Configuration menu
    Copy the full SHA
    d4b06f4 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ec745ef View commit details
    Browse the repository at this point in the history

Commits on Nov 6, 2020

  1. Update src/Shared/Resources/Strings.shared.resx

    Co-authored-by: Rainer Sigwald <[email protected]>
    Forgind and rainersigwald authored Nov 6, 2020
    Configuration menu
    Copy the full SHA
    3190d77 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    e46164e View commit details
    Browse the repository at this point in the history

Commits on Nov 13, 2020

  1. Configuration menu
    Copy the full SHA
    2fd13bc View commit details
    Browse the repository at this point in the history
  2. Updated XLFs

    rainersigwald committed Nov 13, 2020
    Configuration menu
    Copy the full SHA
    81b0bcb View commit details
    Browse the repository at this point in the history