Skip to content
This repository has been archived by the owner on Aug 21, 2024. It is now read-only.

Commit

Permalink
Removed deprecated future imports
Browse files Browse the repository at this point in the history
  • Loading branch information
mraarif committed Jun 18, 2020
1 parent 7df9c07 commit cfdf091
Show file tree
Hide file tree
Showing 102 changed files with 93 additions and 124 deletions.
2 changes: 1 addition & 1 deletion acceptance_tests/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import locale
import os
Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/course_validation/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import os

Expand Down
2 changes: 0 additions & 2 deletions acceptance_tests/course_validation/problem_count_stats.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
Script that produces min-max-avg for problem counts across all courses.
"""

from __future__ import absolute_import, print_function

from elasticsearch import Elasticsearch

es = Elasticsearch(retry_on_timeout=True)
Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/course_validation/report_generators.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import datetime
import logging
Expand Down
2 changes: 0 additions & 2 deletions acceptance_tests/course_validation/report_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@
$ python -m acceptance_tests.course_validation.report_runner
"""

from __future__ import absolute_import

import datetime
import io
import json
Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/mixins.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import datetime
import locale
Expand Down
4 changes: 1 addition & 3 deletions acceptance_tests/pages.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
Tests for course analytics pages
"""

from __future__ import absolute_import

from bok_choy.page_object import PageObject
from bok_choy.promise import EmptyPromise

Expand Down Expand Up @@ -317,7 +315,7 @@ def __init__(self, browser, course_id=None):

def is_browser_on_page(self):
return super(CourseLearnersPage, self).is_browser_on_page() \
and self.browser.title.startswith('Learners')
and self.browser.title.startswith('Learners')


class ErrorPage(DashboardPage):
Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_auth.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from unittest import skipUnless

Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_course_detail.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from bok_choy.web_app_test import WebAppTest

Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_course_engagement.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import datetime
from unittest import skipUnless
Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_course_enrollment.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import datetime
from collections import OrderedDict
Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_course_enrollment_demographics.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import datetime

Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_course_index.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import requests
from bok_choy.promise import EmptyPromise
Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_course_learners.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from unittest import skipUnless

Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_course_performance.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import datetime
from unittest import skipUnless
Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_error_pages.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from unittest import skipUnless

Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_landing.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from bok_choy.web_app_test import WebAppTest
from six.moves import range
Expand Down
2 changes: 1 addition & 1 deletion acceptance_tests/test_status.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from unittest import TestCase

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/admin.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from django.contrib import admin
from django.contrib.auth.admin import UserAdmin
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/apps.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import re

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/context_processors.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from django.conf import settings

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from django.core.management.base import BaseCommand

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from django.core.management.base import BaseCommand

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from django.contrib.auth import get_user_model
from django.core.management.base import BaseCommand
Expand Down
2 changes: 0 additions & 2 deletions analytics_dashboard/core/middleware.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
Middleware for Language Preferences
"""

from __future__ import absolute_import

import logging

from django.template.response import TemplateResponse
Expand Down
1 change: 0 additions & 1 deletion analytics_dashboard/core/migrations/0001_initial.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
# -*- coding: utf-8 -*-
from __future__ import absolute_import, unicode_literals

import django.core.validators
import django.utils.timezone
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
from __future__ import absolute_import, unicode_literals


import django.contrib.auth.models
import django.core.validators
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.9.9 on 2016-08-01 21:41
from __future__ import absolute_import, unicode_literals


import django.core.validators
from django.db import migrations, models
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.11.2 on 2017-07-20 17:10
from __future__ import absolute_import, unicode_literals


import django.contrib.auth.validators
from django.db import migrations, models
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/models.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from django.conf import settings
from django.contrib.auth.models import AbstractUser
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/templatetags/dashboard_extras.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import json

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/tests/test_middleware.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import logging

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/tests/test_templatetags.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/python
# -*- coding: utf-8 -*-
from __future__ import absolute_import


import json

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/tests/test_utils.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import uuid
from copy import deepcopy
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/tests/test_views.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import json
import logging
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/utils.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from hashlib import md5

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/core/views.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import json
import logging
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/exceptions.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import abc

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/middleware.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
This file contains Django middleware. For more information visit
https://docs.djangoproject.com/en/dev/topics/http/middleware/.
"""
from __future__ import absolute_import


import logging

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/permissions.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import datetime
import logging
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/presenters/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import abc
import datetime
Expand Down
1 change: 0 additions & 1 deletion analytics_dashboard/courses/presenters/course_summaries.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
from __future__ import absolute_import

from functools import reduce # pylint: disable=redefined-builtin

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/presenters/engagement.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import datetime
import logging
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/presenters/enrollment.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import copy
import datetime
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/presenters/performance.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import logging
from collections import OrderedDict, namedtuple
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/presenters/programs.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from django.core.cache import cache

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/serializers.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from django.core.serializers.json import DjangoJSONEncoder
from django.utils.encoding import force_text
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/tests/factories.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import hashlib
import re
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/tests/test_middleware.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import logging

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/tests/test_permissions.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import unittest.mock as mock
import ddt
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import unittest.mock as mock
import six
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import, division


import copy
import datetime
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import unittest.mock as mock
from ddt import data, ddt, unpack
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/tests/test_serializers.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import json

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/tests/test_utils.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from django.contrib.auth.models import AnonymousUser
from django.test import RequestFactory, TestCase
Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/tests/test_views/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import json
import logging
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import json

Expand Down
2 changes: 1 addition & 1 deletion analytics_dashboard/courses/tests/test_views/test_csv.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import unittest.mock as mock
import six
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


from unittest.mock import Mock, patch
import analyticsclient.constants.activity_types as AT
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import json

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from __future__ import absolute_import


import json
import logging
Expand Down
Loading

0 comments on commit cfdf091

Please sign in to comment.