Skip to content

Commit

Permalink
Merge pull request #556 from carltongibson/develop
Browse files Browse the repository at this point in the history
Version 1.0 Release
  • Loading branch information
Carlton Gibson committed Nov 17, 2016
2 parents abaa3bb + 3a18f11 commit f5b2d63
Show file tree
Hide file tree
Showing 46 changed files with 2,098 additions and 1,503 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 0.15.3
current_version = 1.0.0
commit = False
tag = False
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(\-(?P<release>[a-z]+))?
Expand Down
45 changes: 8 additions & 37 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,45 +1,16 @@
language: python

sudo: false

language: python
python: '3.5'
cache: pip

python:
- "2.7"
- "3.3"
- "3.4"
- "3.5"

env:
- DJANGO='https://github.com/django/django/archive/master.tar.gz' REST_FRAMEWORK='djangorestframework>=3.4,<3.5'
- DJANGO="django>=1.10.0,<1.11.0" REST_FRAMEWORK="djangorestframework>=3.4,<3.5"
- DJANGO="django>=1.9.0,<1.10.0" REST_FRAMEWORK="djangorestframework>=3.4,<3.5"
- DJANGO="django>=1.8.0,<1.9.0" REST_FRAMEWORK="djangorestframework>=3.4,<3.5"
- DJANGO="django>=1.8.0,<1.9.0" REST_FRAMEWORK="djangorestframework>=3.3,<3.4"

install:
- travis_retry pip install -Ur requirements/test-ci.txt
- travis_retry pip install $DJANGO $REST_FRAMEWORK
- pip install coverage tox

script:
- $W coverage run --source django_filters runtests.py -v 2
- coverage report
- coverage erase
- tox

notifications:
email: false

matrix:
exclude:
- python: "3.3"
env: DJANGO='https://github.com/django/django/archive/master.tar.gz' REST_FRAMEWORK='djangorestframework>=3.4,<3.5'
- python: "3.3"
env: DJANGO="django>=1.10.0,<1.11.0" REST_FRAMEWORK="djangorestframework>=3.4,<3.5"
- python: "3.3"
env: DJANGO="django>=1.9.0,<1.10.0" REST_FRAMEWORK="djangorestframework>=3.4,<3.5"
include:
- python: "3.5"
env: W='python -W error -m' DJANGO='https://github.com/django/django/archive/master.tar.gz' REST_FRAMEWORK='djangorestframework>=3.4,<3.5'
allow_failures:
- env: W='python -W error -m' DJANGO='https://github.com/django/django/archive/master.tar.gz' REST_FRAMEWORK='djangorestframework>=3.4,<3.5'
- env: DJANGO='https://github.com/django/django/archive/master.tar.gz' REST_FRAMEWORK='djangorestframework>=3.4,<3.5'
fast_finish: true
after_success:
- coverage combine
- coverage report
19 changes: 19 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,20 @@
Version 1.0 (2016-11-17)
------------------------

This release removes all the deprecated code from 0.14 and 0.15 for 1.0 #480.

Please see the `Migration Notes`__ for details of how to migrate.
Stick with 0.15.3 if you're not ready to update.

__ https://github.com/carltongibson/django-filter/blob/develop/docs/migration.txt

The release includes a number of small fixes and documentation updates.

See the `1.0 Milestone`__ for full details.

__ https://github.com/carltongibson/django-filter/milestone/8?closed=1


Version 0.15.3 (2016-10-17)
---------------------------

Expand Down Expand Up @@ -60,6 +77,8 @@ __ https://github.com/carltongibson/django-filter/blob/develop/docs/migration.tx
Version 0.14.0 (2016-08-14)
---------------------------

* Confirmed support for Django 1.10.

* Add support for filtering on DurationField (new in Django 1.8).

* Fix UUIDFilter import issue
Expand Down
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.PHONY: deps, test

deps:
pip install -r ./requirements/test.txt

test:
./runtests.py
6 changes: 3 additions & 3 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ Full documentation on `read the docs`_.
Requirements
------------

* Python 2.7, 3.3, 3.4, 3.5
* Django 1.8, 1.9, 1.10
* DRF 3.3 (Django 1.8 only), 3.4
* **Python**: 2.7, 3.3, 3.4, 3.5
* **Django**: 1.8, 1.9, 1.10
* **DRF**: 3.4, 3.5

Installation
------------
Expand Down
3 changes: 2 additions & 1 deletion django_filters/__init__.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
# flake8: noqa
from __future__ import absolute_import
from .constants import STRICTNESS
from .filterset import FilterSet
from .filters import *

__version__ = '0.15.3'
__version__ = '1.0.0'


def parse_version(version):
Expand Down
6 changes: 4 additions & 2 deletions django_filters/compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,11 @@
is_crispy = 'crispy_forms' in settings.INSTALLED_APPS and crispy_forms


# coreapi only compatible with DRF 3.4+
# coreapi is optional (Note that uritemplate is a dependency of coreapi)
# Fixes #525 - cannot simply import from rest_framework.compat, due to
# import issues w/ django-guardian.
try:
from rest_framework.compat import coreapi
import coreapi
except ImportError:
coreapi = None

Expand Down
10 changes: 10 additions & 0 deletions django_filters/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,22 @@
from django.core.signals import setting_changed
from django.utils.translation import ugettext_lazy as _

from .constants import STRICTNESS
from .utils import deprecate


DEFAULTS = {
'DISABLE_HELP_TEXT': False,
'HELP_TEXT_FILTER': True,
'HELP_TEXT_EXCLUDE': True,

# empty/null choices
'EMPTY_CHOICE_LABEL': '---------',
'NULL_CHOICE_LABEL': None,
'NULL_CHOICE_VALUE': 'null',

'STRICTNESS': STRICTNESS.RETURN_NO_RESULTS,

'VERBOSE_LOOKUPS': {
# transforms don't need to be verbose, since their expressions are chained
'date': _('date'),
Expand Down
21 changes: 21 additions & 0 deletions django_filters/constants.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@

ALL_FIELDS = '__all__'


class STRICTNESS:
class IGNORE:
pass

class RETURN_NO_RESULTS:
pass

class RAISE_VALIDATION_ERROR:
pass

# Values of False & True chosen for backward compatability reasons.
# Originally, these were the only options.
_LEGACY = {
False: IGNORE,
True: RETURN_NO_RESULTS,
"RAISE": RAISE_VALIDATION_ERROR,
}

0 comments on commit f5b2d63

Please sign in to comment.