For me, when craft tries to update python, it fails because the binary is
in use by craft itself. This patch aims to fix that, by using the python3
binary specified in CraftSettings.ini
Details
Diff Detail
- Repository
- R138 Craft
- Branch
- master
- Lint
No Linters Available - Unit
No Unit Test Coverage - Build Status
Buildable 12003 Build 12021: arc lint + arc unit
I'm not sure this is the good solution, or if something is broken in my setup and I'm the only one experiencing this problem.
I had it too.
Your issue is on Windows? Actually craft should use the one from the settings directly and not python from the path.
Yes, the issue happens on Windows. And I think it always happens, because the line before the one I added reads: "prefix the path with dev-utils/bin"... and Craft's python3.exe is installed right there.
Sorry, forgot about it.
Which package is actually broken? python?
When was your craft install?
I'm not sure if the python bundled in craft (craft\blueprints\dev-utils\python3) or the one from the craft-kde repo (etc\blueprints\locations\craft-kde\binary\_win\python), but one of them (or both?) is being put in the PATH earlier than the python defined in the settings INI file. So it can't be upgraded by craft because it is in use.
On a side not, we probably don't need to install python3 twice, but regardless of that I think my patch is correct.
I tried to reproduce your issue and failed with the latest version of craft.
The python in CraftRoot/python is only meant to be used for for applications that need to ship python.
In your case I'd recommend to manually set $env:CRAFT_PYTHON to the system python and then force an update of the python3 wrapper.
Also make sure that Paths/Python in etc/CraftSettings.ini points to the system python.
If recrafting python3 fails, try to invoke the system python directly with craft/bin/craft.py.