Re: The python command in Debian

2021-03-02 Thread Matthias Klose
I am appending the following two sections to the python policy chapter 2,
documenting what currently is in testing.  There are different opinions, no
perfect solutions, and if we disagree, we should delegate the final decision
whether to include or to not include the binary packages
python{,-dev}-is-python3 built from the what-is-python source to the CTTE.

Matthias

+Removal of the unversioned packages
+---
+
+Starting with the Debian 11 release (bullseye), the binary packages
+``python``, ``python-minimal``, ``python-dev``, ``python-dbg`` and
+``python-doc`` are removed.  No package in the archive must use any of
+these packages as build dependencies, dependencies, recommendations or
+suggestions.
+
+
+Unversioned python commands
+---
+
+For the Debian 11 release (bullseye), the :file:`/usr/bin/python`
+command is provided in the ``python-is-python2`` package (pointing to
+:file:`/usr/bin/python2`).  The :file:`/usr/bin/python-config` and
+:file:`/usr/bin/pydoc` commands are provided in the
+``python-dev-is-python2`` package.  These package are not installed by
+default for new installations, but only for upgrades from the Debian
+10 release (buster).  These packages should be removed after an
+upgrade.  These packages will not be part of the Debian 12 release
+(bookworm).
+
+The packages ``python-is-python3`` and ``python-dev-is-python3``
+provide the :file:`/usr/bin/python`, :file:`/usr/bin/python-config`
+and :file:`/usr/bin/pydoc` commands pointing to Python3.  These
+packages can be installed by developers and users to use the
+unversioned commands.  NOTE: Locally installed software not yet ported
+to Python3 is likely to break when installing these packages.
+
+The packages ``python-is-python3``, ``python-dev-is-python3``,
+``python-is-python2`` and ``python-dev-is-python2`` must not be used
+as build dependencies, dependencies, recommendations or suggestions.



Joining DPT

2021-03-02 Thread Philippe Coval


Dear Python team

I'd like to join the team to work on TUF package:

* Package name: python-tuf
  Upstream Author : tuf developers 
* URL : https://github.com/theupdateframework/tuf
* License : Apache-2.0

It has been requested by upstream year ago, but never landed

* https://bugs.debian.org/931178# RFS (2019)
* https://bugs.debian.org/934151# ITP (2019)

So I suggested upstream about cooperative maintenance through DPT,
and was then encouraged to help:

* https://github.com/theupdateframework/tuf/issues/263#issuecomment-781029348

I am motivated to do the initial work
because I know the procedures as one debian maintainers:
* https://qa.debian.org/developer.php?login=r...@users.sf.net

Also as requested I acknowlege team policy:

https://salsa.debian.org/python-team/tools/python-modules/blob/master/policy.rst

I planned to use GBP anyway along salsa, BTW here is my id:

https://salsa.debian.org/rzr

Meanwhile I will update activities regarding this packaging effort
on upstream tracker and crosslink to DBTS.

https://github.com/theupdateframework/tuf/issues/263

If needed feel free to ping me rzr in IRC

Regards
-- 
http://rzr.online.fr/# gpg:0x467094BC mailto:r...@users.sf.net



Bug#983870: ITP: webdriver-manager - Webdriver Manager for Python

2021-03-02 Thread Joost van Baal-Ilić
Package: wnpp
Severity: wishlist

* Package name: webdriver-manager
  Upstream Author : Sergey Pirogov
* URL : https://pypi.org/project/webdriver-manager/
* License : Apache-2.0
  Programming Lang: Python
  Description : Webdriver Manager for Python

Binary package names: python3-webdriver-manager

 The Webdriver Manager for Python simplifies management of binary drivers
 for different browsers.  It supports ChromeDriver, GeckoDriver,
 IEDriver, OperaDriver and EdgeChromiumDriver.  It is used by calling
 "from selenium import webdriver" from your Python code.

I'm planning to work on the webdriver-manager packaging using
python-team's git at Salsa, at
https://salsa.debian.org/python-team/packages/webdriver-manager .

Bye,

Joost

-- 
Joost van Baal-Ilić   http://abramowitz.uvt.nl/
 Tilburg University
mailto:joostvb.uvt.nl   The Netherlands


signature.asc
Description: PGP signature


Need a Python 3.8 virtual environment

2021-03-02 Thread Steven Robbins
Hi,

I'm trying to use a (non-Debian) python system built on python 3.8.  Debian's 
default is currently 3.9 so I am advised to use a virtual environment.   Being 
a newbie, I searched around and found a writeup covering several different 
virtualization tools [1].   Note I am using Debian 'sid'.

I can use the tool "virtualenv" to create a virtual environment for default 
python:

steve@riemann:/tmp$ virtualenv blah
created virtual environment CPython3.9.1.final.0-64 in 77ms
  creator CPython3Posix(dest=/tmp/blah, clear=False, no_vcs_ignore=False, 
global=False)
  seeder FromAppData(download=False, pip=bundle, setuptools=bundle, 
wheel=bundle, via=copy, app_data_dir=/home/steve/.local/share/virtualenv)
added seed packages: pip==20.1.1, pkg_resources==0.0.0, 
setuptools==44.0.0, wheel==0.34.2
  activators 
BashActivator,CShellActivator,FishActivator,PowerShellActivator,PythonActivator,XonshActivator


But not for python 3.8:

steve@riemann:/tmp$ virtualenv -p python3.8 blah38
RuntimeError: failed to find interpreter for Builtin discover of 
python_spec='python3.8'


I have installed literally all the Debian python packages whose name contains 
'python3.8'.   A very short list:

ii  libpython3.8:amd643.8.7-1   
  
amd64Shared Python runtime library (version 3.8)
ii  libpython3.8-dev:amd643.8.7-1   
  
amd64Header files and a static library for Python (v3.8)
ii  libpython3.8-minimal:amd643.8.7-1   
  
amd64Minimal subset of the Python language (version 3.8)
ii  libpython3.8-stdlib:amd64 3.8.7-1   
  
amd64Interactive high-level object-oriented language (standard 
library, version 3.8)
ii  python3.8 3.8.7-1   
  
amd64Interactive high-level object-oriented language (version 3.8)
ii  python3.8-dev 3.8.7-1   
  
amd64Header files and a static library for Python (v3.8)
ii  python3.8-minimal   



I have also tried the module 'venv':

steve@riemann:/tmp$ python3.8 -m venv v38
The virtual environment was not created successfully because ensurepip is not
available.  On Debian/Ubuntu systems, you need to install the python3-venv
package using the following command.

apt-get install python3-venv

You may need to use sudo with that command.  After installing the python3-venv
package, recreate your virtual environment.

Failing command: ['/tmp/v38/bin/python3.8', '-Im', 'ensurepip', '--upgrade', 
'--default-pip']

steve@riemann:/tmp$ python3.8 -m venv blah38
The virtual environment was not created successfully because ensurepip is not
available.  On Debian/Ubuntu systems, you need to install the python3-venv
package using the following command.

apt-get install python3-venv

You may need to use sudo with that command.  After installing the python3-venv
package, recreate your virtual environment.

Failing command: ['/tmp/blah38/bin/python3.8', '-Im', 'ensurepip', '--
upgrade', '--default-pip']


Note that I do have 'python3-venv' installed, but it is the 3.9 version:
ii  python3-venv  3.9.1-1   
  
amd64pyvenv-3 binary for python3 (default python3 version)


Is there something I've missed?  

Thank you,
-Steve

[1] 
https://linuxconfig.org/how-to-set-up-a-python-virtual-environment-on-debian-10-buster


signature.asc
Description: This is a digitally signed message part.


Re: Need a Python 3.8 virtual environment

2021-03-02 Thread Jerome Kieffer
On Tue, 02 Mar 2021 21:17:36 -0600
Steven Robbins  wrote:

> Hi,
> 
> I'm trying to use a (non-Debian) python system built on python 3.8.  Debian's 
> default is currently 3.9 so I am advised to use a virtual environment.   
> Being 
> a newbie, I searched around and found a writeup covering several different 
> virtualization tools [1].   Note I am using Debian 'sid'.
[...]
> Is there something I've missed?  


Hi Steven,

I don't think there is any simple solution for you within the debian ecosystem.
As a developper, I faced the same issue and ended in installing `conda` to
have a quick access to the various python versions (then I create
some venv from the conda environments).

I doubt our use-case is common enough to justify having multiple python (again) 
in Debian.

Cheers,

Jerome

PS: venv are about 10x smaller than conda environments !



Re: Need a Python 3.8 virtual environment

2021-03-02 Thread Andrey Rahmatullin
It looks like the only sane way to use non-default Python versions is to
build them locally using pyenv. 

-- 
WBR, wRAR


signature.asc
Description: PGP signature


Re: Need a Python 3.8 virtual environment

2021-03-02 Thread Pokoradi Balazs

Hi Steven,

i tested in a freshly installed virtualbox machine and was able to 
create a virtual environment, using the following steps:


built python3.8.7 form tarball 
(|https://www.python.org/ftp/python/3.8.7/Python-3.8.7.tar.xz)|


ran python3.8 -m venv test387

and then could activate it.

I hope this helps,

Balazs

On 03/03/2021 03:17, Steven Robbins wrote:

Hi,

I'm trying to use a (non-Debian) python system built on python 3.8.  Debian's
default is currently 3.9 so I am advised to use a virtual environment.   Being
a newbie, I searched around and found a writeup covering several different
virtualization tools [1].   Note I am using Debian 'sid'.

I can use the tool "virtualenv" to create a virtual environment for default
python:

steve@riemann:/tmp$ virtualenv blah
created virtual environment CPython3.9.1.final.0-64 in 77ms
   creator CPython3Posix(dest=/tmp/blah, clear=False, no_vcs_ignore=False,
global=False)
   seeder FromAppData(download=False, pip=bundle, setuptools=bundle,
wheel=bundle, via=copy, app_data_dir=/home/steve/.local/share/virtualenv)
 added seed packages: pip==20.1.1, pkg_resources==0.0.0,
setuptools==44.0.0, wheel==0.34.2
   activators
BashActivator,CShellActivator,FishActivator,PowerShellActivator,PythonActivator,XonshActivator


But not for python 3.8:

steve@riemann:/tmp$ virtualenv -p python3.8 blah38
RuntimeError: failed to find interpreter for Builtin discover of
python_spec='python3.8'


I have installed literally all the Debian python packages whose name contains
'python3.8'.   A very short list:

ii  libpython3.8:amd643.8.7-1
amd64Shared Python runtime library (version 3.8)
ii  libpython3.8-dev:amd643.8.7-1
amd64Header files and a static library for Python (v3.8)
ii  libpython3.8-minimal:amd643.8.7-1
amd64Minimal subset of the Python language (version 3.8)
ii  libpython3.8-stdlib:amd64 3.8.7-1
amd64Interactive high-level object-oriented language (standard
library, version 3.8)
ii  python3.8 3.8.7-1
amd64Interactive high-level object-oriented language (version 3.8)
ii  python3.8-dev 3.8.7-1
amd64Header files and a static library for Python (v3.8)
ii  python3.8-minimal



I have also tried the module 'venv':

steve@riemann:/tmp$ python3.8 -m venv v38
The virtual environment was not created successfully because ensurepip is not
available.  On Debian/Ubuntu systems, you need to install the python3-venv
package using the following command.

 apt-get install python3-venv

You may need to use sudo with that command.  After installing the python3-venv
package, recreate your virtual environment.

Failing command: ['/tmp/v38/bin/python3.8', '-Im', 'ensurepip', '--upgrade',
'--default-pip']

steve@riemann:/tmp$ python3.8 -m venv blah38
The virtual environment was not created successfully because ensurepip is not
available.  On Debian/Ubuntu systems, you need to install the python3-venv
package using the following command.

 apt-get install python3-venv

You may need to use sudo with that command.  After installing the python3-venv
package, recreate your virtual environment.

Failing command: ['/tmp/blah38/bin/python3.8', '-Im', 'ensurepip', '--
upgrade', '--default-pip']


Note that I do have 'python3-venv' installed, but it is the 3.9 version:
ii  python3-venv  3.9.1-1
amd64pyvenv-3 binary for python3 (default python3 version)


Is there something I've missed?

Thank you,
-Steve

[1] 
https://linuxconfig.org/how-to-set-up-a-python-virtual-environment-on-debian-10-buster