简体   繁体   中英

Visual Studio 2019, Publish to Azure is failed for NodeJs Web App

Node Js publish from Visual Studio 2019 stopped working. there was no update on VS or code configurations.

在此处输入图像描述

Error dump from temp file :

27-Nov-20 09:58:33
System.NullReferenceException: Object reference not set to an instance of an object.
   at Microsoft.Publish.Framework.ViewModel.ProfileSelectorViewModel.CanShowRestoreAction()
   at Microsoft.Publish.Framework.ViewModel.ProfileSelectorViewModel.RebuildCrudProfileCommands(IProfileVisual profile)
   at Microsoft.Publish.Framework.ViewModel.ProfileSelectorViewModel.set_SelectedProfile(IProfileVisual value)
   at Microsoft.Publish.Framework.ViewModel.ProfileSelectorViewModel.Initialize(ProfileSelectorUserControl view)
   at Microsoft.Publish.Framework.Provider.DefaultPublishTabProvider.<CreateViewAsync>d__13.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.Publish.Framework.Provider.PublishProjectDesignerTabProvider.<CreateViewAsync>d__7.MoveNext()
===================

What I tried:

  1. Clearing.vs, data, bin
  2. Clearing temp But nothing worked.

Anyway to resolve this?

Workaround: Using Deployment center local git

Usually, emptying the C:\Users\%USERPROFILE%\AppData\Local\Microsoft\VisualStudio and C:\Users\%USERPROFILE%\AppData\Local\Microsoft\VSCommon folders should fix your publish error. If not, try repairing your VS installation or re-installing the latest version available.

This SO post highlights a few other workarounds to try. If the problem still persists, please report it onDeveloper Community so the VS Team can investigate further.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM