Open mfdgroot opened 2 months ago
This looks like a common problem with pip: https://github.com/pypa/pip/issues/8063 that hasn't been resolved. @pavoljuhas have you encountered anything like this before?
已经被这个折磨一天了,最终选择折中的方法 ,使用pipx 我在下面记录我自己探索解决方法的过程 [Having been tortured by this all day, I finally chose the compromise and used pipx Below I document my own search for a solution] https://memos.haowuan.top/m/gUAJKSzdjEjJZk3grRWL8C
going to close this an issue with pip, feel free to reopen if there's another solution.
This looks like a common problem with pip: pypa/pip#8063 that hasn't been resolved. @pavoljuhas have you encountered anything like this before?
This seems to happen because openfermion declares documentation files as data_files and as such they would install under PREFIX/openfermion. The package sources go to PREFIX/lib/pythonX.Y/site-packages/openfermion. The --target=TARGET
option makes pip install both the docs and sources to TARGET/openfermion
and it seems only the documentation files survive.
I can think of two remedies
(1) use pip install --prefix=/path/to/prefix
instead of --target=TARGET
so that the openfermion
directories for docs and package sources are different
OR
(2) update openfermion/setup.py to have documentation files included as package_data
so they get installed somewhere under .../site-packages/openfermion instead of to PREFIX/openfermion.
thanks @pavoljuhas I think 2 is probably best.
There seems to be an error when installing openfermion with pip into a specific target dir. When running
pip install -t target openfermion
, I getWARNING: Target directory /xxx/target/openfermion already exists. Specify --upgrade to force replacement.
. This happens toward the end of the installation process. This is what's in the dir without running with--upgrade
and getting the warning:And this is after running with
--upgrade
and without warning:So all of the module files are also gone.