Hello fellow professionals.
I know our profession often resembles magic more than an exact science, and so today I come seeking collective wisdom to solve a problem that has been worrying me.
In a rather mysterious way, once a day — especially after restarting the computer or after the first run of the vtex link command — I run into the error “Error: pages-graphql … Request failed with status code 409”. What’s curious, though, is that this error simply disappears with a quick press of F5.
Has anyone else experienced this?
I’m leaving the full error log below to help with the investigation (I removed my vendor name and workspace name for instructional purposes):
"graphQLErrors": [
{
"message": "Request failed with status code 409",
"path": [
"pageBlocks"
],
"extensions": {
"code": "INTERNAL_SERVER_ERROR",
"exception": {
"message": "Request failed with status code 409",
"name": "Error",
"response": {
"data": {
"code": "GenericError",
"message": "Bucket has conflicts with other workspaces",
"source": "GET http://platform.io.vtex.com/[vendorname]/[workspacename]/buckets/vbase/vtex.pages-graphql.userData/metadata/store/blocks.json",
"requestId": "eade520163034187b0172762cb4296cb"
},
"headers": {
"content-type": "application/json",
"date": "Tue, 15 Aug 2023 12:22:47 GMT",
"server": "VTEX IO",
"cache-control": "no-cache, no-store",
"pragma": "no-cache, no-store",
"transfer-encoding": "chunked",
"vary": "X-Vtex-Detect-Conflicts, Accept-Encoding",
"x-router-cache": "MISS",
"x-request-id": "eade520163034187b0172762cb4296cb",
"x-vtex-router-version": "9.12.17",
"x-vtex-backend-status-code": "Conflict",
"x-vtex-backend-elapsed-time": "00:00:00.0164868",
"x-vtex-backend": "vbase@2.27.10",
"x-vtex-router-elapsed-time": "00:00:00.0208216",
"x-vtex-io-cluster-id": "prod-dj-iodev-eks-use1a-mm2"
},
"status": 409
},
"isAxiosError": true,
"code": "E_HTTP_409"
}
},
"name": "GraphQLError",
"forwardedHost": "[workspacename]--[vendorname].myvtex.com",
"operationId": "abff591c-ee81-4850-b71d-cf1e9ff9384b",
"query": {
"query": "query pageBlocks($input: PageBlocksInput) {\n pageBlocks(input: $input) {\n appsEtag\n appsSettingsJSON\n blocksJSON\n blocksTreeJSON\n componentsJSON\n contentMapJSON\n extensionsJSON\n appsMessages {\n key\n message {\n from\n context\n content\n }\n }\n userMessages {\n key\n message {\n from\n context\n content\n }\n }\n page {\n blockId\n canonical\n canonicalPath\n disableExternals\n domain\n metaTags {\n description\n keywords\n }\n routeContextLocator\n routeId\n routePath\n paramsMapJSON\n paramsJSON\n pageContext {\n id\n type\n }\n title\n varyContentById\n }\n pagesJSON\n cacheHintsJSON\n runtimeJSON\n }\n}",
"variables": "{\"input\":{\"depTree\":\"[{\\\"id\\\":\\\"vtex.render-runtime@8.134.0\\\",\\\"location\\\":\\\"/[vendorname]/[workspacename]/apps/vtex.render-runtime@8.134.0\\\",\\\"registry\\\":\\\"vtex\\\",\\\"vendor\\\":\\\"vtex\\\",\\\"name\\\":\\\"render-runtime\\\",\\\"version\\\":\\\"8.134.0\\\",\\\"settingsSchema\\\":{},\\\"credentialType\\\":\\\"absolute\\\",\\\"_buildFeatures\\\":{\\\"vtex.docs-graphql\\\":[\\\"build.json\\\",\\\"build.json\\\"],\\\"vtex.render-server\\\":[\\\"build.json\\\"]},\\\"_activationDate\\\":\\\"Mon Jan 1 00:00:00 UTC 0001\\\",\\\"_resolvedDependencies\\\":{\\\"vtex.docs-graphql\\\":\\\"0.5.0\\\",\\\"vtex.pages-graphql\\\":\\\"2.116.4\\\",\\\"vtex.render-server\\\":\\\"8.168.1\\\"},\\\"_isRoot\\\":false},{\\\"id\\\":\\\"vtex.device-detector@0.2.6\\\",\\\"location\\\":\\\"/[vendorname]/[workspacename]/apps/vtex.device-detector@0.2.6\\\",\\\"registry\\\":\\\"vtex\\\",\\\"vendor\\\":\\\"vtex\\\",\\\"name\\\":\\\"device-detector\\\",\\\"version\\\":\\\"0.2.6\\\",\\\"credentialType\\\":\\\"absolute\\\",\\\"_buildFeatures\\\":{\\\"vtex.docs-graphql\\\":[\\\"build.json\\\",\\\"build.json\\\"],\\\"vtex.render-server\\\":[\\\"build.json\\\"]},\\\"_activationDate\\\":\\\"Mon Jan 1 00:00:00 UTC 0 [Truncated: variables too long]"
},
"requestId": "1edf2e081e7545188d119a65226bfe0e",
"pathName": "pageBlocks"
}
],
"name": "Error",
"message": "pages-graphql",
"stack": "Error: pages-graphql\n at throwOnGraphQLErrors (/usr/local/app/node_modules/@vtex/api/lib/HttpClient/GraphQLClient.js:10:15)\n at /usr/local/app/node_modules/@vtex/api/lib/HttpClient/GraphQLClient.js:23:15\n at runMicrotasks (<anonymous>)\n at processTicksAndRejections (node:internal/process/task_queues:96:5)\n at Pages.getPage (/usr/src/node/clients/pages.ts:289:28)"
}