Hundred of errors after update to Visual Studio version 17.12.3!

Hossein Dabbaghan 26 Reputation points
2025-01-03T10:39:16.9366667+00:00

I updated Visual Studio to version 17.12.3 and now, there is hundred of errors in Building project! My .net Core project was work correctly before updating. I checked errors but they are nonsense! All codes are correct.

ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,788 questions
Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
5,447 questions
{count} vote

5 answers

Sort by: Most helpful
  1. Anna Xiu-MSFT 30,921 Reputation points Microsoft Vendor
    2025-01-06T03:17:23.11+00:00

    Hi @Hossein Dabbaghan

    Welcome to Microsoft Q&A! 

    You can close all running VS instances and try to delete the hidden .vs, bin and obj folders in the project folder.

    Then, clean and rebuild your solution. 

    Sincerely,

    Anna


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".  Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

     


  2. Craig Burley 0 Reputation points
    2025-01-09T20:04:50.2633333+00:00

    Reverting the upgrade (back to 17.11.5 in my case) has proven to be a solid workaround.


  3. Deleted

    This answer has been deleted due to a violation of our Code of Conduct. The answer was manually reported or identified through automated detection before action was taken. Please refer to our Code of Conduct for more information.


    Comments have been turned off. Learn more

  4. Hossein Dabbaghan 26 Reputation points
    2025-01-23T08:42:40.6+00:00

    Fred Silberberg [MSFT] solved these errors in:

    https://developercommunity.visualstudio.com/t/Hundred-of-errors-appear-after-updating-/10827657

    Thank you Fred Silberberg [MSFT]. It solved the problem. I added ; to the end of every line that has #region and #endregion. I figured out if comment of #region or #endregion have characters like = or && or || or any characters are used in code, should have ; in the end of the line.

    Sample:

    #region Updating "SentToPaymentGatewayDate = null";
    ... Code
    #endregion Updating "objOrderC_ToPay!. SentToPaymentGatewayDate = null";
    

    or:

    #region MinAllowedNumberOfOrder && MaxAllowedNumberOfOrder;
    ... Code
    #endregion MinAllowedNumberOfOrder && MaxAllowedNumberOfOrder;
    

  5. Craig Burley 0 Reputation points
    2025-02-22T01:16:40.6566667+00:00

    Hey all, I've managed to get past this issue even with the latest release of VS.

    Seems it was a combination of the upgraded version(s) needing to upgrade local packages from our company's own NuGet repository and my PAT (for that repo) having expired.

    Generating a new PAT (in GitHub), with the usual read:packages permissions; authorizing it for the pertinent organization(s); using that PAT for the "ClearTextPassword" in my Nuget.Config along with the key I used to configure our org's NuGet repo; then restarting VS seemingly several times, resulted in the compile errors ultimately disappearing.

    One glitch was difficult to track down: error messages NU1301 "Failed to verify the root directory of local source" accompanied by "The given path's format is not supported" was evidently due to a leading space somehow getting into that path, before the "https://".

    Fixing/updating my NuGet.Config via a text editor (I use GNU Emacs but YMMV) so it had the appropriate structure and information, including a space-trimmed URL for our NuGet repo and my GH UserName + PAT to authenticate against that repo, seems to have eliminated all the problems, and I can now run it, and it works.

    It would be great if VS/NuGet/whatever would explicitly warn "login failed" or something when it can't actually reach a repo...but it'd also help if I had had a better understanding of the implications of those early diagnostics in what reached an upper bound of about 39,000 build errors with the latest VS.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.