Skip to content

Commit

Permalink
Merge branch 'master' into feature/unique-slug
Browse files Browse the repository at this point in the history
  • Loading branch information
PetrDlouhy authored Sep 2, 2020
2 parents fa2a487 + 3f9109f commit 4d54133
Show file tree
Hide file tree
Showing 7 changed files with 31 additions and 9 deletions.
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ dist: xenial
language: python

python:
- "2.7"
- "3.6"

install: pip install tox-travis
Expand Down
2 changes: 2 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ New in 1.8
==========

* Category.slug becomes unique. If there are any duplicates in category slugs, the migration will add sequence number to them.
* Support for Django 3.1
* Removed support for Python 2.7

New in 1.7
==========
Expand Down
4 changes: 2 additions & 2 deletions categories/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
__version_info__ = {
'major': 1,
'minor': 7,
'micro': 1,
'minor': 8,
'micro': 0,
'releaselevel': 'final',
'serial': 1
}
Expand Down
20 changes: 20 additions & 0 deletions categories/migrations/0004_auto_20200517_1832.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Generated by Django 3.0.6 on 2020-05-17 18:32

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

dependencies = [
('contenttypes', '0002_remove_content_type_name'),
('categories', '0003_auto_20200306_1050'),
]

operations = [
migrations.AlterField(
model_name='categoryrelation',
name='content_type',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='contenttypes.ContentType', verbose_name='content type'),
),
]
3 changes: 2 additions & 1 deletion categories/registration.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
"""
These functions handle the adding of fields to other models
"""
from django.db.models import FieldDoesNotExist, ForeignKey, ManyToManyField, CASCADE
from django.db.models import ForeignKey, ManyToManyField, CASCADE
from django.core.exceptions import FieldDoesNotExist
from . import fields
# from settings import self._field_registry, self._model_registry
from django.utils.translation import ugettext_lazy as _
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
django-mptt>=0.9.0,<0.11
django-mptt==0.11.0
unicode-slugify==0.1.3
8 changes: 4 additions & 4 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
[tox]
envlist =
begin
py27-lint
py27-django{111}
py36-django{111,2,21,22,3}
py36-lint
py36-django{111,2,21,22,3,31}
coverage-report

[testenv]
Expand All @@ -12,6 +11,7 @@ deps=
django21: Django>=2.1,<2.2
django22: Django>=2.2,<2.3
django3: Django>=3.0,<3.1
django31: Django>=3.1,<3.2
django111: Django>=1.11,<1.12
coverage
pillow
Expand All @@ -25,7 +25,7 @@ commands=
[testenv:begin]
commands = coverage erase

[testenv:py27-lint]
[testenv:py36-lint]
deps=
flake8

Expand Down

0 comments on commit 4d54133

Please sign in to comment.