-
Notifications
You must be signed in to change notification settings - Fork 196
Building a Gatsby site with Yarn 1.0 results in ton of importing errors #89
Comments
for our troubleshooting: similar report from another customer: https://app.intercom.io/a/apps/q245f50x/respond/inbox/1479299/conversations/12192293322 |
Netlify Support todo:
|
We were unable to get a simpler example that we could try debugging to fail, @Aleksion - if you come up with a repro case that is less involved, let us know and we'll reopen this. |
Sounds good. I'll dive into it the next time I hit it! |
arg this is a really magical bug :/ I can't manage to put a simpler repro together but this fails consistently on every gatsby netlify deploy when we try with workspaces. Myself and @KyleAMathews independently confirm it does not occur running the docker image locally, or in any other context except for an actual deploy. We've tried changing the versions of node and yarn to no effect and i see no information about this error anywhere: https://app.netlify.com/sites/using-wordpress/deploys/59f8d06ddf995350b4b3712a |
when you run the docker image locally, do you follow the steps to run with
cache just about the 'Contributing' section in README.md? If not - and if
you don't also set all your environment variables like this:
```
test-tools/test-build.sh path/to/your/repo 'export VAR1=value ; export
VAR2=value2 ; your build command'
```
(and then run it again with the `export T=tmp/tmp.XXXXX` in there as well
to get the cache setup)
…On Tue, Oct 31, 2017 at 12:43 PM, Jason Quense ***@***.***> wrote:
arg this is a really magical bug :/ I can't manage to put a simpler repro
together but this fails consistency on every gatsby netlify deploy when we
try with workspaces. Myself and @KyleAMathews
<https://github.com/kyleamathews> independently confirm it does not occur
running the docker image locally, or in any other context *except* for an
actual deploy. We've tried changing the versions of node and yarn to no
effect and i see no information about this error anywhere:
https://app.netlify.com/sites/using-wordpress/deploys/
59f8d06ddf995350b4b3712a
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub
<#89 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAN-oHhE0hyvZkg5b6ZBzkhKNQQNSXf7ks5sx3hjgaJpZM4PzEti>
.
|
As is usually the case, just after posting I figures it out. The problem is that the default YARN_FLAGS ignores optional deps which for some reason doesn't play nice with workspaces with some packages with post install scripts. Still not sure why I can't reproduce the issue with docker locally tho |
so - what YARN_FLAGS do work? We'll want to write some documentation
around that once we understand your solution :)
…On Tue, Oct 31, 2017 at 6:20 PM, Jason Quense ***@***.***> wrote:
As is usually the case, just after posting I figures it out. The problem
is that the default YARN_FLAGS ignores optional deps which for some reason
doesn't play nice with workspaces with some packages with post install
scripts. Still not sure why I can't reproduce the issue with docker locally
tho
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub
<#89 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAN-oFXSUJLA8wsBlg_dSPlbf-NltiGBks5sx8dBgaJpZM4PzEti>
.
|
I am not sure why As an aside I do think better defaults for YARN_FLAGS should include |
Can confirm that setting I get the error when Can we change the defaults ala what @jquense suggests and maybe finally update the default Yarn version as well? :) #122 |
Yarn finally updated in #130. I'll close this issue when the new image has been deployed. |
I'm guessing the new image was deployed within the last 24 hours? Our CSS just broke on a gatsby site |
Yes, my apologies. We deployed yesterday afternoon. @Bouncey if you reach out to support, they can help solve your problem. |
Hi,
I've been fighting a bit with getting GatsbyJS working on Netlify. The root issues is in gatsby: gatsbyjs/gatsby#2001 (comment)
Which is caused due to GatsbyJS using a global graphql. Meaning this isn't an error on your end.
As can be seen in the issue, the suggested solution is to use Yarn resolutions and force every yarn dependency to resolve to the same version.
However, I haven't been able to get Yarn 1.0 to run succesfully. Whenever I try to build it stumbles over a new missing dependency in the build flow:
UPDATE:
I've tried to reproduce it with a new starter gatsby project without luck. I'll keep digging on my end of things, but if you have any ideas I'm all ears
The text was updated successfully, but these errors were encountered: