Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug parsing an array of dates from a yaml file on a cold build #3953

Closed
lourd opened this issue Feb 9, 2018 · 4 comments · Fixed by #3955
Closed

Bug parsing an array of dates from a yaml file on a cold build #3953

lourd opened this issue Feb 9, 2018 · 4 comments · Fixed by #3955
Assignees
Labels
type: bug An issue or pull request relating to a bug in Gatsby

Comments

@lourd
Copy link
Contributor

lourd commented Feb 9, 2018

Description

When parsing an array of dates from a yaml file, gatsby fails to add it to the GraphQL schema when doing a build without a cache. This triggers warnings about invalid queries, because the property being requested doesn't exist. After killing the process and starting gatsby again, leaving the cache in place, the problem is resolved.

I've only observed this for data coming from yaml files, not JSON files.

This may be related to the work done in #3688 that resolved #3556.

Environment

Gatsby version: 1.9.190
Node.js version: 8.9
Operating System: macOS 10.12.6 and whatever version of Debian Netlify is using on their Docker container

Steps to reproduce

See this repo https://github.com/lourd/gatsby-yaml-dates-array-bug

@pieh pieh self-assigned this Feb 9, 2018
@pieh pieh added the type: bug An issue or pull request relating to a bug in Gatsby label Feb 9, 2018
@pieh
Copy link
Contributor

pieh commented Feb 9, 2018

I will investigate this.

@pieh
Copy link
Contributor

pieh commented Feb 9, 2018

Just quick question - is this regression? Was it working earlier on cold build?

@lourd
Copy link
Contributor Author

lourd commented Feb 9, 2018

I just tried my test repo with Gatsby 1.9.185 and it also failed. (it's under a new branch called regression if you want to try it out). So it does not look like this is a regression. I guess your new work on date parsing is unrelated.

@pieh
Copy link
Contributor

pieh commented Feb 9, 2018

Yeah, I didn't change anything related to date specifically (just moved code around).

I see where the issue is and will make pull request with fix soon.

@ghost ghost added the review label Feb 9, 2018
@ghost ghost removed the review label Feb 9, 2018
This was referenced Sep 5, 2021
This was referenced Sep 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug An issue or pull request relating to a bug in Gatsby
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants