This updates Django to v1.11.10 and and all updates related supporting
requirements and introduces some code changes required to keep things
running smoothly
django-filters 1.x required updates to all API filter classes
Implemented new filter class for Attribute model API viewset,
replacing AttributeViewSet.filter_fields with .filter_class
All existing MethodFilter fields had to be converted to typed
fields that specified method= as an argument
All .filter_foo() methods had to have a new name argument added
to their signature
Custom database model fields have been updated to include the new
.from_db_value() method which differs only slightly from the
.to_python() method for each custom field.
The nsot-server upgrade command no longer calls syncdb (which has
been deprecated) underneath has been updated to call migrate
instead.
All places where django.utils.log.getLogger was being called has
been replaced with logging.getLogger
Calls to django.core.handlers.wsgi.STATUS_CODE_TEXT have been
replaced with httplib.responses
django-macaddress required all MAC address objects to conform to
EUIv48 format: settings.INTERFACE_DEFAULT_MAC has been explicitly
set to use EUIv48 format
nsot.validators.validate_mac_address() no longer utilizes
macaddress.formfields.MacAddressField.clean() as a validator and
instead directly instantitates a netaddr.EUI() object to assert
validity.
Because pytest-django had to be updated, so did pytest, and new test
warnings were occuring when tests.api_tests.fixtures.TestSite was
used. It has been renamed to SiteHelper to avoid the warnings.
This updates Django to v1.11.10 and and all updates related supporting requirements and introduces some code changes required to keep things running smoothly
AttributeViewSet.filter_fields
with.filter_class
MethodFilter
fields had to be converted to typed fields that specifiedmethod=
as an argument.filter_foo()
methods had to have a newname
argument added to their signature.from_db_value()
method which differs only slightly from the.to_python()
method for each custom field.nsot-server upgrade
command no longer callssyncdb
(which has been deprecated) underneath has been updated to callmigrate
instead.django.utils.log.getLogger
was being called has been replaced withlogging.getLogger
django.core.handlers.wsgi.STATUS_CODE_TEXT
have been replaced withhttplib.responses
settings.INTERFACE_DEFAULT_MAC
has been explicitly set to use EUIv48 formatnsot.validators.validate_mac_address()
no longer utilizesmacaddress.formfields.MacAddressField.clean()
as a validator and instead directly instantitates anetaddr.EUI()
object to assert validity.tests.api_tests.fixtures.TestSite
was used. It has been renamed toSiteHelper
to avoid the warnings.