Netlify无法编译我的代码,它返回Build脚本,返回非零退出代码:1

时间:2019-06-12 15:44:31

标签: javascript node.js yarnpkg netlify nuxt

我正在使用nuxt构建一个网站,并且希望将其部署在Netlify上。在一开始,一切都运行良好,然后发生了这种情况:

5:35:57 PM: Build ready to start
5:36:00 PM: build-image version: 9e0f207a27642d0115b1ca97cd5e8cebbe492f63
5:36:00 PM: build-image tag: v3.3.2
5:36:00 PM: buildbot version: 75cd99f62ada9e21edea53208e8baf0eab85a045
5:36:00 PM: Fetching cached dependencies
5:36:00 PM: Starting to download cache of 109.3MB
5:36:01 PM: Finished downloading cache in 1.181829836s
5:36:01 PM: Starting to extract cache
5:36:05 PM: Finished extracting cache in 3.965861244s
5:36:05 PM: Finished fetching cache in 5.184781224s
5:36:05 PM: Starting to prepare the repo for build
5:36:07 PM: Preparing Git Reference refs/heads/master
5:36:09 PM: Starting build script
5:36:09 PM: Installing dependencies
5:36:09 PM: Started restoring cached node version
5:36:11 PM: Finished restoring cached node version
5:36:12 PM: v10.15.3 is already installed.
5:36:13 PM: Now using node v10.15.3 (npm v6.4.1)
5:36:13 PM: Attempting ruby version 2.6.2, read from environment
5:36:14 PM: Using ruby version 2.6.2
5:36:15 PM: Using PHP version 5.6
5:36:15 PM: Started restoring cached node modules
5:36:15 PM: Finished restoring cached node modules
5:36:15 PM: Started restoring cached yarn cache
5:36:15 PM: Finished restoring cached yarn cache
5:36:16 PM: Found yarn version (1.13.0) that doesn't match expected (1.16.0)
5:36:16 PM: up to date in 0.034s
5:36:16 PM: Installing yarn at version 1.16.0
5:36:16 PM: Installing Yarn!
5:36:16 PM: > Downloading tarball...
5:36:16 PM: [1/2]: https://yarnpkg.com/downloads/1.16.0/yarn-v1.
5:36:16 PM: 16.0.tar.gz --> /tmp/yarn.tar.gz.fJ72WR9Evz
5:36:16 PM:   % Total    % Received % Xferd  Average Speed   Time
5:36:16 PM:     Time     Time  Current
5:36:16 PM:                                  Dload  Upload
5:36:16 PM:  Total   Spent    Left  Speed
5:36:16 PM: 
  0     0    0
5:36:16 PM:     0    0     0      0      0 --:--:-- --:--:-- -
5:36:16 PM: -:--:--     0
5:36:17 PM: 
100    93  100    93    0     0    367
5:36:17 PM:    0 --:--:-- --:--:-- --:--:--   369
5:36:17 PM: 
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --
5:36:17 PM: :--:--     0
5:36:17 PM: 
100   609    0   609    0     0    887      0 --
5:36:17 PM: :--:-- --:--:-- --:--:--  2206
5:36:18 PM: 
100 1145k  100 1145k    0     0   991k      0  0:00:01  0:00:
5:36:18 PM: 01 --:--:--  991k
5:36:18 PM: [2/2]: https:
5:36:18 PM: //yarnpkg.com/downloads/1.16.0/yarn-v1.16.0.tar.gz.asc --> /tmp/yarn.tar.gz.fJ72WR9Evz.asc
5:36:18 PM: 
100    97  100    97    0     0   1605
5:36:18 PM:       0 --:--:-- --:--:-- --:--:--  1605
5:36:18 PM: 
100   613    0   613    0     0   2722      0 --:--:-- --:--:-- --:--:--  2722
5:36:18 PM: 
  0   832    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--
5:36:18 PM:    0
5:36:18 PM: 
100   832  100   832    0
5:36:18 PM: 0   3149      0 --:--:-- --:--:-- --:--:--  812k
5:36:18 PM: > Verifying integrity...
5:36:18 PM: gpg: Signature made Mon 29 Apr 2019 06:16:55 PM UTC using RSA key ID 69475BAA
5:36:18 PM: gpg: Good signature from "Yarn Packaging <yarn@dan.cx>"
5:36:18 PM: gpg: WARNING: This key is not certified with a trusted signature!
5:36:18 PM: gpg:          There is no indication that the signature belongs to the owner.
5:36:18 PM: Primary key fingerprint: 72EC F46A 56B4 AD39 C907  BBB7 1646 B01B 86E5 0310
5:36:18 PM:      Subkey fingerprint: 6D98 490C 6F1A CDDD 448E  4595 4F77 6793 6947 5BAA
5:36:18 PM: > GPG signature looks good
5:36:18 PM: > Extracting to ~/.yarn...
5:36:18 PM: > Adding to $PATH...
5:36:18 PM: > We've added the following to your /opt/buildhome/.profile
5:36:18 PM: > If this isn't the profile of your current shell then please add the following to your correct profile:
5:36:18 PM: export PATH="$HOME/.yarn/bin:$HOME/.config/yarn/global/node_modules/.bin:$PATH"
5:36:18 PM: 
5:36:18 PM: > Successfully installed Yarn 1.16.0! Please open another terminal where the `yarn` command will now be available.
5:36:19 PM: Installing NPM modules using Yarn version 1.16.0
5:36:20 PM: yarn install v1.16.0
5:36:20 PM: [1/4] Resolving packages...
5:36:20 PM: [2/4] Fetching packages...
5:36:33 PM: info fsevents@2.0.7: The platform "linux" is incompatible with this module.
5:36:33 PM: info "fsevents@2.0.7" is an optional dependency and failed compatibility check. Excluding it from installation.
5:36:33 PM: info fsevents@1.2.9: The platform "linux" is incompatible with this module.
5:36:33 PM: info "fsevents@1.2.9" is an optional dependency and failed compatibility check. Excluding it from installation.
5:36:33 PM: [3/4] Linking dependencies...
5:36:33 PM: warning " > sass-loader@7.1.0" has unmet peer dependency "webpack@^3.0.0 || ^4.0.0".
5:36:38 PM: [4/4] Building fresh packages...
5:36:40 PM: Done in 20.12s.
5:36:40 PM: NPM modules installed using Yarn
5:36:40 PM: Started restoring cached go cache
5:36:40 PM: Finished restoring cached go cache
5:36:40 PM: unset GOOS;
5:36:40 PM: unset GOARCH;
5:36:40 PM: export GOROOT='/opt/buildhome/.gimme/versions/go1.12.linux.amd64';
5:36:40 PM: export PATH="/opt/buildhome/.gimme/versions/go1.12.linux.amd64/bin:${PATH}";
5:36:40 PM: go version >&2;
5:36:40 PM: export GIMME_ENV='/opt/buildhome/.gimme/env/go1.12.linux.amd64.env';
5:36:40 PM: go version go1.12 linux/amd64
5:36:40 PM: Installing missing commands
5:36:40 PM: Verify run directory
5:36:40 PM: Executing user command: yarn run generate
5:36:40 PM: yarn run v1.16.0
5:36:40 PM: $ nuxt generate
5:36:42 PM: ℹ Production build
5:36:42 PM: ✔ Builder initialized
5:36:42 PM: ✔ Nuxt files generated
5:36:44 PM: ℹ Compiling Client
5:36:54 PM: ✔ Client: Compiled with some errors in 9.90s
5:36:54 PM: failed during stage 'building site': Build script returned non-zero exit code: 1
5:36:54 PM: Hash: c8fb3bcb9033fa4485fc
5:36:54 PM: Version: webpack 4.33.0
5:36:54 PM: Time: 9906ms
5:36:54 PM: Built at: 06/12/2019 3:36:54 PM
5:36:54 PM:                   Asset       Size  Chunks  Chunk Names
5:36:54 PM: 0443daab18a711484cb4.js   4.07 KiB       3  pages/home

当我运行yarn run generate时,代码被编译而没有任何错误,因此我想问题不在我的代码中,但我不确定。我读过类似的其他主题,但似乎无济于事。我已经检查了我的git commits中的修改,但是我找不到我所说的代码中有什么问题...

您知道如何解决此问题吗?

0 个答案:

没有答案