Core26: bundled Python changes

oHi,

I tried with stable Snapcraft 9.0.0 (rev. 18124) and core26 20260531 (rev. 409).

  • venv is still not hermetic with other parts of the snap during build
  • case A: same python libs than snapcraft ones: does NOT build
  • case B: different python libs version than snapcraft ones: does NOT build

Same tests than before:

  • Case A (python 3.14):
Building test3
:: + python3 -V
:: Python 3.14.4
:: + pip list
:: Traceback (most recent call last):
::   File "/root/stage/bin/pip", line 5, in <module>
::     from pip._internal.cli.main import main
:: ModuleNotFoundError: No module named 'pip'
  • Case B (python 3.13):
Building test3
:: + python3 -V
:: Python 3.13.14
:: + pip list
:: Traceback (most recent call last):
::   File "/root/stage/bin/pip", line 3, in <module>
::     from pip._internal.cli.main import main
:: ModuleNotFoundError: No module named 'pip'

Thanks.

Edit:

When snap is built with case A (= no test3 performed), python modules are not loaded when running the snap.