-
-
Notifications
You must be signed in to change notification settings - Fork 63
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
Problematic makeRelativeToProject
use in importGQLDocument
#843
Comments
Additional thought: For maximum flexibility the QGL document could be accepted as a string instead of as a filename. The HLS issue linked above suggests the use of the
Where |
Summary: The
makeRelativeToProject
call inimportQGLDocument
should be removed.Detail:
importQGLDocument
is using the functionmakeRelativeToProject
internally which implies that the parameter toimportQGLDocument
should be a relative path. However in at least one of the examples the path passed is implied to be an absolute path due to the explicitmakeRelativeToProject
call:In the case above,
makeRelativeToProject
ends up getting called twice; this works by coincidence because the project root usually resolves to "./
".But in multi-component projects this is not the case and the extra
makeRelativeToProject
will cause problems. In my case this was compounded by a bug in Haskell Language Server which is returning an incorrect root for multi-component projects; the internal call tomakeRelativeToProject
made the HLS bug even harder to work around.So, that's why I think
makeRelativeToProject
should be removed fromimportQGLDocument
. The exact call I'm talking about is here. I also see a usage inreadWith
; that should probably go too.The text was updated successfully, but these errors were encountered: