[Python-modules-team] Bug#991650: python-django-imagekit: FTBFS: dh_auto_test: error: pybuild --test -i python{version} -p 3.9 returned exit code 13
Lucas Nussbaum
lucas at debian.org
Thu Jul 29 16:16:01 BST 2021
Source: python-django-imagekit
Version: 4.0.2-3
Severity: serious
Justification: FTBFS on amd64
Tags: bullseye sid ftbfs
Usertags: ftbfs-20210728 ftbfs-bullseye
Hi,
During a rebuild of all packages in bullseye, your package failed to build
on amd64.
Relevant part (hopefully):
> make[1]: Entering directory '/<<PKGBUILDDIR>>'
> dh_auto_build
> I: pybuild base:232: /usr/bin/python3 setup.py build
> running build
> running build_py
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/registry.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/generatorlibrary.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/lib.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/pkgmeta.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/__init__.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/conf.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/hashers.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/compat.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/admin.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/exceptions.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/signals.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/utils.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> copying imagekit/files.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/forms
> copying imagekit/forms/fields.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/forms
> copying imagekit/forms/__init__.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/forms
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/models
> copying imagekit/models/__init__.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/models
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/processors
> copying imagekit/processors/resize.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/processors
> copying imagekit/processors/__init__.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/processors
> copying imagekit/processors/crop.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/processors
> copying imagekit/processors/base.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/processors
> copying imagekit/processors/utils.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/processors
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/specs
> copying imagekit/specs/__init__.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/specs
> copying imagekit/specs/sourcegroups.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/specs
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/templatetags
> copying imagekit/templatetags/__init__.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/templatetags
> copying imagekit/templatetags/imagekit.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/templatetags
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/cachefiles
> copying imagekit/cachefiles/backends.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/cachefiles
> copying imagekit/cachefiles/__init__.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/cachefiles
> copying imagekit/cachefiles/strategies.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/cachefiles
> copying imagekit/cachefiles/namers.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/cachefiles
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/management
> copying imagekit/management/__init__.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/management
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/models/fields
> copying imagekit/models/fields/__init__.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/models/fields
> copying imagekit/models/fields/utils.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/models/fields
> copying imagekit/models/fields/files.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/models/fields
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/management/commands
> copying imagekit/management/commands/__init__.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/management/commands
> copying imagekit/management/commands/generateimages.py -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/management/commands
> running egg_info
> creating django_imagekit.egg-info
> writing django_imagekit.egg-info/PKG-INFO
> writing dependency_links to django_imagekit.egg-info/dependency_links.txt
> writing requirements to django_imagekit.egg-info/requires.txt
> writing top-level names to django_imagekit.egg-info/top_level.txt
> writing manifest file 'django_imagekit.egg-info/SOURCES.txt'
> reading manifest file 'django_imagekit.egg-info/SOURCES.txt'
> reading manifest template 'MANIFEST.in'
> warning: no files found matching 'tests/assets/Lenna.png'
> warning: no files found matching 'tests/assets/lenna-*.jpg'
> warning: no files found matching 'tests/media/lenna.png'
> no previously-included directories found matching 'tests/media/CACHE'
> no previously-included directories found matching 'tests/media/b'
> no previously-included directories found matching 'tests/media/photos'
> writing manifest file 'django_imagekit.egg-info/SOURCES.txt'
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/templates
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/templates/imagekit
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/templates/imagekit/admin
> copying imagekit/templates/imagekit/admin/thumbnail.html -> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9_django-imagekit/build/imagekit/templates/imagekit/admin
> PYTHONPATH=. python3 -m sphinx -b html -d docs/.build/.doctrees -N docs docs/.build/html
> Running Sphinx v3.4.3
> making output directory... done
> building [mo]: targets for 0 po files that are out of date
> building [html]: targets for 6 source files that are out of date
> updating environment: [new config] 6 added, 0 changed, 0 removed
> reading sources... [ 16%] _themes/README
> reading sources... [ 33%] advanced_usage
> reading sources... [ 50%] caching
> reading sources... [ 66%] configuration
> reading sources... [ 83%] index
> reading sources... [100%] upgrading
>
> /<<PKGBUILDDIR>>/docs/caching.rst:6: WARNING: Title underline too short.
>
> Default Backend Workflow
> ================
> README.rst:1: WARNING: Undefined substitution referenced: "Build Status".
> looking for now-outdated files... none found
> pickling environment... done
> checking consistency... /<<PKGBUILDDIR>>/docs/_themes/README.rst: WARNING: document isn't included in any toctree
> done
> preparing documents... done
> writing output... [ 16%] _themes/README
> writing output... [ 33%] advanced_usage
> writing output... [ 50%] caching
> writing output... [ 66%] configuration
> writing output... [ 83%] index
> writing output... [100%] upgrading
>
> generating indices... genindex done
> writing additional pages... search done
> copying static files... done
> copying extra files... done
> dumping search index in English (code: en)... done
> dumping object inventory... done
> build succeeded, 3 warnings.
>
> The HTML pages are in docs/.build/html.
> make[1]: Leaving directory '/<<PKGBUILDDIR>>'
> dh_auto_test -O--buildsystem=pybuild
> I: pybuild base:232: python3.9 setup.py test
> running test
> WARNING: Testing via this command is deprecated and will be removed in a future version. Users looking for a generic test entry point independent of test runner are encouraged to use tox.
> running egg_info
> writing django_imagekit.egg-info/PKG-INFO
> writing dependency_links to django_imagekit.egg-info/dependency_links.txt
> writing requirements to django_imagekit.egg-info/requires.txt
> writing top-level names to django_imagekit.egg-info/top_level.txt
> reading manifest file 'django_imagekit.egg-info/SOURCES.txt'
> reading manifest template 'MANIFEST.in'
> warning: no files found matching 'tests/assets/Lenna.png'
> warning: no files found matching 'tests/assets/lenna-*.jpg'
> warning: no files found matching 'tests/media/lenna.png'
> no previously-included directories found matching 'tests/media/CACHE'
> no previously-included directories found matching 'tests/media/b'
> no previously-included directories found matching 'tests/media/photos'
> writing manifest file 'django_imagekit.egg-info/SOURCES.txt'
> running build_ext
> Creating test database for alias 'default'...
> ............./<<PKGBUILDDIR>>/tests/utils.py:67: GuessedAtParserWarning: No parser was explicitly specified, so I'm using the best available HTML parser for this system ("html.parser"). This usually isn't a problem, but if you run this code on another system, or in a different virtual environment, it may use a different parser and behave differently.
>
> The code that caused this warning is on line 67 of the file /<<PKGBUILDDIR>>/tests/utils.py. To get rid of this warning, pass the additional argument 'features="html.parser"' to the BeautifulSoup constructor.
>
> return BeautifulSoup(render_tag(ttag)).img.attrs
> ............E.E.........
> ======================================================================
> ERROR: Creating a new instance with an image causes the source_saved signal to be
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "/usr/lib/python3/dist-packages/nose/case.py", line 197, in runTest
> self.test(*self.arg)
> File "/<<PKGBUILDDIR>>/tests/test_sourcegroups.py", line 26, in test_source_saved_signal
> ImageModel.objects.create(image=File(get_image_file()))
> File "/usr/lib/python3/dist-packages/django/db/models/manager.py", line 82, in manager_method
> return getattr(self.get_queryset(), name)(*args, **kwargs)
> File "/usr/lib/python3/dist-packages/django/db/models/query.py", line 422, in create
> obj.save(force_insert=True, using=self.db)
> File "/usr/lib/python3/dist-packages/django/db/models/base.py", line 743, in save
> self.save_base(using=using, force_insert=force_insert,
> File "/usr/lib/python3/dist-packages/django/db/models/base.py", line 780, in save_base
> updated = self._save_table(
> File "/usr/lib/python3/dist-packages/django/db/models/base.py", line 873, in _save_table
> result = self._do_insert(cls._base_manager, using, fields, update_pk, raw)
> File "/usr/lib/python3/dist-packages/django/db/models/base.py", line 910, in _do_insert
> return manager._insert([self], fields=fields, return_id=update_pk,
> File "/usr/lib/python3/dist-packages/django/db/models/manager.py", line 82, in manager_method
> return getattr(self.get_queryset(), name)(*args, **kwargs)
> File "/usr/lib/python3/dist-packages/django/db/models/query.py", line 1186, in _insert
> return query.get_compiler(using=using).execute_sql(return_id)
> File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 1376, in execute_sql
> for sql, params in self.as_sql():
> File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 1318, in as_sql
> value_rows = [
> File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 1319, in <listcomp>
> [self.prepare_value(field, self.pre_save_val(field, obj)) for field in fields]
> File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 1319, in <listcomp>
> [self.prepare_value(field, self.pre_save_val(field, obj)) for field in fields]
> File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 1270, in pre_save_val
> return field.pre_save(obj, add=True)
> File "/usr/lib/python3/dist-packages/django/db/models/fields/files.py", line 289, in pre_save
> file.save(file.name, file.file, save=False)
> File "/usr/lib/python3/dist-packages/django/db/models/fields/files.py", line 87, in save
> name = self.field.generate_filename(self.instance, name)
> File "/usr/lib/python3/dist-packages/django/db/models/fields/files.py", line 308, in generate_filename
> filename = validate_file_name(filename, allow_relative_path=True)
> File "/usr/lib/python3/dist-packages/django/core/files/utils.py", line 18, in validate_file_name
> raise SuspiciousFileOperation(
> django.core.exceptions.SuspiciousFileOperation: Detected path traversal attempt in '/<<PKGBUILDDIR>>/tests/media/reference.png'
>
> ======================================================================
> ERROR: Source groups created for abstract models must cause signals to be
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "/usr/lib/python3/dist-packages/nose/case.py", line 197, in runTest
> self.test(*self.arg)
> File "/<<PKGBUILDDIR>>/tests/test_sourcegroups.py", line 54, in test_abstract_model_signals
> ConcreteImageModel.objects.create(original_image=File(get_image_file()))
> File "/usr/lib/python3/dist-packages/django/db/models/manager.py", line 82, in manager_method
> return getattr(self.get_queryset(), name)(*args, **kwargs)
> File "/usr/lib/python3/dist-packages/django/db/models/query.py", line 422, in create
> obj.save(force_insert=True, using=self.db)
> File "/usr/lib/python3/dist-packages/django/db/models/base.py", line 743, in save
> self.save_base(using=using, force_insert=force_insert,
> File "/usr/lib/python3/dist-packages/django/db/models/base.py", line 780, in save_base
> updated = self._save_table(
> File "/usr/lib/python3/dist-packages/django/db/models/base.py", line 873, in _save_table
> result = self._do_insert(cls._base_manager, using, fields, update_pk, raw)
> File "/usr/lib/python3/dist-packages/django/db/models/base.py", line 910, in _do_insert
> return manager._insert([self], fields=fields, return_id=update_pk,
> File "/usr/lib/python3/dist-packages/django/db/models/manager.py", line 82, in manager_method
> return getattr(self.get_queryset(), name)(*args, **kwargs)
> File "/usr/lib/python3/dist-packages/django/db/models/query.py", line 1186, in _insert
> return query.get_compiler(using=using).execute_sql(return_id)
> File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 1376, in execute_sql
> for sql, params in self.as_sql():
> File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 1318, in as_sql
> value_rows = [
> File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 1319, in <listcomp>
> [self.prepare_value(field, self.pre_save_val(field, obj)) for field in fields]
> File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 1319, in <listcomp>
> [self.prepare_value(field, self.pre_save_val(field, obj)) for field in fields]
> File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 1270, in pre_save_val
> return field.pre_save(obj, add=True)
> File "/usr/lib/python3/dist-packages/django/db/models/fields/files.py", line 289, in pre_save
> file.save(file.name, file.file, save=False)
> File "/usr/lib/python3/dist-packages/django/db/models/fields/files.py", line 87, in save
> name = self.field.generate_filename(self.instance, name)
> File "/usr/lib/python3/dist-packages/django/db/models/fields/files.py", line 308, in generate_filename
> filename = validate_file_name(filename, allow_relative_path=True)
> File "/usr/lib/python3/dist-packages/django/core/files/utils.py", line 18, in validate_file_name
> raise SuspiciousFileOperation(
> django.core.exceptions.SuspiciousFileOperation: Detected path traversal attempt in '/<<PKGBUILDDIR>>/tests/media/reference.png'
>
> ----------------------------------------------------------------------
> Ran 37 tests in 0.287s
>
> FAILED (errors=2)
> Destroying test database for alias 'default'...
> nosetests tests -s --cover-tests --cover-html --cover-package=imagekit --cover-html-dir=/<<PKGBUILDDIR>>/tests/cover --verbosity=1
> E: pybuild pybuild:353: test: plugin distutils failed with: exit code=2: python3.9 setup.py test
> dh_auto_test: error: pybuild --test -i python{version} -p 3.9 returned exit code 13
The full build log is available from:
http://qa-logs.debian.net/2021/07/28/python-django-imagekit_4.0.2-3_testing.log
A list of current common problems and possible solutions is available at
http://wiki.debian.org/qa.debian.org/FTBFS . You're welcome to contribute!
If you reassign this bug to another package, please marking it as 'affects'-ing
this package. See https://www.debian.org/Bugs/server-control#affects
If you fail to reproduce this, please provide a build log and diff it with mine
so that we can identify if something relevant changed in the meantime.
About the archive rebuild: The rebuild was done on EC2 VM instances from
Amazon Web Services, using a clean, minimal and up-to-date chroot. Every
failed build was retried once to eliminate random failures.
More information about the Python-modules-team
mailing list