Project build halts on: “Build delayed until Bower/npm packages finish restoring.”

前端 未结 5 1540
忘掉有多难
忘掉有多难 2021-02-12 12:26

In VS 2017, I created a new ASP.NET Core Web Application using the Angular template.

The project however does not run, it gets stuck on:

Build delayed un         


        
相关标签:
5条回答
  • 2021-02-12 13:01

    For react project I solved it using these steps.

    1) right click on the project and select >build

    2) Then in output box showing "Build delayed until Bower/npm packages finish restoring."

    3) Wait few minutes.After building the project you can see

    Build delayed until Bower/npm packages finish restoring. 1>------ Build started: Project: chatApplication, Configuration: Debug Any CPU ------ 1>chatApplication -> D:\IdeaProjects\chatApplication\chatApplication\bin\Debug\netcoreapp2.1\chatApplication.dll 1>chatApplication -> D:\IdeaProjects\chatApplication\chatApplication\bin\Debug\netcoreapp2.1\chatApplication.Views.dll ========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========

    0 讨论(0)
  • 2021-02-12 13:02

    I had some problem in visual stduio 2019 aspnet core & angular project.

    I have solved it using this way.

    1. Manually run npm install via cmd,

    2. And if after run project via visual studio 2019, Project run successfuly. (Without “Build delayed until Bower/npm packages finish restoring.”)

    This way worked for me

    0 讨论(0)
  • 2021-02-12 13:05

    I had a similar problem and I followed the below steps to get around it.

    Disable Package restore:

    1. Go to Tools -> Options -> Project and Solutions -> Web Package Management -> Package Restore.
    2. Set False to 'Restore on Project Open' and 'Restore on Save'

    After disabling, I opened a terminal and manually installed all the packages. I used Yarn to install the packages and faced no problems.

    Visual Studio often halts during project builds because of timeouts. To get around that, I used the command yarn --network-timeout 60000.

    Hope this helps!

    0 讨论(0)
  • 2021-02-12 13:10

    I was able to workaround my indefinite “Build delayed until Bower/npm packages finish restoring.” publishing delay in VS.NET 2019 Community Edition by:

    1. Clicking on the [Cancel] button in the [Web Publish Activity] tab.
    2. Exiting and restarting VS.NET with Administrative privileges
    3. Opening the solution and publishing my app again.

    In my case, it looks like it was the lack of Administrative privileges that caused the infinite delay.

    0 讨论(0)
  • 2021-02-12 13:13

    i had a sort-a-like problem. This is what i did to solve it:

    1. check the folder node_modules
    2. on my pc it was empty
    3. open the folder in a command prompt (with administrator privileges)
    4. run "npm install", this will download all referenced node modules (see package.json) to your pc
    5. then when you build in VS Studio,the bower delay is gone
    0 讨论(0)
提交回复
热议问题