Links of affected pages in Plone Documentation, if any.
No response
Description
I created a documentation PR last week, and now wanted to continue on it:
$ make livehtml
python3 -m venv . || virtualenv --clear --python=python3 .
Error: [Errno 2] No such file or directory: '/Users/maurits/community/plone-coredev/6.0/documentation/docs/bin/python3'
created virtual environment CPython3.11.8.final.0-64 in 4533ms
creator CPython3Posix(dest=/Users/maurits/community/plone-coredev/6.0/documentation/docs, clear=True, no_vcs_ignore=False, global=False)
seeder FromAppData(download=False, pip=bundle, wheel=bundle, setuptools=bundle, via=copy, app_data_dir=/Users/maurits/Library/Application Support/virtualenv)
added seed packages: pip==21.2.3, setuptools==57.4.0, wheel==0.37.0
activators PythonActivator,CShellActivator,FishActivator,PowerShellActivator,BashActivator
bin/pip install -r requirements-initial.txt
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
bash: line 1: bin/pip: No such file or directory
make: *** [bin/python] Error 127
So for whatever reason (no idea), python3 -m venv . failed, so the Makefile fell back to calling virtualenv --clear. Since a few years, --clear actually removes the target directory. So my checkout of the documentation repo was gone.
No worries: no work was lost.
Still, I would like to avoid this. :-D
Never call virtualenv, only use python3 -m venv .. I suppose the virtualenv fallback was only there to support Python versions that did not yet have the venv module. This should not be an issue anymore.
I would be happy to make a PR if wanted, but it would be good to know the preference first.
Links of affected pages in Plone Documentation, if any.
No response
Description
I created a documentation PR last week, and now wanted to continue on it:
So for whatever reason (no idea),
python3 -m venv .
failed, so the Makefile fell back to callingvirtualenv --clear
. Since a few years,--clear
actually removes the target directory. So my checkout of the documentation repo was gone.No worries: no work was lost. Still, I would like to avoid this. :-D
Two possible solutions, for this line in the Makefile:
--clear
option.virtualenv
, only usepython3 -m venv .
. I suppose thevirtualenv
fallback was only there to support Python versions that did not yet have thevenv
module. This should not be an issue anymore.I would be happy to make a PR if wanted, but it would be good to know the preference first.