samba-tool ImportError: No module named param

Volker Lendecke Volker.Lendecke at SerNet.DE
Wed Dec 12 16:08:55 UTC 2018


On Wed, Dec 12, 2018 at 03:49:46PM +0000, Noel Power via samba-technical wrote:
> the default make builds and installs python3 products, the import statement
> if failing because you are running ./bin/samba-tool (which by default on
> your system is running with python2 because of the shebang)
> 
> if you run python3 ./bin/samba-tool  it will work
> 
> So, why haven't we changed the shebang to python3, there is currently some
> discussion ongoing about that. It's not as clear cut as you think. In
> general though scripts that are deliberately written to run with python2 &
> python3 can have python in the shebang line. You need to be aware what
> /usr/bin/python (or wherever it is located) is pointing at, in a system that
> has python2 and python3 it might be /usr/bin/python could be a link to
> either (and certainly in some newer enterprise focused distros I will bet
> soon python -> python3), additionally you need to be aware of what your
> build targets python2 or python3

The python community really was smoking weird stuff when designing a
completely new and incompatible language, naming it the same as the
one before.

We must force the user to choose either python2 or python3 at build
time and not even pretend to do anything else. If the default "python"
is python2, just don't do any attempt to even use or build for
python3. If "python" runs python3, do the reverse. No mix up. At all.

We should make a blocker bug for 4.10. We can't ship with this mess.

Volker

-- 
Besuchen Sie die verinice.XP 2019 in Berlin!
Anwenderkonferenz für Informationssicherheit
26.-28. Februar 2019 - im Hotel Radisson Blu
Info & Anmeldung hier: http://veriniceXP.org

SerNet GmbH, Bahnhofsallee 1b, 37081 Göttingen
phone: +49-551-370000-0, fax: +49-551-370000-9
AG Göttingen, HRB 2816, GF: Dr. Johannes Loxen
http://www.sernet.de, mailto:kontakt at sernet.de



More information about the samba-technical mailing list