[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Please help with creating pure Python 3 package (Was: Bug#848479: openmolar: Should Suggest the metapackage default-mysql-*)



On Sun, Dec 18, 2016 at 05:03:10PM +0100, Alberto Caso wrote:
> On Sat, 2016-12-17 at 21:14 +0100, Andreas Tille wrote:
> > Unfortunately I have severe trouble to stop the build system from
> > always trying pyversions instead of py3versions.  For instance I
> > injected
> > 
> > override_dh_auto_build:
> > 	# No idea why this would call
> > 	#           python setup.py build --force
> > 	# without this override
> > 	python3 setup.py build --force
> > 
> > into d/rules - otherwise I get:
> > 
> >    dh_auto_build
> > Can't exec "pyversions": No such file or directory at
> > /usr/share/perl5/Debian/Debhelper/Buildsystem/python_distutils.pm
> > line 121.
> > dh_auto_build: failed to run pyversions
> 
> 
> I could not reproduce the behavior you describe. Maybe your environment
> is messed?

I created a fresh

    sudo cowbuilder --create

and the issue remains. :-(
 
> Here is what I get after removing your overrides (for full log see the
> attached file):
> 
> [...]
> dh_auto_build -O--buildsystem=pybuild
> I: pybuild base:184: /usr/bin/python3 setup.py build
> running build
> running build_py
> creating /tmp/molar/openmolar/.pybuild/pythonX.Y_3.5/build/openmolar
> [...]
> 
> That's inside a debootstrapped sid chroot with only the package build
> dependencies installed (no pyversions and no Python < 3 components
> installed),

Hmmm, that's really strange.

> but I get the same results in my Stretch machine with both
> Python 3 and Python 2 installed (and both pyversions and py3versions
> commands available).
> 
> The build does fail in the tests phase, but I does not look related to
> what you are experiencing. Instead it seems to need running setup.py
> makeuis in the build process.
> ...
> ======================================================================
> ERROR: openmolar.qt4gui (unittest.loader._FailedTest)
> ----------------------------------------------------------------------
> ImportError: Failed to import test module: openmolar.qt4gui
> Traceback (most recent call last):
>   File "/tmp/molar/openmolar/.pybuild/pythonX.Y_3.5/build/openmolar/qt4gui/__init__.py", line 30, in <module>
>     from openmolar.qt4gui import resources_rc
> ImportError: cannot import name 'resources_rc'
> 
> During handling of the above exception, another exception occurred:
> 
> Traceback (most recent call last):
>   File "/usr/lib/python3.5/unittest/loader.py", line 462, in _find_test_path
>     package = self._get_module_from_name(name)
>   File "/usr/lib/python3.5/unittest/loader.py", line 369, in _get_module_from_name
>     __import__(name)
>   File "/tmp/molar/openmolar/.pybuild/pythonX.Y_3.5/build/openmolar/qt4gui/__init__.py", line 34, in <module>
>     sys.exit("openmolar is not properly built")
> SystemExit: openmolar is not properly built
> 
> 
> ----------------------------------------------------------------------
> Ran 1 test in 0.000s
> 
> FAILED (errors=1)
> E: pybuild pybuild:276: test: plugin distutils failed with: exit code=1: cd /tmp/molar/openmolar/.pybuild/pythonX.Y_3.5/build; python3.5 -m unittest discover -v 

I confirm that when using my crude overrides I get the same issue - but
my plan was to takle the stupid nuisance first.  I guess this is
something that will not make it into Stretch - several more important
stuff is on my desk for the moment ...

Thanks for checking anyway

       Andreas.

-- 
http://fam-tille.de


Reply to: