[Django] #26425: django/utils/six.py generates a RemovedInDjango110Warning

69 views
Skip to first unread message

Django

unread,
Mar 30, 2016, 10:31:57 AM3/30/16
to django-...@googlegroups.com
#26425: django/utils/six.py generates a RemovedInDjango110Warning
-------------------------+-------------------------------------------------
Reporter: | Owner: nobody
mvanderlinde |
Type: Bug | Status: new
Component: | Version: 1.9
Utilities | Keywords:
Severity: Normal | runserver,SubfieldBase,RemovedInDjango110Warning
Triage Stage: | Has patch: 0
Unreviewed |
Easy pickings: 1 | UI/UX: 0
-------------------------+-------------------------------------------------
Using Django 1.9.4, Python 3.4.2, when performing a `runserver` command,
the following warning is displayed in the output:

```
/Users/coredev/.virtualenvs/newdjango/lib/python3.4/site-
packages/django/utils/six.py:808: RemovedInDjango110Warning: SubfieldBase
has been deprecated. Use Field.from_db_value instead.
```

--
Ticket URL: <https://code.djangoproject.com/ticket/26425>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Mar 30, 2016, 10:32:35 AM3/30/16
to django-...@googlegroups.com
#26425: django/utils/six.py generates a RemovedInDjango110Warning
-------------------------------------+-------------------------------------
Reporter: mvanderlinde | Owner: nobody
Type: Bug | Status: new
Component: Utilities | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage:
runserver,SubfieldBase,RemovedInDjango110Warning| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by mvanderlinde):

* needs_better_patch: => 0
* needs_tests: => 0
* needs_docs: => 0


Old description:

> Using Django 1.9.4, Python 3.4.2, when performing a `runserver` command,
> the following warning is displayed in the output:
>
> ```
> /Users/coredev/.virtualenvs/newdjango/lib/python3.4/site-
> packages/django/utils/six.py:808: RemovedInDjango110Warning: SubfieldBase
> has been deprecated. Use Field.from_db_value instead.
> ```

New description:

Using Django 1.9.4, Python 3.4.2, when performing a `runserver` command,
the following warning is displayed in the output:

`/Users/coredev/.virtualenvs/newdjango/lib/python3.4/site-
packages/django/utils/six.py:808: RemovedInDjango110Warning: SubfieldBase
has been deprecated. Use Field.from_db_value instead.`

--

--
Ticket URL: <https://code.djangoproject.com/ticket/26425#comment:1>

Django

unread,
Mar 30, 2016, 10:56:14 AM3/30/16
to django-...@googlegroups.com
#26425: django/utils/six.py generates a RemovedInDjango110Warning
-------------------------------------+-------------------------------------
Reporter: mvanderlinde | Owner: nobody
Type: Bug | Status: new

Component: Utilities | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage:
runserver,SubfieldBase,RemovedInDjango110Warning| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by timgraham):

I guess your code probably uses `six.with_metaclass()` and `stacklevel=2`
in that warning isn't helping in this case. I don't know if it's worth
spending any time trying to improve the situation since it's fairly easy
to grep a project directory to find usage of `SubfieldBase`.

--
Ticket URL: <https://code.djangoproject.com/ticket/26425#comment:2>

Django

unread,
Mar 30, 2016, 11:02:26 AM3/30/16
to django-...@googlegroups.com
#26425: django/utils/six.py generates a RemovedInDjango110Warning
-------------------------------------+-------------------------------------
Reporter: mvanderlinde | Owner: nobody
Type: Bug | Status: new

Component: Utilities | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage:
runserver,SubfieldBase,RemovedInDjango110Warning| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by mvanderlinde):

Replying to [comment:2 timgraham]:


> I guess your code probably uses `six.with_metaclass()` and
`stacklevel=2` in that warning isn't helping in this case. I don't know if
it's worth spending any time trying to improve the situation since it's
fairly easy to grep a project directory to find usage of `SubfieldBase`.

Ahh, you are correct. After doing a grep search of the site-packages
folder, I found an app that uses `six.with_metaclass()`. I will open a
ticket on the suspect app, instead. Thanks for the quick response!

--
Ticket URL: <https://code.djangoproject.com/ticket/26425#comment:3>

Django

unread,
Mar 30, 2016, 11:03:02 AM3/30/16
to django-...@googlegroups.com
#26425: django/utils/six.py generates a RemovedInDjango110Warning
-------------------------------------+-------------------------------------
Reporter: mvanderlinde | Owner: nobody
Type: Bug | Status: closed
Component: Utilities | Version: 1.9
Severity: Normal | Resolution: invalid

Keywords: | Triage Stage:
runserver,SubfieldBase,RemovedInDjango110Warning| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by mvanderlinde):

* status: new => closed
* resolution: => invalid


--
Ticket URL: <https://code.djangoproject.com/ticket/26425#comment:4>

Django

unread,
Apr 20, 2016, 11:41:30 AM4/20/16
to django-...@googlegroups.com
#26425: django/utils/six.py generates a RemovedInDjango110Warning
-------------------------------------+-------------------------------------
Reporter: mvanderlinde | Owner: nobody
Type: Bug | Status: new

Component: Utilities | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage:
runserver,SubfieldBase,RemovedInDjango110Warning| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by davidszotten):

* status: closed => new
* resolution: invalid =>


Comment:

seeing this from a few different 3rd party packages. if they are using
six.with_metaclass, the otherwise helpful indication of what caused there
warning is pretty useless

i guess it's possible to try to detect six, though an easier workaround
might be to bump the stacklevel, and err on the side of going too far,
which might at least find an import statement indicating where to look

thoughts?

--
Ticket URL: <https://code.djangoproject.com/ticket/26425#comment:5>

Django

unread,
Apr 20, 2016, 11:49:15 AM4/20/16
to django-...@googlegroups.com
#26425: SubfieldBase deprecation warning may appear as coming from six

-------------------------------------+-------------------------------------
Reporter: mvanderlinde | Owner: nobody
Type: | Status: new
Cleanup/optimization |

Component: Utilities | Version: 1.9
Severity: Normal | Resolution:
Keywords: | Triage Stage:
runserver,SubfieldBase,RemovedInDjango110Warning| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by timgraham):

* type: Bug => Cleanup/optimization
* easy: 1 => 0


Comment:

I don't think it's worth spending any time on this issue given grep should
be a simple solution.

--
Ticket URL: <https://code.djangoproject.com/ticket/26425#comment:6>

Django

unread,
Apr 20, 2016, 8:23:50 PM4/20/16
to django-...@googlegroups.com
#26425: SubfieldBase deprecation warning may appear as coming from six
-------------------------------------+-------------------------------------
Reporter: mvanderlinde | Owner: nobody
Type: | Status: closed

Cleanup/optimization |
Component: Utilities | Version: 1.9
Severity: Normal | Resolution: wontfix

Keywords: | Triage Stage:
runserver,SubfieldBase,RemovedInDjango110Warning| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by timgraham):

* status: new => closed
* resolution: => wontfix


Comment:

Feel free to reopen if you want to propose a patch.

--
Ticket URL: <https://code.djangoproject.com/ticket/26425#comment:7>

Reply all
Reply to author
Forward
0 new messages