• Bug#1091506: ITP: python-unshare -- extension for C unshare() call

    From Simon Josefsson@21:1/5 to Helmut Grohne on Thu Jan 2 10:10:02 2025
    tag 1091506 wontfix
    thanks

    Helmut Grohne <helmut@subdivi.de> writes:

    In any case, I stand by my recommendation of not uploading a module of
    such dubious value to Debian

    I agree with that, so tagging this ITP bug appropriately pending other
    input or ideas in the future.

    I can't speak of alternatives, but I've realized that python-unshare
    isn't a showstopper for PQconnect since python-netfilterqueue has been
    made to work without python-unshare now.

    /Simon

    -----BEGIN PGP SIGNATURE-----

    iIoEARYIADIWIQSjzJyHC50xCrrUzy9RcisI/kdFogUCZ3ZU/RQcc2ltb25Aam9z ZWZzc29uLm9yZwAKCRBRcisI/kdFoh3UAQC0bReBTPejWQ3Yq1Pdqw5K92NUfE5h WCYa5c1u/y5nCQD+OizKrLH/ALwX/KvVjDdx8lSnhhfxTujbZJTfJB5Yswc=
    =mydl
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Simon Josefsson@21:1/5 to All on Fri Dec 27 20:30:01 2024
    XPost: linux.debian.devel, linux.debian.maint.python

    Package: wnpp
    Severity: wishlist
    Owner: Simon Josefsson <simon@josefsson.org>
    X-Debbugs-Cc: debian-devel@lists.debian.org, debian-python@lists.debian.org

    * Package name : python-unshare
    Version : 0.22
    Upstream Author : Shubham Sharma <shubhamsharma1172@gmail.com>
    * URL : https://github.com/shubham1172/unshare
    * License : GPL-3
    Programming Lang: Python
    Description : extension for C unshare() call

    Python extension for C's unshare call, see unshare(2).

    https://salsa.debian.org/python-team/packages/python-unshare/

    /Simon

    -----BEGIN PGP SIGNATURE-----

    iIoEARYIADIWIQSjzJyHC50xCrrUzy9RcisI/kdFogUCZ27+7BQcc2ltb25Aam9z ZWZzc29uLm9yZwAKCRBRcisI/kdFooRVAP47dBKLPFYZ2scIRUp+HSePYMBl8EA+ HFaojOqrVUAA9QD9Hm7+fQXZgB22J24q35MbThMETNJL8qpCI/GvErZz2Q0=
    =bbck
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Helmut Grohne@21:1/5 to Simon Josefsson on Sat Dec 28 08:10:02 2024
    Control: tags -1 + moreinfo

    Hi Simon,

    On Fri, Dec 27, 2024 at 08:24:28PM +0100, Simon Josefsson wrote:
    Package: wnpp
    Severity: wishlist
    Owner: Simon Josefsson <simon@josefsson.org>
    X-Debbugs-Cc: debian-devel@lists.debian.org, debian-python@lists.debian.org

    * Package name : python-unshare
    Version : 0.22
    Upstream Author : Shubham Sharma <shubhamsharma1172@gmail.com>
    * URL : https://github.com/shubham1172/unshare
    * License : GPL-3
    Programming Lang: Python
    Description : extension for C unshare() call

    Python extension for C's unshare call, see unshare(2).

    https://salsa.debian.org/python-team/packages/python-unshare/

    I recommend not adding this to Debian. This Python extension wraps a
    single syscall. You can achieve a similar effect using ctypes.

    import ctypes
    unshare = ctypes.CDLL(None, use_errno=True)["unshare"]
    unshare(flags)

    The functionality being added here is useful, but in my opinion it does
    not reach the bar of being sufficiently useful to warrant the cost of
    carrying it in Debian yet. Bear in mind that every package being added
    bears a permanent cost to Debian.

    Please allow me to suggest an alternative. https://git.subdivi.de/~helmut/python-linuxnamespaces.git/
    Disclaimer: I am the author of the alternative.

    I did not dare to propose adding this to Debian yet, because I consider
    it work in progress, but even at this time, it does so much more than
    the module you propose that it probably is worth looking into. It is not
    API compatible, because it uses the enum module instead of numeric
    constants. It also includes a pile of examples for more elaborate
    container construction.

    Helmut

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Simon Josefsson@21:1/5 to All on Sat Dec 28 10:40:01 2024
    --Apple-Mail-09AFA489-2702-47F4-8843-9EAE41B7DA12
    Content-Type: text/plain;
    charset=utf-8
    Content-Transfer-Encoding: quoted-printable

    Thank you - I agree and hope to convince upstream PQconnect to pick build dependencies in a better way. This was a bit further down the dependency stack, but hopefully they can help anyway. They brought up a valid concern: prefer not to depend on things
    not on PyPI and I agree (of course, within reason). It seems unshare is there: https://pypi.org/project/unshare/

    /Simon

    28 dec. 2024 kl. 08:08 skrev Helmut Grohne <helmut@subdivi.de>:

    Control: tags -1 + moreinfo

    Hi Simon,

    On Fri, Dec 27, 2024 at 08:24:28PM +0100, Simon Josefsson wrote:
    Package: wnpp
    Severity: wishlist
    Owner: Simon Josefsson <simon@josefsson.org>
    X-Debbugs-Cc: debian-devel@lists.debian.org, debian-python@lists.debian.org >>
    * Package name : python-unshare
    Version : 0.22
    Upstream Author : Shubham Sharma <shubhamsharma1172@gmail.com>
    * URL : https://github.com/shubham1172/unshare
    * License : GPL-3
    Programming Lang: Python
    Description : extension for C unshare() call

    Python extension for C's unshare call, see unshare(2).

    https://salsa.debian.org/python-team/packages/python-unshare/

    I recommend not adding this to Debian. This Python extension wraps a
    single syscall. You can achieve a similar effect using ctypes.

    import ctypes
    unshare = ctypes.CDLL(None, use_errno=True)["unshare"]
    unshare(flags)

    The functionality being added here is useful, but in my opinion it does
    not reach the bar of being sufficiently useful to warrant the cost of carrying it in Debian yet. Bear in mind that every package being added
    bears a permanent cost to Debian.

    Please allow me to suggest an alternative. https://git.subdivi.de/~helmut/python-linuxnamespaces.git/
    Disclaimer: I am the author of the alternative.

    I did not dare to propose adding this to Debian yet, because I consider
    it work in progress, but even at this time, it does so much more than
    the module you propose that it probably is worth looking into. It is not
    API compatible, because it uses the enum module instead of numeric
    constants. It also includes a pile of examples for more elaborate
    container construction.

    Helmut


    --Apple-Mail-09AFA489-2702-47F4-8843-9EAE41B7DA12
    Content-Type: text/html;
    charset=utf-8
    Content-Transfer-Encoding: quoted-printable

    <html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto">Thank you - I agree and hope to convince upstream PQconnect to pick build dependencies in a better way. This was a bit further down the dependency
    stack, but hopefully they can help anyway. They brought up a valid concern: prefer not to depend on things not on PyPI and I agree (of course, within reason). &nbsp;It seems unshare is there:&nbsp;<a href="https://pypi.org/project/unshare/">https://pypi.
    org/project/unshare/</a><div><div><br id="lineBreakAtBeginningOfSignature"><div dir="ltr">/Simon</div><div dir="ltr"><br><blockquote type="cite">28 dec. 2024 kl. 08:08 skrev Helmut Grohne &lt;helmut@subdivi.de&gt;:<br><br></blockquote></div><blockquote
    type="cite"><div dir="ltr"><span>Control: tags -1 + moreinfo</span><br><span></span><br><span>Hi Simon,</span><br><span></span><br><span>On Fri, Dec 27, 2024 at 08:24:28PM +0100, Simon Josefsson wrote:</span><br><blockquote type="cite"><span>Package:
    wnpp</span><br></blockquote><blockquote type="cite"><span>Severity: wishlist</span><br></blockquote><blockquote type="cite"><span>Owner: Simon Josefsson &lt;simon@josefsson.org&gt;</span><br></blockquote><blockquote type="cite"><span>X-Debbugs-Cc: debian-
    devel@lists.debian.org, debian-python@lists.debian.org</span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>* Package name &nbsp;&nbsp;&nbsp;: python-unshare</span><br></blockquote><blockquote type="
    cite"><span> &nbsp;Version &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;: 0.22</span><br></blockquote><blockquote type="cite"><span> &nbsp;Upstream Author : Shubham Sharma &lt;shubhamsharma1172@gmail.com&gt;</span><br></blockquote><blockquote type="
    cite"><span>* URL &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;: https://github.com/shubham1172/unshare</span><br></blockquote><blockquote type="cite"><span>* License &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;: GPL-3</
    span><br></blockquote><blockquote type="cite"><span> &nbsp;Programming Lang: Python</span><br></blockquote><blockquote type="cite"><span> &nbsp;Description &nbsp;&nbsp;&nbsp;&nbsp;: extension for C unshare() call</span><br></blockquote><blockquote type="
    cite"><span></span><br></blockquote><blockquote type="cite"><span> Python extension for C's unshare call, see unshare(2).</span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>https://salsa.debian.org/
    python-team/packages/python-unshare/</span><br></blockquote><span></span><br><span>I recommend not adding this to Debian. This Python extension wraps a</span><br><span>single syscall. You can achieve a similar effect using ctypes.</span><br><span></span><
    <span> &nbsp;&nbsp;&nbsp;import ctypes</span><br><span> &nbsp;&nbsp;&nbsp;unshare = ctypes.CDLL(None, use_errno=True)["unshare"]</span><br><span> &nbsp;&nbsp;&nbsp;unshare(flags)</span><br><span></span><br><span>The functionality being added here is
    useful, but in my opinion it does</span><br><span>not reach the bar of being sufficiently useful to warrant the cost of</span><br><span>carrying it in Debian yet. Bear in mind that every package being added</span><br><span>bears a permanent cost to
    Debian.</span><br><span></span><br><span>Please allow me to suggest an alternative.</span><br><span>https://git.subdivi.de/~helmut/python-linuxnamespaces.git/</span><br><span>Disclaimer: I am the author of the alternative.</span><br><span></span><br><
    span>I did not dare to propose adding this to Debian yet, because I consider</span><br><span>it work in progress, but even at this time, it does so much more than</span><br><span>the module you propose that it probably is worth looking into. It is not</
    span><br><span>API compatible, because it uses the enum module instead of numeric</span><br><span>constants. It also includes a pile of examples for more elaborate</span><br><span>container construction.</span><br><span></span><br><span>Helmut</span><br><
    span></span><br></div></blockquote></div></div></body></html> --Apple-Mail-09AFA489-2702-47F4-8843-9EAE41B7DA12--

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Simon Josefsson@21:1/5 to Simon Josefsson on Sat Dec 28 11:10:01 2024
    XPost: linux.debian.maint.python

    I have patched out use of python-unshare from python-netfilterqueue, it
    was only used during self-tests but those did not work anyway.

    https://salsa.debian.org/python-team/packages/python-netfilterqueue/-/commit/22a94f3ba90112ea8aa474ba2523f6c81ca1d333
    https://salsa.debian.org/python-team/packages/python-netfilterqueue/-/pipelines/787900

    I opened an upstream bug report to ask them to consider another
    approach:

    https://github.com/oremanj/python-netfilterqueue/issues/15#issuecomment-2564282968

    It seems their code is here:

    https://github.com/oremanj/python-netfilterqueue/blob/master/tests/test_basic.py
    https://github.com/oremanj/python-netfilterqueue/blob/master/tests/conftest.py

    If you (or anyone on debian-python that I'm cc'ing now) can propose a
    patch for upstream, maybe that will convince them to avoid the
    python-unshare dependency and we'll have better self-tests as a result.

    Note that there appears to be two python-unshare: one on PyPI and
    another one here: https://github.com/NightTsarina/python-unshare/

    /Simon

    Simon Josefsson <simon@josefsson.org> writes:

    Thank you - I agree and hope to convince upstream PQconnect to pick
    build dependencies in a better way. This was a bit further down the dependency stack, but hopefully they can help anyway. They brought up
    a valid concern: prefer not to depend on things not on PyPI and I
    agree (of course, within reason). It seems unshare is there: https://pypi.org/project/unshare/

    /Simon

    28 dec. 2024 kl. 08:08 skrev Helmut Grohne <helmut@subdivi.de>:

    Control: tags -1 + moreinfo

    Hi Simon,

    On Fri, Dec 27, 2024 at 08:24:28PM +0100, Simon Josefsson wrote:
    Package: wnpp
    Severity: wishlist
    Owner: Simon Josefsson <simon@josefsson.org>
    X-Debbugs-Cc: debian-devel@lists.debian.org, debian-python@lists.debian.org >>>
    * Package name : python-unshare
    Version : 0.22
    Upstream Author : Shubham Sharma <shubhamsharma1172@gmail.com>
    * URL : https://github.com/shubham1172/unshare
    * License : GPL-3
    Programming Lang: Python
    Description : extension for C unshare() call

    Python extension for C's unshare call, see unshare(2).

    https://salsa.debian.org/python-team/packages/python-unshare/

    I recommend not adding this to Debian. This Python extension wraps a
    single syscall. You can achieve a similar effect using ctypes.

    import ctypes
    unshare = ctypes.CDLL(None, use_errno=True)["unshare"]
    unshare(flags)

    The functionality being added here is useful, but in my opinion it does
    not reach the bar of being sufficiently useful to warrant the cost of
    carrying it in Debian yet. Bear in mind that every package being added
    bears a permanent cost to Debian.

    Please allow me to suggest an alternative.
    https://git.subdivi.de/~helmut/python-linuxnamespaces.git/
    Disclaimer: I am the author of the alternative.

    I did not dare to propose adding this to Debian yet, because I consider
    it work in progress, but even at this time, it does so much more than
    the module you propose that it probably is worth looking into. It is not
    API compatible, because it uses the enum module instead of numeric
    constants. It also includes a pile of examples for more elaborate
    container construction.

    Helmut


    --=-=-Content-Type: application/pgp-signature; name="signature.asc"

    -----BEGIN PGP SIGNATURE-----

    iIoEARYIADIWIQSjzJyHC50xCrrUzy9RcisI/kdFogUCZ2/MQBQcc2ltb25Aam9z ZWZzc29uLm9yZwAKCRBRcisI/kdFouRUAQDRFA8sJBu+M/00hZrtOWxfP0/mkq8H yNKxqrPx77vA7QD+NnuIoepW8wo/nqUkWVT0R7r305zbbrtowOZum3yCcAg=QfMK
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)