Editing a markdown file can cause the site to error while gatsby develop is running.
Gatsby version: from master
Node.js version: 9.5.0
Operating System: macOS
see https://github.com/gatsbyjs/gatsby/tree/c246262d10830eda09135ff5f8a3ee64883757ce/www
Page displays an error:

Page should not display an error 馃槃
cd wwwrm -r .cacheyarn run developdocs/docs/graphql-reference.mdTypeError: Cannot read property 'markdownRemark' of undefined, which will remain until deleting the .cache directoryI've been able to recreate this with various docs pages and blog posts - all markdown files. Maybe the query data isn't being retrieved from the cache properly?
This query will still work in graphiql:
{
markdownRemark(fields: { slug: { eq: "/docs/querying-with-graphql/" } }) {
html
excerpt
timeToRead
fields {
slug
anchor
}
frontmatter {
title
}
}
}
Saw this too just now.
I wonder if this is similar to the issue that @peduarte was seeing earlier today?
Nope, actually my issue was me being stupid and using mutable array methods on props.data 馃槖馃敨
I got the same issue. If I had link in .md, browser throw me the exact same error.
[Edit] I don't know why but It seems a little bit random to me. I didn't change anything and it works now. \o/
[Edit 2] I add a new link and got the error again.
Same issue here, every time I edit a markdown file.
but yeah this issue happens to me, when I edit a markdown file. but not ALL the time.
I'm seeing this issue, too. Bare bones Gatsby install. Just added transformer remark. Most edits to my .md file break the develop build and I have to restart the server to get it working again.
This should have fixed the bug, thanks for your patience!
https://github.com/gatsbyjs/gatsby/pull/4213/files/cb52bc81b85f466e846da528bc0ec9b0eead9ec4#diff-a45448af33cc109010d5aab8911336dd