Skip to content
This repository has been archived by the owner on Feb 4, 2020. It is now read-only.

CLCACHE_PROFILE ignored when clcache is installed as .exe from chocolatey or pip #363

Open
Artalus opened this issue Nov 15, 2019 · 1 comment

Comments

@Artalus
Copy link

Artalus commented Nov 15, 2019

Apparently, because setup.py mentions

    entry_points={
          'console_scripts': [
              'clcache = clcache.__main__:main',

, the if 'CLCACHE_PROFILE' in os.environ: check is ignored, since it is not located in def main(). I can reproduce this on two machines that has clcache installed as clcache.exe: one was installed from Chocolatey due to lack of MSVC 14.0, another from pip install.

@Artalus
Copy link
Author

Artalus commented Nov 15, 2019

Also, if I move this check into some def main_wrapper() and make it an entrypoint, cProfile.run will argue that main() is not defined. I had to replace it with cProfile.run('import clcache\nclcache.__main__.main()', ....

Not sure how it was supposed to work for previous 3 years since CLCACHE_PROFILE introduction...

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant