Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.maint.python > #12665

Re: Issues with packaging intake

Path csiph.com!aioe.org!bofh.it!news.nic.it!robomod
From Shayan Doust <hello@shayandoust.me>
Newsgroups linux.debian.maint.python
Subject Re: Issues with packaging intake
Date Fri, 19 Jun 2020 21:50:02 +0200
Message-ID <Ajvbs-6Pb-3@gated-at.bofh.it> (permalink)
References <Aj8RA-1I7-7@gated-at.bofh.it> <AjagF-2GN-5@gated-at.bofh.it>
X-Original-To Scott Talbert <swt@techie.net>
X-Mailbox-Line From debian-python-request@lists.debian.org Fri Jun 19 19:47:33 2020
Old-Return-Path <hello@shayandoust.me>
X-Amavis-Spam-Status No, score=-9.9 tagged_above=-10000 required=5.3 tests=[BAYES_00=-2, FOURLA=0.1, LDO_WHITELIST=-5, MEDS2=2, PGPSIGNATURE=-5, RCVD_IN_DNSWL_NONE=-0.0001] autolearn=ham autolearn_force=no
X-Policyd-Weight using cached result; rate: -5.5
Autocrypt addr=hello@shayandoust.me; keydata= mQINBF1v4u4BEADISlcZDW9MHwXL9l8FvoTn48rEmQLhvHhGlMvqmH65yZvpXiutFyvwABWp U6nAH4KxKtIOWEct6OWKgkRcHK2GSs70jPvVKVb1RTg19Umdv9XfikMmo71DzdA9PDXmnAbP jj2qZCQNj6WSWQe+8Je6vxUHcUPpI/SboLTxqCCYj6UM+qgZJSdJXROJens2Rr+MieyoFzMk I1YpeaZFRorN5D0xu+3DWB8tnfmlux1cPuyhjwXFRG5OLEJ4vxeVL2L2dsbUHrxsxg+Oxg3T ghUYdGyKU0qxGcIBzNk9v/eKuYRqW+GcN3pzdera6uwruZ+Ej06B7ifJ8+k6Gk/ed04cGXhx M+ILlcDdhcgFcpLoLO/+P67aqxrx/DQTCyObnKmip1+9lQYrubUhK74cnDmXPqpR8XYePASg LU3SNKPAeGQeEL9Ang9ZTnMF0p80WjZUXzTml8449tPW3+aCHA+5fxmAQD64ZzUBkgLi2jdz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.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0
MIME-Version 1.0
Content-Type multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="8SILpxYyAfLjbaG434v55YsOJm4h4aXFj"
X-Mailing-List <debian-python@lists.debian.org> archive/latest/18377
List-ID <debian-python.lists.debian.org>
List-URL <https://lists.debian.org/debian-python/>
List-Archive https://lists.debian.org/msgid-search/944847d9-5c28-d948-27d9-5df023202272@shayandoust.me
Approved robomod@news.nic.it
Lines 217
Organization linux.* mail to news gateway
Sender robomod@news.nic.it
X-Original-Cc debian-python@lists.debian.org
X-Original-Date Fri, 19 Jun 2020 20:46:35 +0100
X-Original-Message-ID <944847d9-5c28-d948-27d9-5df023202272@shayandoust.me>
X-Original-References <276c662e-c9e0-5620-9945-35b717c6b24d@shayandoust.me> <alpine.DEB.2.21.2006181703140.11296@bear.techie.net>
Xref csiph.com linux.debian.maint.python:12665

Show key headers only | View raw


[Multipart message — attachments visible in raw view] - view raw

Hello Scott,

Many thanks for your prompt response.

> Yes, this is unfortunately a common packaging problem due to the test
> target running before the install target which causes problems for a lot
> of Python packages that do additional work during the install step.

Ah right. Thanks for the information (for future packaging too).

> Anyway, you can fix most of the failures by creating a
> debian/pybuild.testfiles file that contains:
> intake.egg-info

I can confirm that this has indeed fixed most of the tests.

> For the console scripts, I don't have any good ideas other than
> overriding dh_auto_test and dh_auto_install (so that you run
> dh_auto_test *after* dh_auto_install).  But you will probably have to
> set PATH and PYTHONPATH to include the install directories so that the
> console scripts and Python modules can be found.

There were only a few non-critical tests that failed, however I managed
to fix some of them. With around 300 (if I remember correctly) tests
passing, there's enough coverage and I will simply query with upstream
later for the couple of minor tests that failed.

Thanks again & Kind regards,
Shayan Doust

On 18/06/2020 22:24, Scott Talbert wrote:
> On Thu, 18 Jun 2020, Shayan Doust wrote:
> 
>> I have been having some issues with packaging intake[1] for the Debian
>> Med packaging team, specifically during pytest. There are a lot of tests
>> failing, so I contacted upstream for a solution.
>>
>> According to upstream, the "entrypoints in the setup script are not
>> being registered when using python3 setup.py build", so I decided to do
>> some experimentation. It seems like the entry_points do actually get
>> registered and installed, so I experimentally overrode dh_auto_test and
>> only triggered dh_auto_test after dh_install (which is also overridden).
>> Unfortunately, this has not made any difference and a good hundred unit
>> tests fail.
>>
>> I am new to Python packaging, especially one that features entry points.
>> If anyone could please kindly look into the package (and possibly even
>> building it), this would be much appreciated.
>>
>> Kind regards,
>> Shayan Doust
>>
>> [1]: https://salsa.debian.org/med-team/intake
> 
> Yes, this is unfortunately a common packaging problem due to the test
> target running before the install target which causes problems for a lot
> of Python packages that do additional work during the install step.
> 
> Anyway, you can fix most of the failures by creating a
> debian/pybuild.testfiles file that contains:
> intake.egg-info
> 
> This causes the egg-info to be copied into the directory used for
> testing. This solves the errors related to plugins but not the ones
> related to console scripts, since the console script shims don't get
> created until 'install' runs.  :(
> 
> For the console scripts, I don't have any good ideas other than
> overriding dh_auto_test and dh_auto_install (so that you run
> dh_auto_test *after* dh_auto_install).  But you will probably have to
> set PATH and PYTHONPATH to include the install directories so that the
> console scripts and Python modules can be found.
> 
> Maybe someone else will have a better idea.
> 
> Scott

Back to linux.debian.maint.python | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

Issues with packaging intake Shayan Doust <hello@shayandoust.me> - 2020-06-18 22:00 +0200
  Re: Issues with packaging intake Scott Talbert <swt@techie.net> - 2020-06-18 23:30 +0200
    Re: Issues with packaging intake Shayan Doust <hello@shayandoust.me> - 2020-06-19 21:50 +0200

csiph-web