Comments (5)
I am having this issues as well while following the tutorial: https://blog.strapi.io/building-a-static-website-using-gatsby-and-strapi/
I am also having
error GraphQL Error Unknown field `allStrapiArticle` on type `Query`
38:5 error Cannot query field "allStrapiArticle" on type "Query" graphql/template-strings
success open and validate gatsby-configs — 0.006 s
success load plugins — 0.265 s
success onPreInit — 0.391 s
success delete html and css files from previous builds — 0.019 s
success initialize cache — 0.005 s
success copy gatsby files — 0.018 s
success onPreBootstrap — 0.005 s
⠁ Starting to fetch data from Strapi (articles)
Starting to fetch data from Strapi (users)
error Plugin gatsby-source-strapi returned an error
Error: connect ECONNREFUSED 127.0.0.1:1337
warning The gatsby-source-strapi plugin has generated no Gatsby nodes. Do you need it?
success source and transform nodes — 0.081 s
success building schema — 0.242 s
success createPages — 0.001 s
success createPagesStatefully — 0.038 s
success onPreExtractQueries — 0.003 s
success update schema — 0.108 s
error GraphQL Error Unknown field `allStrapiArticle` on type `Query`
file: /root/gatsby-strapi-tutorial/blog/src/pages/index.js
1 |
2 | query IndexQuery {
> 3 | allStrapiArticle {
| ^
4 | edges {
5 | node {
6 | id
7 | title
8 | content
9 | }
10 | }
11 | }
12 | }
13 |
success extract queries from components — 0.127 s
⠁ (node:11534) DeprecationWarning: Passing lineNumber and colNumber is deprecated to @babel/code-frame. Please use `codeFrameColumns`.
success run graphql queries — 0.012 s — 5/5 440.27 queries/second
success write out page data — 0.004 s
success write out redirect data — 0.001 s
⡀ onPostBootstrapdone generating icons for manifest
success onPostBootstrap — 0.220 s
info bootstrap finished - 3.578 s
ERROR Failed to compile with 1 errors 10:01:12 PM
error in ./src/pages/index.js
Module Error (from ./node_modules/eslint-loader/index.js):
/root/gatsby-strapi-tutorial/blog/src/pages/index.js
38:5 error Cannot query field "allStrapiArticle" on type "Query" graphql/template-strings
✖ 1 problem (1 error, 0 warnings)
@ ./.cache/sync-requires.js 15:50-113
@ ./.cache/app.js
@ multi (webpack)-hot-middleware/client.js?path=/__webpack_hmr&reload=true&overlay=false ./.cache/app
✖ 「wdm」:
ERROR in ./src/pages/index.js
Module Error (from ./node_modules/eslint-loader/index.js):
/root/gatsby-strapi-tutorial/blog/src/pages/index.js
38:5 error Cannot query field "allStrapiArticle" on type "Query" graphql/template-strings
✖ 1 problem (1 error, 0 warnings)
@ ./.cache/sync-requires.js 15:50-113
@ ./.cache/app.js
@ multi (webpack)-hot-middleware/client.js?path=/__webpack_hmr&reload=true&overlay=false ./.cache/app
ℹ 「wdm」: Failed to compile.
WAIT Compiling... 10:01:12 PM
ℹ 「wdm」: Compiling...
ERROR Failed to compile with 1 errors 10:01:12 PM
error in ./src/pages/index.js
Module Error (from ./node_modules/eslint-loader/index.js):
/root/gatsby-strapi-tutorial/blog/src/pages/index.js
38:5 error Cannot query field "allStrapiArticle" on type "Query" graphql/template-strings
✖ 1 problem (1 error, 0 warnings)
@ ./.cache/sync-requires.js 15:50-113
@ ./.cache/app.js
@ multi (webpack)-hot-middleware/client.js?path=/__webpack_hmr&reload=true&overlay=false ./.cache/app
✖ 「wdm」:
ERROR in ./src/pages/index.js
Module Error (from ./node_modules/eslint-loader/index.js):
/root/gatsby-strapi-tutorial/blog/src/pages/index.js
38:5 error Cannot query field "allStrapiArticle" on type "Query" graphql/template-strings
✖ 1 problem (1 error, 0 warnings)
@ ./.cache/sync-requires.js 15:50-113
@ ./.cache/app.js
@ multi (webpack)-hot-middleware/client.js?path=/__webpack_hmr&reload=true&overlay=false ./.cache/app
ℹ 「wdm」: Failed to compile.
from gatsby-source-strapi.
Hi @clabmb, the GraphQL error you are getting is most likely due to the initial error that we were mentioning initially, about the Strapi host not being found. Make sure you have a Strapi instance effectively running on 127.0.0.1:1337
and see if the errors persist.
from gatsby-source-strapi.
Hi @elussich, thanks.... I just fix the problem... I was so stupid that i forgot to start the strapi service....
from gatsby-source-strapi.
Hello @elussich I suggest you to submit a PR if you want this feature.
We don't have time dedicated to work on your point.
from gatsby-source-strapi.
Thanks for your interest in this project. This plugin is moving into the Gatsby User Collective and this repo will be archived. Please open an issue in that repository, submit a PR if you'd like to see this implemented, or join us on Discord if you have questions!
from gatsby-source-strapi.
Related Issues (20)
- Gatsby develop hangs for minutes on "Source and Transform Nodes" HOT 1
- Gatsby Source not fetching all locales date throwing an error
- Issue generating links for nested collection routes HOT 1
- Plugin doesn't update data when content on admin changes HOT 2
- Error: EPERM: operation not permitted, lstat HOT 2
- "Rich text" field makes a ERROR #11321 PLUGIN HOT 1
- How to fetch custom API HOT 4
- image from strapi component doesn't show up in graphql HOT 3
- Single Types don't update on rebuild if multiple locales exist HOT 1
- Missing images from richtext field HOT 1
- Image Processing in HTML code HOT 2
- Plugin is not pulling data from Strapi when there is a timestamp on the cache. HOT 1
- ERROR #11321 PLUGIN "gatsby-source-strapi" threw an error while running the sourceNodes lifecycle: connect ECONNREFUSED ::1:1337 HOT 5
- Unable to make optional fileds. HOT 4
- CreateTypes Camel case vs. snake case HOT 1
- Is this plugin still maintained? HOT 31
- Getting "Unknown type" for the starter project HOT 2
- Cannot retrieve sub-components of components in graphql? HOT 13
- GatsbyImageData in dynamic zones HOT 2
- Pull plugin comments data into Gatsby HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gatsby-source-strapi.