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

Cache path inconsistency in cc and python? #651

Closed
uduse opened this issue Apr 12, 2022 · 1 comment · Fixed by #656
Closed

Cache path inconsistency in cc and python? #651

uduse opened this issue Apr 12, 2022 · 1 comment · Fixed by #656
Assignees
Labels
Bug Something isn't working
Milestone

Comments

@uduse
Copy link
Contributor

uduse commented Apr 12, 2022

I noticed that theses two files are using different conventions for creating cache paths. The cc file says the python file should align with the cc file, but they are still different. Is this intended?

return Path(forced) / relpath
elif os.environ.get("HOME"):
return Path("~/.cache/compiler_gym").expanduser() / relpath
else:
return Path(f"/tmp/compiler_gym_{getuser()}/cache") / relpath

const char* home = std::getenv("HOME");
if (home) {
return fs::path(home) / ".local/cache/compiler_gym";
} else {
// $HOME may not be set under testing conditions. In this case, use a

@uduse uduse changed the title Cache path inconsistency? Cache path inconsistency in cc and python? Apr 12, 2022
@ChrisCummins
Copy link
Contributor

Hi @uduse, that is a bug! Please patch the .py file. They should both be ~/.local/cache/compiler_gym.

Thanks for the report, good catch!

Cheers,
Chris

@ChrisCummins ChrisCummins added the Bug Something isn't working label Apr 13, 2022
@ChrisCummins ChrisCummins added this to the v0.2.4 milestone Apr 13, 2022
@ChrisCummins ChrisCummins self-assigned this Nov 29, 2022
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

Successfully merging a pull request may close this issue.

2 participants