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

Local header in codebase not found #79

Open
vadi2 opened this issue Mar 28, 2023 · 1 comment
Open

Local header in codebase not found #79

vadi2 opened this issue Mar 28, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@vadi2
Copy link
Contributor

vadi2 commented Mar 28, 2023

I'm getting a FileNotFoundError: [Errno 2] No such file or directory: '/src/utils.h' error when src/utils.h is a valid header and it is listed in CMakeLists.txt.

What could be going wrong?

@ZedThree
Copy link
Owner

The real file path is ../../src/utils.h which is somehow getting expanded to /src/utils.h -- note the leading slash. So something has gone wrong in our file path fixing code I would guess, probably this line:

resolved_path = str(pathlib.Path(filename).resolve().absolute())

I have a couple of ideas how that might happen, but main guess is that it could be that it's a relative path from the build directory and we're not handling that correctly.

@ZedThree ZedThree added the bug Something isn't working label Mar 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants