INCR-159 Run python-modernize on openedx/core/djangoapps/zendesk_proxy (#20474)

* INCR-159 Run python-modernize on openedx/core/djangoapps/zendesk_proxy

* INCR-159 added docstring and disabled spurious import error
This commit is contained in:
aliciaerwin
2019-05-09 13:39:37 -04:00
committed by Michael Youngstrom
parent bf47cd0cc2
commit d03f970be6
8 changed files with 16 additions and 1 deletions

View File

@@ -3,6 +3,7 @@ Zendesk Proxy Configuration
"""
from __future__ import absolute_import
from django.apps import AppConfig
from openedx.core.djangoapps.plugins.constants import ProjectType, SettingsType, PluginURLs, PluginSettings

View File

@@ -1,3 +1,8 @@
"""
Tests of Zendesk interaction utility functions
"""
from __future__ import absolute_import
import ddt
from django.test.utils import override_settings
from mock import MagicMock, patch

View File

@@ -1,4 +1,5 @@
"""Tests for zendesk_proxy views."""
from __future__ import absolute_import
import json
from copy import deepcopy
@@ -9,6 +10,7 @@ from mock import MagicMock, patch
from openedx.core.djangoapps.zendesk_proxy.v0.views import ZENDESK_REQUESTS_PER_HOUR
from openedx.core.lib.api.test_utils import ApiTestCase
from six.moves import range
@ddt.ddt

View File

@@ -1,4 +1,5 @@
"""Tests for zendesk_proxy views."""
from __future__ import absolute_import
import json
from copy import deepcopy
@@ -9,6 +10,7 @@ from mock import MagicMock, patch
from openedx.core.djangoapps.zendesk_proxy.v1.views import ZendeskProxyThrottle
from openedx.core.lib.api.test_utils import ApiTestCase
from six.moves import range
@ddt.ddt

View File

@@ -2,6 +2,7 @@
Map urls to the relevant view handlers
"""
from __future__ import absolute_import
from django.conf.urls import url
from openedx.core.djangoapps.zendesk_proxy.v0.views import ZendeskPassthroughView as v0_view

View File

@@ -1,9 +1,11 @@
"""
Utility functions for zendesk interaction.
"""
from __future__ import absolute_import
import json
import logging
from urlparse import urljoin
from six.moves.urllib.parse import urljoin # pylint: disable=import-error
from django.conf import settings
import requests

View File

@@ -1,6 +1,7 @@
"""
Define request handlers used by the zendesk_proxy djangoapp
"""
from __future__ import absolute_import
from rest_framework import status
from rest_framework.parsers import JSONParser
from rest_framework.response import Response

View File

@@ -1,6 +1,7 @@
"""
Define request handlers used by the zendesk_proxy djangoapp
"""
from __future__ import absolute_import
from rest_framework import status
from rest_framework.parsers import JSONParser
from rest_framework.response import Response