Skip to content

Commit

Permalink
Update docs to reflect no more Python 2 support
Browse files Browse the repository at this point in the history
  • Loading branch information
mx-moth committed Dec 30, 2019
1 parent a0e5ca4 commit a9f214f
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 13 deletions.
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Django EnumChoiceField
.. image:: https://badge.fury.io/py/django-enumchoicefield.svg
:target: https://pypi.org/project/django-enumchoicefield/

A Django model field for native Python 3.4 Enums.
A Django model field for native Python Enums.

.. code:: python
Expand Down
8 changes: 1 addition & 7 deletions docs/setup.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,11 @@
Setup
=====

``django-enumchoicefield`` is compatible with Django 1.8 and higher, Python 2.7,
``django-enumchoicefield`` is compatible with Django 2.0 and higher,
and Python 3.4 and higher.

You can install ``django-enumchoicefield`` using pip:

.. code-block:: console
$ pip install django-enumchoicefield
On Python 2.7, you will also need to install ``enum34``:

.. code-block:: console
$ pip install enum34
5 changes: 0 additions & 5 deletions enumchoicefield/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,6 @@ def order_enum(field, members):
.annotate(my_order=order_enum('choice', MyEnum))\\
.order_by('my_order')
.. warning:: On Python 2, Enums may not have a consistent order,
depending upon how they were defined.
You can set an explicit order using ``__order__`` to fix this.
See the ``enum34`` docs for more information.
Any enum members not present in the list of members
will be sorted to the end of the results.
Expand Down

0 comments on commit a9f214f

Please sign in to comment.