Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 1581753 - python-django FTBFS on Python 3.7
Summary: python-django FTBFS on Python 3.7
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: python-django
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Matthias Runge
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: PYTHON37
TreeView+ depends on / blocked
 
Reported: 2018-05-23 14:52 UTC by Miro Hrončok
Modified: 2018-06-11 08:55 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-06-11 08:55:16 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
build.log from copr (2.95 MB, text/plain)
2018-06-04 12:07 UTC, Miro Hrončok
no flags Details

Description Miro Hrončok 2018-05-23 14:52:28 UTC
Django tests fails on Python 3.7:

======================================================================
ERROR: test_load_empty_dir (migrations.test_loader.LoaderTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/Django-2.0.5/tests/migrations/test_loader.py", line 173, in test_load_empty_dir
    loader = MigrationLoader(connection)
  File "/builddir/build/BUILD/Django-2.0.5/django/db/migrations/loader.py", line 49, in __init__
    self.build_graph()
  File "/builddir/build/BUILD/Django-2.0.5/django/db/migrations/loader.py", line 200, in build_graph
    self.load_disk()
  File "/builddir/build/BUILD/Django-2.0.5/django/db/migrations/loader.py", line 99, in load_disk
    directory = os.path.dirname(module.__file__)
  File "/usr/lib64/python3.7/posixpath.py", line 156, in dirname
    p = os.fspath(p)
TypeError: expected str, bytes or os.PathLike object, not NoneType
======================================================================
ERROR: test_makemigrations_no_init (migrations.test_commands.MakeMigrationsTests)
Migration directories without an __init__.py file are allowed.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/Django-2.0.5/tests/migrations/test_commands.py", line 860, in test_makemigrations_no_init
    call_command('makemigrations', stdout=out)
  File "/builddir/build/BUILD/Django-2.0.5/django/core/management/__init__.py", line 141, in call_command
    return command.execute(*args, **defaults)
  File "/builddir/build/BUILD/Django-2.0.5/django/core/management/base.py", line 335, in execute
    output = self.handle(*args, **options)
  File "/builddir/build/BUILD/Django-2.0.5/django/core/management/commands/makemigrations.py", line 78, in handle
    loader = MigrationLoader(None, ignore_no_migrations=True)
  File "/builddir/build/BUILD/Django-2.0.5/django/db/migrations/loader.py", line 49, in __init__
    self.build_graph()
  File "/builddir/build/BUILD/Django-2.0.5/django/db/migrations/loader.py", line 200, in build_graph
    self.load_disk()
  File "/builddir/build/BUILD/Django-2.0.5/django/db/migrations/loader.py", line 99, in load_disk
    directory = os.path.dirname(module.__file__)
  File "/usr/lib64/python3.7/posixpath.py", line 156, in dirname
    p = os.fspath(p)
TypeError: expected str, bytes or os.PathLike object, not NoneType
----------------------------------------------------------------------

Version-Release number of selected component: 2.0.5-1.fc29


This one is fixed in https://github.com/django/django/commit/0f0a07ac278dc2be6da81e519188f77e2a2a00cf

3.7 support for Django is tracked in https://code.djangoproject.com/ticket/28814

Comment 1 Matthias Runge 2018-05-29 09:26:59 UTC
Thank you for the report. I would prefer to wait with a rebuild, until a next django version was released. The upstream ticket is still in a "unknown state".

Comment 2 Miro Hrončok 2018-05-29 12:12:28 UTC
There are still other packages blocking Python 3.7. But once those are unblocked, we will need to proceed. This still happens in Copr only so far, but I'd like to continue in Fedora once 3.7.0rc1 is released and important packages are unblocked.

That said, we can wait for now, but when the time comes, we will need to apply the patch anyway

Django 2.1 should be released ~August 1. That's a bit too late (mass rebuild happens 1 month earlier).

Comment 3 Matthias Runge 2018-06-04 10:29:51 UTC
Django just built. I guess, we can close this bug? 

https://koji.fedoraproject.org/koji/buildinfo?buildID=1088523

Comment 4 Miro Hrončok 2018-06-04 11:10:30 UTC
That's still 3.6. I can recheck on 3.7.

Comment 5 Miro Hrončok 2018-06-04 12:07:35 UTC
Created attachment 1447407 [details]
build.log from copr

Still FTFBS.

Comment 6 Miro Hrončok 2018-06-08 10:39:23 UTC
3.7.0c1 is expected in 3 days (2018-06-11, [1]). I'd like to start building stuff in a side tag soon after that. I think we need to patch it.


[1] https://www.python.org/dev/peps/pep-0537/

Comment 7 Miro Hrončok 2018-06-08 19:06:25 UTC
https://src.fedoraproject.org/rpms/python-django/pull-request/6

I don't need a rebuild or release bump.


Note You need to log in before you can comment on or make changes to this bug.