It would be really good if the bastions could be updated to something more modern, so we could have a uniform python infrastructure everywhere. I think I once opened a phab ticket for this, which was closed as some variation on infeasible.
I ran into exactly the issue described below myself. After trying a bunch of various workarounds, I ended up building my own python 3.7 from source. That's suboptimal in so many ways, but it was the only way I could find to get a consistent setup between my test/dev environment on the bastion and my production environment on kubernetes.
At some point, this is going to become a more acute problem, since 3.5 is officially end-of-life.
On Oct 7, 2020, at 11:41 AM, Bryan Davis bd808@wikimedia.org wrote:
On Wed, Oct 7, 2020 at 9:15 AM maxime delzenne maxime.delzenne@gmail.com wrote:
Hello,
First of all, thank you to Chico Venancio for the explanation about "kubectl describe". However it still did not start...
It seems to me that there is a problem with python3.7. When I install the venv for python3.7 (web and base, same problem) and I do a command "hello Kubernetes!", it crashes (deployment file here https://paste.toolforge.org/view/89fc0b13). If I replace 3.7 through 3.5, then It works and returns the hello Kubernetes.
After bringing back everything to Python 3.5, the Celery worker is running (at last!).
This sounds suspiciously like you made the virtual environment from a login shell on one of the Toolforge bastions (where python3 is actually python3.5). To make a Python 3.7 virtual environment it is necessary to first enter a python3.7 container running on the Kubernetes cluster. This can be done using the `webservice python3.7 shell` command. See https://wikitech.wikimedia.org/wiki/Help:Toolforge/Web/Python#Virtual_Environments_and_Packages for related information.
Bryan
Bryan Davis Technical Engagement Wikimedia Foundation Principal Software Engineer Boise, ID USA [[m:User:BDavis_(WMF)]] irc: bd808
Wikimedia Cloud Services mailing list Cloud@lists.wikimedia.org (formerly labs-l@lists.wikimedia.org) https://lists.wikimedia.org/mailman/listinfo/cloud