I am creating a website with Nuxt, graphql and strapi.
Locally with works well. I then deploy the backend in heuroku with mlab addon and also all good.
Went to netlify with the heuroku link and deploy it there( follow a tutorial). It said deployed successful but when I open the page it says page not found. I went to see the deploy log and there is an error:
Error: Network error: request to http://localhost:1337/graphql failed, reason: connect ECONNREFUSED 127.0.0.1:1337
10:16:00 AM: at new ApolloError (/opt/build/repo/node_modules/apollo-client/bundle.umd.js:92:26)
10:16:00 AM: at /opt/build/repo/node_modules/apollo-client/bundle.umd.js:1588:34
10:16:00 AM: at /opt/build/repo/node_modules/apollo-client/bundle.umd.js:2008:15
10:16:00 AM: at Set.forEach (<anonymous>)
10:16:00 AM: at /opt/build/repo/node_modules/apollo-client/bundle.umd.js:2006:26
10:16:00 AM: at Map.forEach (<anonymous>)
10:16:00 AM: at QueryManager.broadcastQueries (/opt/build/repo/node_modules/apollo-client/bundle.umd.js:2004:20)
10:16:00 AM: at /opt/build/repo/node_modules/apollo-client/bundle.umd.js:1483:29
10:16:00 AM: at processTicksAndRejections (internal/process/task_queues.js:97:5)
Any idea how to fix this? I search but couldn't find any answer that helped me.
Thank you
It should be referencing the Heroku url. You need to change your database.js for Heroku. https://strapi.io/documentation/3.0.0-beta.x/deployment/heroku.html
Related
This is what I get in the stack trace from launching chrome: Cypress version is 7.3.:
Title: Error launching browser
Message: Cypress failed to make a connection to the Chrome DevTools Protocol after retrying for 50 seconds.
This usually indicates there was a problem opening the Chrome browser.
The CDP port requested was 29079.
Error details:
Error: connect ECONNREFUSED 127.0.0.1:29079
at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1146:16)
Stack trace:
Error: Cypress failed to make a connection to the Chrome DevTools Protocol after retrying for 50 seconds.
This usually indicates there was a problem opening the Chrome browser.
The CDP port requested was [33m29079[39m.
Error details:
Error: connect ECONNREFUSED 127.0.0.1:29079
at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1146:16)
at get (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\lib\errors.js:988:15)
at Object.throwErr [as throw] (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\lib\errors.js:1006:9)
at C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\lib\browsers\protocol.js:106:21
at tryCatcher (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\node_modules\bluebird\js\release\util.js:16:23)
at Promise._settlePromiseFromHandler (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\node_modules\bluebird\js\release\promise.js:547:31)
at Promise._settlePromise (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\node_modules\bluebird\js\release\promise.js:604:18)
at Promise._settlePromise0 (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\node_modules\bluebird\js\release\promise.js:649:10)
at Promise._settlePromises (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\node_modules\bluebird\js\release\promise.js:725:18)
at _drainQueueStep (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\node_modules\bluebird\js\release\async.js:93:12)
at _drainQueue (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\node_modules\bluebird\js\release\async.js:86:9)
at Async._drainQueues (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\node_modules\bluebird\js\release\async.js:102:5)
at Immediate.Async.drainQueues [as _onImmediate] (C:\Users\giannia\AppData\Local\Cypress\Cache\7.3.0\Cypress\resources\app\packages\server\node_modules\bluebird\js\release\async.js:15:14)
at processImmediate (internal/timers.js:461:21)
I have spoken to the support team and they currently do not have any protocols in place that would block cypress from launching chrome. I have also looked at an earlier solution in stack overflow where you go into ext/files to comment out the localhost address but still to ano avail. Can anyone please help??
I'm having the following problem when I enter the page, I don't know what part of Elastic Search is causing it
NestedError: Error while validating Authorization header at
boService.getSignKey.then.then.catch (/var/youmarket/fo-search/src/middleWares/validation.js:32:28)
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:182:7)
Caused By: JsonWebTokenError: jwt malformed
at Object.module.exports [as verify] (/var/youmarket/fo-search/node_modules/jsonwebtoken/verify.js:49:17)
at Promise (/var/youmarket/fo-search/src/middleWares/validation.js:16:9)
at new Promise (<anonymous>)
at jwtPromise (/var/youmarket/fo-search/src/middleWares/validation.js:6:10)
at boService.getSignKey.then (/var/youmarket/fo-search/src/middleWares/validation.js:26:23)
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:182:7)
I am running into an error when trying to deploy to Netlify. I haven't changed anything really crucial since the last build, just updated some text on a shipping policy. This is my project repository for reference https://github.com/ThermalIDTechnologies/up-safety-solutions.
My previous build worked just fine. It probably has something to do with the gatsby-source-prismic plugin. I've tried updating all my dependencies to the latest versions and still receiving the same error. Running build locally receives the same error.
Here is the error from Netlify:
10:04:25 AM: success open and validate gatsby-configs — 0.108
10:04:26 AM: error Expected JSON to be a GraphQL nullable type.
10:04:26 AM: Error in "/opt/build/repo/node_modules/gatsby-source-prismic/gatsby-node.js": Expected JSON to be a GraphQL nullable type.
10:04:26 AM: See our docs page for more info on this error: https://gatsby.dev/issue-how-to
10:04:26 AM:
10:04:26 AM: Error: Expected JSON to be a GraphQL nullable type.
10:04:26 AM:
10:04:26 AM: - default.js:20 Object.<anonymous>
10:04:26 AM: [repo]/[gatsby-source-prismic]/[graphql-compose]/lib/directive/default.js:20 :13
10:04:26 AM:
10:04:26 AM: - v8-compile-cache.js:178 Module._compile
10:04:26 AM: [repo]/[v8-compile-cache]/v8-compile-cache.js:178:30
10:04:26 AM:
10:04:26 AM: - loader.js:789 Object.Module._extensions..js
10:04:26 AM: internal/modules/cjs/loader.js:789:10
10:04:26 AM:
10:04:26 AM: - loader.js:653 Module.load
10:04:26 AM: internal/modules/cjs/loader.js:653:32
10:04:26 AM:
10:04:26 AM: - loader.js:593 tryModuleLoad
10:04:26 AM: internal/modules/cjs/loader.js:593:12
10:04:26 AM:
10:04:26 AM: - loader.js:585 Function.Module._load
10:04:26 AM: internal/modules/cjs/loader.js:585:3
10:04:26 AM:
10:04:26 AM: - loader.js:692 Module.require
10:04:26 AM: internal/modules/cjs/loader.js:692:17
10:04:26 AM:
10:04:26 AM: - v8-compile-cache.js:159 require
10:04:26 AM: [repo]/[v8-compile-cache]/v8-compile-cache.js:159:20
10:04:26 AM:
10:04:26 AM: - SchemaComposer.js:36 Object.<anonymous>
10:04:26 AM: [repo]/[gatsby-source-prismic]/[graphql-compose]/lib/SchemaComposer.js:36:39
10:04:26 AM: - v8-compile-cache.js:178 Module._compile
10:04:26 AM: [repo]/[v8-compile-cache]/v8-compile-cache.js:178:30
10:04:26 AM:
10:04:26 AM: - loader.js:789 Object.Module._extensions..js
10:04:26 AM: internal/modules/cjs/loader.js:789:10
10:04:26 AM:
10:04:26 AM: - loader.js:653 Module.load
10:04:26 AM: internal/modules/cjs/loader.js:653:32
10:04:26 AM:
10:04:26 AM: - loader.js:593 tryModuleLoad
10:04:26 AM: internal/modules/cjs/loader.js:593:12
10:04:26 AM:
10:04:26 AM:
10:04:27 AM: Skipping functions preparation step: no functions directory set
10:04:27 AM: Caching artifacts
10:04:27 AM: Started saving node modules
10:04:27 AM: Finished saving node modules
10:04:27 AM: Started saving yarn cache
10:04:27 AM: Finished saving yarn cache
10:04:27 AM: Started saving pip cache
10:04:27 AM: Finished saving pip cache
10:04:27 AM: Started saving emacs cask dependencies
10:04:27 AM: Finished saving emacs cask dependencies
10:04:27 AM: Started saving maven dependencies
10:04:27 AM: Finished saving maven dependencies
10:04:27 AM: Started saving boot dependencies
10:04:27 AM: Finished saving boot dependencies
10:04:27 AM: Started saving go dependencies
10:04:27 AM: Finished saving go dependencies
10:04:33 AM: Error running command: Build script returned non-zero exit code: 1
10:04:33 AM: Failing build: Failed to build site
10:04:33 AM: failed during stage 'building site': Build script returned non-zero exit code: 1
10:04:33 AM: Finished processing build request in 1m45.555296927s
And here is the error locally:
ERROR
Error in "C:\Users\Admin\Desktop\Development\up-safety-solutions-master\node_modules\gatsby-source-prismic\gatsby-node.js": Expected JSON to be a GraphQL nullable type.
For me the following was true. When I ran gatsby develop I got a different error that explains the issue a bit more.
Error: Cannot use GraphQLScalarType "JSON" from another module or realm.
Ensure that there is only one instance of "graphql" in the node_modules
directory. If different versions of "graphql" are the dependencies of other
relied on modules, use "resolutions" to ensure only one version is installed.
https://yarnpkg.com/en/docs/selective-version-resolutions
Duplicate "graphql" modules cannot be used at the same time since different
versions may have different capabilities and behavior. The data from one
version used in the function from another could produce confusing and
spurious results.
yarn.lock had a few dependencies which depended on different versions of graphql. This resulted in the build not working.
Deleting node_modules and yarn.lock and running yarn install resolved the issue, but I don't know if deleting yarn.lock is good practice.
UPDATE
Running yarn upgrade fixed the dependencies in yarn.lock.
Helo Friends,
I am trying to do a POC with Nightwatch.js on windows machine and ended up getting the below error. Could you please help me in resolving this issue.
Starting selenium server... started - PID: 12796
Error: No source folder defined. Check configuration.
at Function.Runner.readPaths (C:\Users\user_abc\IdeaProjects\nightwatch-cucumber-example\node_modules\nightwatch\lib\runner\run.js:192:11)
at Runner.runner [as run] (C:\Users\user_abc\IdeaProjects\nightwatch-cucumber-example\node_modules\nightwatch\lib\runner\run.js:235:10)
at CliRunner.runner (C:\Users\user_abc\IdeaProjects\nightwatch-cucumber-example\node_modules\nightwatch\lib\runner\cli\clirunner.js:443:23)
at C:\Users\user_abc\IdeaProjects\nightwatch-cucumber-example\node_modules\nightwatch\lib\runner\cli\clirunner.js:395:12
at SeleniumServer.onStarted (C:\Users\user_abc\IdeaProjects\nightwatch-cucumber-example\node_modules\nightwatch\lib\runner\cli\clirunner.js:354:9)
at SeleniumServer.checkProcessStarted (C:\Users\user_abc\IdeaProjects\nightwatch-cucumber-example\node_modules\nightwatch\lib\runner\selenium.js:152:10)
at SeleniumServer.onStderrData (C:\Users\user_abc\IdeaProjects\nightwatch-cucumber-example\node_modules\nightwatch\lib\runner\selenium.js:132:8)
at emitOne (events.js:116:13)
at Socket.emit (events.js:211:7)
at addChunk (_stream_readable.js:263:12)
at readableAddChunk (_stream_readable.js:250:11)
at Socket.Readable.push (_stream_readable.js:208:10)
at Pipe.onread (net.js:607:20)
INFO Selenium process finished.
Timeout when uploading HeroCard to the bot framework on messenger channel.
Error: connect ETIMEDOUT 40.121.91.199:443
at Object.exports._errnoException (util.js:1007:11)
at exports._exceptionWithHostPort (util.js:1030:20)
at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1080:14)
When uploading seeing this error as well
Error: Request to 'https://facebook.botframework.com/v3/conversations/1184220421
633853-1103485719738974/activities/mid.1470863624883%3Ae1dcd9f8a2c3d74b52' failed: [500] Internal Server Error`