FrontasticGmbH / netlify-plugin-commercetools-frontend

1 stars 0 forks source link

Please replace with a clear and descriptive title #4

Open dungnguyenhoang-sm opened 9 months ago

dungnguyenhoang-sm commented 9 months ago

Describe the bug

Detail log when build fail

2:30:45 PM: build-image version: 3ffff9df3d5419545acc1b673a54de348174406d (focal)
2:30:45 PM: buildbot version: bbe0ea9996d161264a9e2a12f85f3385d1bf3738
2:30:46 PM: Fetching cached dependencies
2:30:46 PM: Starting to download cache of 1.0GB
2:30:59 PM: Finished downloading cache in 13.816s
2:30:59 PM: Starting to extract cache
2:31:08 PM: Finished extracting cache in 8.91s
2:31:08 PM: Finished fetching cache in 22.875s
2:31:08 PM: Starting to prepare the repo for build
2:31:09 PM: Preparing Git Reference refs/heads/master
2:31:10 PM: Custom build path detected. Proceeding with the specified path: "packages/schuhe/frontend"
2:31:10 PM: Custom publish path detected. Proceeding with the specified path: "packages/schuhe/frontend/.next"
2:31:10 PM: Custom ignore command detected. Proceeding with the specified command: "$CACHED_COMMIT_REF == $COMMIT_REF"
2:31:10 PM: manpath: warning: $PATH not set
2:31:11 PM: /usr/bin/bash: 131473932b7033dd036f2496a9ced7556160aaa9: command not found
2:31:11 PM: Starting to install dependencies
2:31:11 PM: Python version set to 3.8
2:31:11 PM: Attempting Ruby version 2.7.2, read from environment
2:31:12 PM: Using Ruby version 2.7.2
2:31:12 PM: Started restoring cached go cache
2:31:12 PM: Finished restoring cached go cache
2:31:12 PM: Installing Go version 1.17 (requested 1.17)
2:31:17 PM: go version go1.17 linux/amd64
2:31:17 PM: Using PHP version 8.0
2:31:18 PM: Started restoring cached Node.js version
2:31:19 PM: Finished restoring cached Node.js version
2:31:19 PM: v16.20.2 is already installed.
2:31:19 PM: Now using node v16.20.2 (npm v8.19.4)
2:31:19 PM: Enabling Node.js Corepack
2:31:19 PM: Started restoring cached build plugins
2:31:19 PM: Finished restoring cached build plugins
2:31:19 PM: Started restoring cached corepack dependencies
2:31:19 PM: Finished restoring cached corepack dependencies
2:31:19 PM: Started restoring cached yarn cache
2:31:25 PM: Finished restoring cached yarn cache
2:31:25 PM: Installing Yarn version 1.22.10
2:31:25 PM: Preparing yarn@1.22.10 for immediate activation...
2:31:25 PM: No yarn workspaces detected
2:31:25 PM: Started restoring cached node modules
2:31:25 PM: Finished restoring cached node modules
2:31:25 PM: Installing npm packages using Yarn version 1.22.10
2:31:26 PM: yarn install v1.22.10
2:31:26 PM: [1/4] Resolving packages...
2:31:26 PM: success Already up-to-date.
2:31:26 PM: Done in 0.61s.
2:31:26 PM: npm packages installed using Yarn
2:31:27 PM: Successfully installed dependencies
2:31:27 PM: Starting build script
2:31:28 PM: Detected 1 framework(s)
2:31:28 PM: "next" at version "12.3.4"
2:31:28 PM: Section completed: initializing
2:31:30 PM: ​
2:31:30 PM: Netlify Build                                                 
2:31:30 PM: ────────────────────────────────────────────────────────────────
2:31:30 PM: ​
2:31:30 PM: ❯ Version
2:31:30 PM:   @netlify/build 29.29.0
2:31:30 PM: ​
2:31:30 PM: ❯ Flags
2:31:30 PM:   baseRelDir: true
2:31:30 PM:   buildId: 65683a244c8700000863ebe8
2:31:30 PM:   deployId: 65683a244c8700000863ebea
2:31:30 PM: ​
2:31:30 PM: ❯ Current directory
2:31:30 PM:   /opt/build/repo/packages/schuhe/frontend
2:31:30 PM: ​
2:31:30 PM: ❯ Config file
2:31:30 PM:   /opt/build/repo/packages/schuhe/frontend/netlify.toml
2:31:30 PM: ​
2:31:30 PM: ❯ Context
2:31:30 PM:   production
2:31:30 PM: ​
2:31:30 PM: ❯ Using Next.js Runtime - v4.41.2
2:31:30 PM: ​
2:31:30 PM: ❯ Loading plugins
2:31:30 PM:    - @commercetools/frontend-netlify-plugin@0.2.0 from netlify.toml and package.json
2:31:31 PM: ​
2:31:31 PM: @netlify/plugin-nextjs (onPreBuild event)                     
2:31:31 PM: ────────────────────────────────────────────────────────────────
2:31:31 PM: ​
2:31:32 PM: Next.js cache restored.
2:31:32 PM: Netlify configuration property "build.environment.NEXT_PRIVATE_TARGET" value changed.
2:31:32 PM: ​
2:31:32 PM: (@netlify/plugin-nextjs onPreBuild completed in 527ms)
2:31:32 PM: ​
2:31:32 PM: @commercetools/frontend-netlify-plugin (onPreBuild event)     
2:31:32 PM: ────────────────────────────────────────────────────────────────
2:31:32 PM: ​
2:31:32 PM: NEXT_PUBLIC_EXT_BUILD_ID is not set or has falsy value. Setting it to short commit hash: "1a34f19"
2:31:32 PM: Checking if extension is up, attempt:  1
2:31:32 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:31:32 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:31:32 PM: Extension is not available, waiting for 1 seconds
2:31:32 PM: Checking if extension is up, attempt:  2
2:31:32 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:31:32 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:31:32 PM: Extension is not available, waiting for 2 seconds
2:31:33 PM: Checking if extension is up, attempt:  3
2:31:33 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:31:33 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:31:33 PM: Extension is not available, waiting for 3 seconds
2:31:35 PM: Checking if extension is up, attempt:  4
2:31:35 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:31:36 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:31:36 PM: Extension is not available, waiting for 4 seconds
2:31:39 PM: Checking if extension is up, attempt:  5
2:31:39 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:31:39 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:31:39 PM: Extension is not available, waiting for 5 seconds
2:31:43 PM: Checking if extension is up, attempt:  6
2:31:43 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:31:43 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:31:43 PM: Extension is not available, waiting for 6 seconds
2:31:48 PM: Checking if extension is up, attempt:  7
2:31:48 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:31:48 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:31:48 PM: Extension is not available, waiting for 7 seconds
2:31:54 PM: Checking if extension is up, attempt:  8
2:31:54 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:31:55 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:31:55 PM: Extension is not available, waiting for 8 seconds
2:32:02 PM: Checking if extension is up, attempt:  9
2:32:02 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:32:02 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:32:02 PM: Extension is not available, waiting for 9 seconds
2:32:10 PM: Checking if extension is up, attempt:  10
2:32:10 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:32:10 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:32:10 PM: Extension is not available, waiting for 10 seconds
2:32:19 PM: Checking if extension is up, attempt:  11
2:32:19 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:32:20 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:32:20 PM: Extension is not available, waiting for 11 seconds
2:32:30 PM: Checking if extension is up, attempt:  12
2:32:30 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:32:30 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:32:30 PM: Extension is not available, waiting for 12 seconds
2:32:41 PM: Checking if extension is up, attempt:  13
2:32:41 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:32:41 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:32:41 PM: Extension is not available, waiting for 13 seconds
2:32:53 PM: Checking if extension is up, attempt:  14
2:32:53 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:32:53 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:32:53 PM: Extension is not available, waiting for 14 seconds
2:33:06 PM: Checking if extension is up, attempt:  15
2:33:06 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:33:07 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:33:07 PM: Extension is not available, waiting for 15 seconds
2:33:21 PM: Checking if extension is up, attempt:  16
2:33:21 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:33:21 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:33:21 PM: Extension is not available, waiting for 16 seconds
2:33:36 PM: Checking if extension is up, attempt:  17
2:33:36 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:33:36 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:33:36 PM: Extension is not available, waiting for 17 seconds
2:33:52 PM: Checking if extension is up, attempt:  18
2:33:52 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:33:52 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:33:52 PM: Extension is not available, waiting for 18 seconds
2:34:09 PM: Checking if extension is up, attempt:  19
2:34:09 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:34:10 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:34:10 PM: Extension is not available, waiting for 19 seconds
2:34:28 PM: Checking if extension is up, attempt:  20
2:34:28 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:34:28 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:34:28 PM: Extension is not available, waiting for 20 seconds
2:34:47 PM: Checking if extension is up, attempt:  21
2:34:47 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:34:47 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:34:47 PM: Extension is not available, waiting for 21 seconds
2:35:07 PM: Checking if extension is up, attempt:  22
2:35:07 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:35:07 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:35:07 PM: Extension is not available, waiting for 22 seconds
2:35:28 PM: Checking if extension is up, attempt:  23
2:35:28 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:35:29 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:35:29 PM: Extension is not available, waiting for 23 seconds
2:35:51 PM: Checking if extension is up, attempt:  24
2:35:51 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:35:51 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:35:51 PM: Extension is not available, waiting for 24 seconds
2:36:14 PM: Checking if extension is up, attempt:  25
2:36:14 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:36:14 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:36:14 PM: Extension is not available, waiting for 25 seconds
2:36:38 PM: Checking if extension is up, attempt:  26
2:36:38 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:36:38 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:36:38 PM: Extension is not available, waiting for 26 seconds
2:37:03 PM: Checking if extension is up, attempt:  27
2:37:03 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:37:04 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:37:04 PM: Extension is not available, waiting for 27 seconds
2:37:30 PM: Checking if extension is up, attempt:  28
2:37:30 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:37:30 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:37:30 PM: Extension is not available, waiting for 28 seconds
2:37:57 PM: Checking if extension is up, attempt:  29
2:37:57 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:37:57 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:37:57 PM: Extension is not available, waiting for 29 seconds
2:38:25 PM: Checking if extension is up, attempt:  30
2:38:25 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:38:25 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:38:25 PM: Extension is not available, waiting for 30 seconds
2:38:54 PM: Checking if extension is up, attempt:  31
2:38:54 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:38:55 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:38:55 PM: Extension is not available, waiting for 31 seconds
2:39:25 PM: Checking if extension is up, attempt:  32
2:39:25 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:39:25 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:39:25 PM: Extension is not available, waiting for 32 seconds
2:39:56 PM: Checking if extension is up, attempt:  33
2:39:56 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:39:56 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:39:56 PM: Extension is not available, waiting for 33 seconds
2:40:28 PM: Checking if extension is up, attempt:  34
2:40:28 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:40:28 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:40:28 PM: Extension is not available, waiting for 34 seconds
2:41:02 PM: Checking if extension is up, attempt:  35
2:41:02 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:41:02 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:41:02 PM: Extension is not available, waiting for 35 seconds
2:41:36 PM: Checking if extension is up, attempt:  36
2:41:36 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:41:36 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:41:36 PM: Extension is not available, waiting for 36 seconds
2:42:11 PM: Checking if extension is up, attempt:  37
2:42:11 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:42:11 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:42:11 PM: Extension is not available, waiting for 37 seconds
2:42:47 PM: Checking if extension is up, attempt:  38
2:42:47 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:42:48 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:42:48 PM: Extension is not available, waiting for 38 seconds
2:43:25 PM: Checking if extension is up, attempt:  39
2:43:25 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:43:25 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:43:25 PM: Extension is not available, waiting for 39 seconds
2:44:03 PM: Checking if extension is up, attempt:  40
2:44:03 PM: Calling https://schuhe-anwrnext.frontastic.io/frontastic/status/extensionrunner Version 1a34f19
2:44:03 PM: Version mismatch, got answer from 1314739 instead of 1a34f19
2:44:03 PM: Extension is not available, waiting for 40 seconds
2:44:42 PM: ​
2:44:42 PM: Plugin "@commercetools/frontend-netlify-plugin" failed        
2:44:42 PM: ────────────────────────────────────────────────────────────────
2:44:42 PM: ​
2:44:42 PM:   Error message
2:44:42 PM:   Error: Error message
2:44:42 PM:   Extension is not up
2:44:42 PM: ​
2:44:42 PM:   Plugin details
2:44:42 PM:   Package:        @commercetools/frontend-netlify-plugin
2:44:42 PM:   Version:        0.2.0
2:44:42 PM:   Repository:     git+https://github.com/FrontasticGmbH/netlfy-plugin-commercetools-frontend.git
2:44:42 PM:   npm link:       https://www.npmjs.com/package/@commercetools/frontend-netlify-plugin
2:44:42 PM:   Report issues:  https://github.com/FrontasticGmbH/netlfy-plugin-commercetools-frontend/issues
2:44:42 PM: ​
2:44:42 PM:   Error location
2:44:42 PM:   In "onPreBuild" event in "@commercetools/frontend-netlify-plugin" from netlify.toml and package.json
2:44:42 PM: ​
2:44:42 PM:   Resolved config
2:44:42 PM:   build:
2:44:42 PM:     base: /opt/build/repo/packages/schuhe/frontend
2:44:42 PM:     command: next build && next-sitemap
2:44:42 PM:     commandOrigin: ui
2:44:42 PM:     environment:
2:44:42 PM:       - NETLIFY_USE_YARN
2:44:42 PM:       - NEXT_PUBLIC_CAT_ANCESTOR_ID
2:44:42 PM:       - NEXT_PUBLIC_CLOUDINARY_CLOUD_NAME
2:44:42 PM:       - NEXT_PUBLIC_ERROR_PATH
2:44:42 PM:       - NEXT_PUBLIC_FRONTASTIC_HOST
2:44:42 PM:       - NEXT_PUBLIC_SITE_URL
2:44:42 PM:       - NEXT_PRIVATE_TARGET
2:44:42 PM:     ignore: $CACHED_COMMIT_REF == $COMMIT_REF
2:44:42 PM:     publish: /opt/build/repo/packages/schuhe/frontend/.next
2:44:42 PM:     publishOrigin: ui
2:44:42 PM:   functions:
2:44:42 PM:     "*":
2:44:42 PM:       included_files:
2:44:42 PM:         - public/locales/**/*.json
2:44:42 PM:         - next-i18next.config.js
2:44:42 PM:   plugins:
2:44:42 PM:     - inputs: {}
2:44:42 PM:       origin: ui
2:44:42 PM:       package: "@netlify/plugin-nextjs"
2:44:42 PM:     - inputs: {}
2:44:42 PM:       origin: config
2:44:42 PM:       package: "@commercetools/frontend-netlify-plugin"
2:44:43 PM: Failed during stage "building site": Build script returned non-zero exit code: 2
2:44:43 PM: Build failed due to a user error: Build script returned non-zero exit code: 2
2:44:43 PM: Failing build: Failed to build site
2:44:43 PM: Finished processing build request in 13m57.595s

Expected behavior

Please help us fix it to run smoothly and stable, because sometimes it has this problem again

Screenshots Screenshot 2023-11-30 at 15 02 28

jluterek commented 5 months ago

I'm getting the same error. Was there a resolution or fix?

dumitrualex commented 1 month ago

Hello 👋!

I've been having the same issue on and off for a while, and sometimes a fake commit would help nudge the Studio pipeline to build the correct version but sometimes we would have PRs with failed pipelines for several days where not even creating a new branch (with new commits) would help.

Eventually, after a couple of tickets opened with CT Support, they figured out that our setup was wrong. Our project runs in a multi-tenant environment, and there is no need for us to use the @commercetools/frontend-netlify-plugin package.

So, after a minimal change of removing the package and updating our next.config.js file, everything was back to normal and builds are running fine ever since (which at the time of me posting this message is a little over 2 weeks).

I've posted the same issue on the CT community page and documented our changes there. Feel free to check it out at: https://community.commercetools.com/ask-a-question-44/frontend-extension-runner-not-available-162