On 6/27/24 09:34, Magnus Hagander wrote: > > > It also is on python 3.7 which should be 3.9 to match what's > deployed. > > In general, I'd recommend starting off the debian bullseye > container > > instead of the python specific one -- that's what's used in the > > production deployments, so it makes sense to keep to the same. > > That way it could also be using the same versions of the debian > > packages for all requirements (basically everything except Django > > itself), to ensure it's exactly the same. > > > > //Magnus > > Which Debian release is used by PG infrastructure? > > > Currently, bullseye.
When using python 3.9 PyYAML 3.13 (requirements.txt) fails to compile. --- ext/_yaml.c: In function ‘__Pyx_modinit_type_init_code’: ext/_yaml.c:25698:25: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’ 25698 | __pyx_type_5_yaml_Mark.tp_print = 0; | ^ ext/_yaml.c:25718:28: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’ 25718 | __pyx_type_5_yaml_CParser.tp_print = 0; | ^ ext/_yaml.c:25732:29: error: ‘PyTypeObject’ {aka ‘struct _typeobject’} has no member named ‘tp_print’ 25732 | __pyx_type_5_yaml_CEmitter.tp_print = 0; | ^ ---
I assume, PyYAML was updated on system but not requirements.txt. Possible to verify following package versions from the PG Infra server?
We get all dependencies from Debian, not from pip, when possible. And we use the standard versions on debian bullseye, so as long as you haven't configured backports or unstable or something like that, you should get the correct one automatically. The only things we get from pip is django itself and asgiref.