sp-dev-docs icon indicating copy to clipboard operation
sp-dev-docs copied to clipboard

"gulp bundle --ship" hangs at CopyAssets subtask

Open BenGWeeks opened this issue 9 years ago • 4 comments

Category

  • [ ] Question
  • [ ] Typo
  • [x] Bug
  • [x] Enhancement / Suggestion
  • [ ] Additional article idea

Expected or Desired Behavior

I expect that the "gulp build --ship" should build like "gulp build" does.

Observed Behavior

Console hangs at "CopyAssets" subtask and CPU maxes out (Node.js)

Steps to Reproduce

Would initially fail with the following:

SyntaxError: Unexpected token: name (Def) when "gulp bundle --ship" with sp-pnp-js https://github.com/SharePoint/PnP-JS-Core/issues/314

As per suggestion, change config/config.json to include:

"externals": { "sp-pnp-js": "https://cdnjs.cloudflare.com/ajax/libs/sp-pnp-js/2.0.0/pnp.min.js" },

My packages.json is as follows:

{ "name": "sharepoint-app", "version": "0.0.1", "private": true, "engines": { "node": ">=0.10.0" }, "dependencies": { "@angular/common": "^2.4.5", "@angular/compiler": "^2.4.5", "@angular/core": "^2.4.5", "@angular/forms": "^2.4.5", "@angular/http": "^2.4.5", "@angular/platform-browser": "^2.4.5", "@angular/platform-browser-dynamic": "^2.4.5", "@angular/router": "^3.4.5", "@microsoft/sp-client-base": "~0.7.0", "@microsoft/sp-client-preview": "~0.9.0", "@microsoft/sp-core-library": "~0.1.2", "@microsoft/sp-webpart-base": "~0.4.0", "@progress/kendo-angular-buttons": "^0.16.0", "@progress/kendo-angular-dropdowns": "^0.26.9", "@progress/kendo-angular-grid": "^0.14.0", "@progress/kendo-angular-intl": "^0.9.0", "@progress/kendo-angular-layout": "^0.20.1", "@progress/kendo-angular-upload": "^0.13.1", "@progress/kendo-data-query": "^0.3.5", "@progress/kendo-theme-default": "^2.11.8", "@types/webpack-env": ">=1.12.1 <1.14.0", "bootstrap": "^3.3.7", "core-js": "^2.4.1", "json-stringify": "^1.0.0", "reflect-metadata": "^0.1.9", "rxjs": "^5.1.0", "sp-pnp-js": "^2.0.0", "ts-helper": "0.0.1", "tslint": "^4.0.0", "zone.js": "^0.7.6" }, "devDependencies": { "@microsoft/sp-build-web": "~0.9.0", "@microsoft/sp-module-interfaces": "~0.7.0", "@microsoft/sp-webpart-workbench": "~0.8.0", "@types/chai": "^3.4.34", "@types/jasmine": "^2.5.41", "@types/mocha": "^2.2.38", "@types/node": "^7.0.4", "bootstrap-loader": "^2.0.0-beta.20", "bootstrap-sass": "^3.3.7", "codelyzer": "^2.0.0-beta.4", "css-loader": "^0.26.1", "extract-text-webpack-plugin": "^1.0.1", "gulp": "^3.9.1", "gulp-spsave": "^3.0.0", "html-loader": "^0.4.4", "jasmine-core": "^2.5.2", "jasmine-spec-reporter": "^3.2.0", "jquery": "^3.1.1", "json-stringify": "^1.0.0", "karma": "^1.4.0", "karma-chrome-launcher": "^2.0.0", "karma-jasmine": "^1.1.0", "node-sass": "^4.3.0", "resolve-url-loader": "^1.6.1", "sass-loader": "^4.1.1", "sp-pnp-js": "^2.0.0", "spsave": "^3.0.2", "style-loader": "^0.13.1", "ts-node": "^2.0.0", "tslint": "^3.15.1", "typescript": "^2.1.5", "url-loader": "^0.5.7", "webpack": "^2.2.1" }, "scripts": { "build": "gulp bundle", "clean": "gulp clean", "test": "gulp test" } }

Any help much appreciated.

EDIT: Issue resolution

Resolution was to change prepare-deploy.json from:

{ "deployCdnPath": "https://[somecompany].sharepoint.com/sites/Development/SiteAssets/[SomeFolder]/" }

Back to:

{ "deployCdnPath": "temp/deploy" }

However, some more feedback in the console / error handling is required I think in @microsoft/sp-build-web.

BenGWeeks avatar Feb 02 '17 09:02 BenGWeeks

@webtechy Just making sure that your issue with the --ship command is resolved and that the open issue now is to improve the error handling and documentation - correct?

chakkaradeep avatar Feb 07 '17 19:02 chakkaradeep

Hi @webtechy, please confirm that you issue is resolved. We are working on improving error handling and documentation.

amishra0909 avatar May 09 '17 00:05 amishra0909

Yes, although would have this as a suggestion still.

BenGWeeks avatar May 09 '17 06:05 BenGWeeks

Issues that have been closed & had no follow-up activity for at least 7 days are automatically locked. Please refer to our wiki for more details, including how to remediate this action if you feel this was done prematurely or in error: Issue List: Our approach to locked issues

msft-github-bot avatar Jan 29 '20 18:01 msft-github-bot