-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
relay-compiler --watchman false option fails with FATAL ERROR: v8::ToLocalChecked Empty MaybeLocal. when --src is current directory #2042
Comments
--watchman false
option fails with FATAL ERROR: v8::ToLocalChecked Empty MaybeLocal.
when src
is current directory
I can confirm this on v1.4.1 |
@stevehollaar did you find a workaround for this? |
I started digging a bit into this and found that The filtering as specified by My current workaround for a next.js project is explicitly specifying source directories relative to |
cc @robrichard @leebyron (#1966) I can't think of a smart way to fix this based on @simenbrekken's observations. Any thoughts on this? If nothing else, I think specifically showing a descriptive error message when --src === "." and the "--exclude" option is used like this could be useful (as a last resort):
|
I think this was working with node 6, but is broken now with node 8. I opened an issue in the fast-glob repo: mrmlnc/fast-glob#23 |
It complained that Watchman wasn't installed (even though wasn't relay-compiling with --watch). Needed to update relay packages and move run relay-compile against sub folder (facebook/relay#2042)
Summary: * #2042 * mrmlnc/fast-glob#23 * Fix for #2042. Now works fine with more then 500 000 entries (maybe more – more I have not tried). * Also this is a [new release of `fast-glob` package](https://github.com/mrmlnc/fast-glob/releases/tag/2.0.0), which became even faster and more stable. * If you want exclude `node_modules` directory you can use `**/node_modules` pattern ([documentation](https://github.com/mrmlnc/fast-glob#how-to-exclude-directory-from-reading)). Sorry for the problems from #2042. Closes #2295 Reviewed By: kassens Differential Revision: D6770665 Pulled By: jstejada fbshipit-source-id: dcc0920c75aed32ca0b1d9d34aa6b1fdbeda95be
watchman option still does not work. |
@steida, what do you mean that it still doesn't work? Which version of node are you running? Did you try @simenbrekken's workaround? |
Why is watchman needed without watching anyway? Does anybody know how to install it on circle-ci 2? Thank you. |
You can check it here: https://github.com/este/este |
Hello, @steida, Unfortunately, this does not looks like a bug inside my package ( I see that you trying to pass the following set of patterns to the [ 'components/A.js/*.+(js)',
'components/AreYouSureConfirm.js/*.+(js)',
// …
'components/editor/*.+(js)',
'mutations/CreateWebMutation.js/*.+(js)',
// …
'mutations/utils/*.+(js)',
'pages/__generated__/*.+(js)',
// …
'pages/sign-in.js/*.+(js)' ] But I see that you have the following tree on the file system:
When you pass a pattern like JFYI: This is the Task that was created for your pattern: {
base: 'components/A.js', // The parent directory
dynamic: true,
patterns: [
'components/A.js/*.+(js)',
'!**/node_modules',
'!**/__mocks__',
'!**/__tests__',
'!**/__generated__'
],
positive: [
'components/A.js/*.+(js)'
],
negative: [
'**/node_modules',
'**/__mocks__',
'**/__tests__',
'**/__generated__'
]
} This issue related to wildcards inside npm scripts. Before sending the patterns to the script, they are expanded by shell. You should wrap the patterns in quotation marks:
Or After it all works fine: [ 'components/**/*.+(js)',
'mutations/**/*.+(js)',
'pages/**/*.+(js)' ] |
@mrmlnc Wow, it works. Finally, :-) Thank you ❤️ |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Using version
1.2.0
This seems to only happen when
src
is the current directory:.
Setting
src
to a subdirectory works as expected:The text was updated successfully, but these errors were encountered: