Remove #noqa from django.conf.urls.include
We have one more import with #noqa: django.conf.urls.include that is also commonly used in urls.py module and could be included to the list of import exceptions. This change has also revealed one unused import. Change-Id: I47cc582340625aac87ab0242b147e11ef1d9b38e
This commit is contained in:
parent
cdad4940e7
commit
b47f226647
27
HACKING.rst
27
HACKING.rst
@ -3,30 +3,9 @@ Horizon Style Commandments
|
||||
|
||||
- Step 1: Read the OpenStack Style Commandments
|
||||
http://docs.openstack.org/developer/hacking/
|
||||
- Step 2: The following names can be imported directly, without triggering the
|
||||
"H302: import only modules" flake8 warning::
|
||||
|
||||
collections.defaultdict,
|
||||
django.conf.settings,
|
||||
django.conf.urls.patterns,
|
||||
django.conf.urls.url,
|
||||
django.core.urlresolvers.reverse,
|
||||
django.core.urlresolvers.reverse_lazy,
|
||||
django.template.loader.render_to_string,
|
||||
django.test.utils.override_settings,
|
||||
django.utils.datastructures.SortedDict,
|
||||
django.utils.encoding.force_text,
|
||||
django.utils.html.conditional_escape,
|
||||
django.utils.html.escape,
|
||||
django.utils.http.urlencode,
|
||||
django.utils.safestring.mark_safe,
|
||||
django.utils.translation.npgettext_lazy,
|
||||
django.utils.translation.pgettext_lazy,
|
||||
django.utils.translation.ugettext_lazy,
|
||||
django.utils.translation.ungettext_lazy,
|
||||
operator.attrgetter,
|
||||
StringIO.StringIO
|
||||
|
||||
- Step 2: Read [hacking] section in tox.ini to find the list of names which
|
||||
can be imported directly without triggering the "H302: import only modules"
|
||||
flake8 warning
|
||||
- Step 3: Read on
|
||||
|
||||
Horizon Specific Commandments
|
||||
|
@ -27,7 +27,7 @@ import logging
|
||||
import os
|
||||
|
||||
from django.conf import settings
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
from django.core.exceptions import ImproperlyConfigured # noqa
|
||||
|
@ -17,7 +17,7 @@
|
||||
# under the License.
|
||||
|
||||
from django.conf import settings
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
from django.views.generic import TemplateView # noqa
|
||||
|
@ -20,7 +20,7 @@
|
||||
URL patterns for testing Horizon views.
|
||||
"""
|
||||
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
from django.contrib.staticfiles.urls import staticfiles_urlpatterns # noqa
|
||||
|
@ -12,7 +12,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
|
@ -12,7 +12,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
|
@ -10,7 +10,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
|
@ -10,7 +10,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
|
@ -10,7 +10,6 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
|
@ -16,7 +16,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
|
@ -16,7 +16,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
|
@ -12,7 +12,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
|
@ -12,7 +12,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls import url
|
||||
|
||||
|
@ -21,7 +21,7 @@ URL patterns for the OpenStack Dashboard.
|
||||
"""
|
||||
|
||||
from django.conf import settings
|
||||
from django.conf.urls import include # noqa
|
||||
from django.conf.urls import include
|
||||
from django.conf.urls import patterns
|
||||
from django.conf.urls.static import static # noqa
|
||||
from django.conf.urls import url
|
||||
|
Loading…
Reference in New Issue
Block a user