Describe the bug
Cannot query field "allDoczEntries" on type "Query". Did you mean "allDoczDb"?
File: node_modules/gatsby-theme-docz/src/node/createPages.js:30:10
Running docz dev and getting the above error.
A clear and concise description of what the bug is.
To Reproduce
There was an error in your GraphQL query:
Cannot query field "allDoczEntries" on type "Query". Did you mean "allDoczDb"?
File: node_modules/gatsby-theme-docz/src/node/createPages.js:30:10
success createPages - 0.063 s
success createPagesStatefully - 0.070 s
success onPreExtractQueries - 0.020 s
success update schema - 0.036 s
ERROR
There was a problem parsing "/Users/mkruk/dev/docz/node_modules/gatsby-theme-docz/templates/Layout.tpl.js"; any GraphQL fragments or queries in this file were not processed.
This may indicate a syntax error in the code, or it may be a file type that Gatsby does not know how to parse.
In order to allow us to quickly reproduce you issue please include a link to a reproduction repository.
Expected behavior
A clear and concise description of what you expected to happen..
Environment
Additional context/Screenshots
Add any other context about the problem here. If applicable, add screenshots to help explain.
same issue
I don't know why, but the error goes away if the command to start is: yarn gatsby develop (as stated on https://www.docz.site/docs/gatsby-theme) instead of yarn run develop.
I am getting the same error
I am also getting the same error
Hello !
Could you please provide the rest of the logs ? Or alternatively a repo to reproduce this error ?
I suspect something crashed before the GraphQL error.
I just followed the getting started guide, the only output I get is:
ERROR #85901 GRAPHQL
There was an error in your GraphQL query:
Cannot query field "allDoczEntries" on type "Query". Did you mean "allDoczDb"?
File: node_modules/gatsby-theme-docz/lib/createPages.js:27:10
Although after a restart I get no error but localhost:3000 just has a Gatsby 4o4 page saying "Gatsby.js development 404 page There's not a page yet at /"
It might be worth mentioning I'm using yarn Workspaces so node_modules are hoisted up.
Hey @DominicTobias,
You're right, I followed the getting started instructions and they led to an error.
I updated them now, could you try the updated instructions here ?
@rakannimer thanks works with those, only thing I changed was the .mdx to follow that Button example 馃憤
Closing this for inactivity, please feel free to re-open and add more information if the error is still happening
I'm getting the same error (except the line number changed) @rakannimer, but only in my project, not with the example. I'm not sure what would be interfering with it. Running the latest. Trying to track it down, but having trouble.
ERROR #85901 GRAPHQL
There was an error in your GraphQL query:
Cannot query field "allDoczEntries" on type "Query". Did you mean "allDoczDb"?
File: ../node_modules/gatsby-theme-docz/src/node/createPages.js:30:10
Hey @brandonarbini
Any chance you can share the code to your repo so I can help debug ?
If not, make sure to clear all cache and try again :
rm -rf node_modules yarn.lock .docz package-lock.json && yarn && yarn docz dev
@rakannimer Apologies for not being more helpful. I completely reworked the project. I got Docz 2 working first and then pulled over components one-by-one. I wish I could point to the exact thing that made it all work, but there was too much going on and I tried too many things. If it breaks again I'll try and figure it out and let you know. Thanks!
Hey @brandonarbini
Any chance you can share the code to your repo so I can help debug ?
If not, make sure to clear all cache and try again :
rm -rf node_modules yarn.lock .docz package-lock.json && yarn && yarn docz dev
I tried this but still getting GRAPHQL error
I just followed the getting started guide, the only output I get is:
ERROR #85901 GRAPHQL There was an error in your GraphQL query: Cannot query field "allDoczEntries" on type "Query". Did you mean "allDoczDb"? File: node_modules/gatsby-theme-docz/lib/createPages.js:27:10Although after a restart I get no error but
localhost:3000just has a Gatsby 4o4 page saying "Gatsby.js development 404 page There's not a page yet at /"It might be worth mentioning I'm using yarn Workspaces so node_modules are hoisted up.
@jesperorb @rakannimer I am getting same errror with the GRAPHQL ERROR
`---
name: Button
menu: Components
import { Props, Playground } from 'docz'
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
import { faPen, faTrash, faPlus } from '@fortawesome/free-solid-svg-icons'
import { Button } from '.'
| Prop | Value | Default |
| buttonClasses | 'primary-button' | true |
| 'secondary-button' | - | |
| 'danger-button' | - | |
| 'transparent-button' | - | |
| 'section-placeholder-button' | - | |
| 'content-placeholder-button' | - | |
| 'icon-button' | - | |
| 'round' | - |
Disable using disabled prop.
<Button buttonClasses='content-placeholder-button' disabled>
<span><FontAwesomeIcon icon={faPlus} /></span>
<span>Click here to add a banner</span>
</Button>
Hey @brandonarbini
Any chance you can share the code to your repo so I can help debug ?
If not, make sure to clear all cache and try again :
rm -rf node_modules yarn.lock .docz package-lock.json && yarn && yarn docz dev
Thank you.It's work for me.
In my case it was because I had src: "./src" in my doczrc.js (which used to be ok in v1).
Not sure why but removing that line removed the error.
Hey @xaviergonz
Any chance the repo where you got the error is public ?
Would love to reproduce and investigate this.
just generate a new typescript project and put that line in the doczrc file, it should already happen there
That didn't work, here's what I tried :
npx create-docz-app app --example typescript
then in doczrc.js I added src: "./src" but it worked as expected.
A catch the same problem, is not solved yet?
same here
I hit the same error too with 2.2.0 and 2.3.1 (Windows, Node 10.15.3), but things are kind of opaque and can't really tell what is wrong...
Most helpful comment
I hit the same error too with 2.2.0 and 2.3.1 (Windows, Node 10.15.3), but things are kind of opaque and can't really tell what is wrong...