-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
File path infer problem #13267
Comments
Could you provide a small reproduction repo to investigate? This would be very helpful, thanks! |
sidharthachatterjee
added
the
status: needs reproduction
This issue needs a simplified reproduction of the bug for further troubleshooting.
label
Apr 10, 2019
Reproduction link: https://github.com/suziwen/gatsby-file-path-infer-problem
|
stefanprobst
removed
the
status: needs reproduction
This issue needs a simplified reproduction of the bug for further troubleshooting.
label
Apr 11, 2019
Thanks for the reproduction, this should be fixed with #13289 |
pieh
pushed a commit
that referenced
this issue
Apr 11, 2019
In the `fileByPath` resolver, we need a node's parent `File` node to resolve relative to absolute paths. For this we use `findRootNodeAncestor`, which will return a node's root node. This can be problematic for (unusual) scenarios like in #13267 where a node has more than one `File` node ancestor. We should just use the closest `File` parent. Fixes #13267
Published |
This was referenced Sep 16, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Assuming I have three node
I hope C's property (cover) will be inferred to
/home/test/b/featured.png
, but not/home/test/a/featured.png
.Is it possible get the
/home/test/b/featured.png
cover?or
have any custom condition function to stop find root node?
The text was updated successfully, but these errors were encountered: