From 247bb50ed2699c9e723f32cfe64f351fef030a44 Mon Sep 17 00:00:00 2001 From: Eric Fischer <efischer@edx.org> Date: Tue, 5 Jun 2018 13:18:40 -0400 Subject: [PATCH] s/django.core.urlresolvers/django.urls/g Django 1.10 deprecation fix for Hackathon XIX Addresses PLAT-1397 --- cms/djangoapps/api/v1/tests/test_views/test_course_runs.py | 2 +- cms/djangoapps/cms_user_tasks/signals.py | 2 +- cms/djangoapps/cms_user_tasks/tests.py | 2 +- cms/djangoapps/contentstore/api/tests/test_views.py | 2 +- cms/djangoapps/contentstore/courseware_index.py | 2 +- cms/djangoapps/contentstore/tests/test_course_create_rerun.py | 2 +- cms/djangoapps/contentstore/tests/test_request_event.py | 2 +- cms/djangoapps/contentstore/tests/tests.py | 2 +- cms/djangoapps/contentstore/utils.py | 2 +- cms/djangoapps/contentstore/views/course.py | 2 +- cms/djangoapps/contentstore/views/preview.py | 2 +- cms/djangoapps/contentstore/views/public.py | 2 +- cms/djangoapps/contentstore/views/tests/test_item.py | 2 +- cms/djangoapps/contentstore/views/tests/test_organizations.py | 2 +- .../contentstore/views/tests/test_transcript_settings.py | 2 +- cms/djangoapps/contentstore/views/tests/test_transcripts.py | 2 +- cms/djangoapps/contentstore/views/videos.py | 2 +- cms/djangoapps/course_creators/tests/test_views.py | 2 +- cms/djangoapps/maintenance/tests.py | 2 +- cms/lib/xblock/runtime.py | 2 +- cms/templates/accessibility.html | 2 +- cms/templates/asset_index.html | 2 +- cms/templates/course-create-rerun.html | 2 +- cms/templates/edit-tabs.html | 2 +- cms/templates/error.html | 2 +- cms/templates/export_git.html | 2 +- cms/templates/howitworks.html | 2 +- cms/templates/html_error.html | 2 +- cms/templates/login.html | 2 +- cms/templates/maintenance/base.html | 2 +- cms/templates/maintenance/container.html | 2 +- cms/templates/maintenance/index.html | 2 +- cms/templates/manage_users.html | 2 +- cms/templates/manage_users_lib.html | 2 +- cms/templates/register.html | 2 +- cms/templates/registration/activation_complete.html | 2 +- cms/templates/registration/activation_invalid.html | 2 +- cms/templates/widgets/footer.html | 2 +- cms/templates/widgets/header.html | 2 +- cms/templates/widgets/user_dropdown.html | 4 ++-- common/djangoapps/course_modes/tests/test_admin.py | 2 +- common/djangoapps/course_modes/tests/test_views.py | 2 +- common/djangoapps/course_modes/views.py | 2 +- common/djangoapps/edxmako/shortcuts.py | 2 +- common/djangoapps/edxmako/tests.py | 2 +- common/djangoapps/enrollment/tests/test_views.py | 2 +- common/djangoapps/entitlements/api/v1/tests/test_views.py | 2 +- .../microsite_configuration/tests/backends/test_filebased.py | 2 +- common/djangoapps/student/cookies.py | 2 +- common/djangoapps/student/forms.py | 2 +- common/djangoapps/student/helpers.py | 2 +- common/djangoapps/student/tests/test_activate_account.py | 2 +- common/djangoapps/student/tests/test_admin_views.py | 2 +- common/djangoapps/student/tests/test_bulk_email_settings.py | 2 +- common/djangoapps/student/tests/test_certificates.py | 2 +- .../djangoapps/student/tests/test_configuration_overrides.py | 2 +- common/djangoapps/student/tests/test_cookies.py | 2 +- common/djangoapps/student/tests/test_create_account.py | 2 +- common/djangoapps/student/tests/test_credit.py | 2 +- common/djangoapps/student/tests/test_email.py | 2 +- common/djangoapps/student/tests/test_enrollment.py | 2 +- common/djangoapps/student/tests/test_helpers.py | 2 +- common/djangoapps/student/tests/test_login.py | 2 +- .../djangoapps/student/tests/test_login_registration_forms.py | 2 +- common/djangoapps/student/tests/test_long_username_email.py | 2 +- common/djangoapps/student/tests/test_password_policy.py | 2 +- common/djangoapps/student/tests/test_recent_enrollments.py | 2 +- common/djangoapps/student/tests/test_refunds.py | 2 +- common/djangoapps/student/tests/test_reset_password.py | 2 +- common/djangoapps/student/tests/test_retirement.py | 2 +- common/djangoapps/student/tests/test_userstanding.py | 2 +- common/djangoapps/student/tests/test_verification_status.py | 2 +- common/djangoapps/student/tests/test_views.py | 2 +- common/djangoapps/student/tests/tests.py | 2 +- common/djangoapps/student/views/dashboard.py | 2 +- common/djangoapps/student/views/login.py | 2 +- common/djangoapps/student/views/management.py | 2 +- common/djangoapps/third_party_auth/admin.py | 2 +- common/djangoapps/third_party_auth/api/tests/test_views.py | 2 +- common/djangoapps/third_party_auth/decorators.py | 1 - common/djangoapps/third_party_auth/pipeline.py | 2 +- common/djangoapps/third_party_auth/tests/specs/base.py | 2 +- common/djangoapps/third_party_auth/tests/specs/test_google.py | 2 +- common/djangoapps/third_party_auth/tests/specs/test_lti.py | 2 +- common/djangoapps/third_party_auth/tests/test_admin.py | 2 +- common/djangoapps/third_party_auth/views.py | 2 +- common/djangoapps/track/tests/test_logs.py | 2 +- common/djangoapps/util/testing.py | 2 +- common/djangoapps/util/url.py | 2 +- common/test/test-theme/cms/templates/login.html | 2 +- .../test/test_sites/test_site/templates/courseware/tabs.html | 2 +- .../test_site/templates/emails/confirm_email_change.txt | 2 +- common/test/test_sites/test_site/templates/footer.html | 2 +- common/test/test_sites/test_site/templates/login-sidebar.html | 4 ++-- .../test/test_sites/test_site/templates/register-sidebar.html | 2 +- .../test_site/templates/static_templates/about.html | 2 +- .../test_site/templates/static_templates/contact.html | 2 +- .../test_sites/test_site/templates/static_templates/faq.html | 2 +- .../test_sites/test_site/templates/static_templates/tos.html | 2 +- lms/djangoapps/badges/events/course_complete.py | 2 +- lms/djangoapps/branding/api.py | 2 +- lms/djangoapps/branding/tests/test_api.py | 2 +- lms/djangoapps/branding/tests/test_page.py | 2 +- lms/djangoapps/branding/tests/test_views.py | 2 +- lms/djangoapps/branding/views.py | 2 +- lms/djangoapps/bulk_email/tasks.py | 2 +- lms/djangoapps/bulk_email/tests/test_course_optout.py | 2 +- lms/djangoapps/bulk_email/tests/test_email.py | 2 +- lms/djangoapps/bulk_email/tests/test_err_handling.py | 2 +- lms/djangoapps/bulk_email/tests/test_signals.py | 2 +- lms/djangoapps/bulk_enroll/tests/test_views.py | 2 +- lms/djangoapps/ccx/api/v0/tests/test_views.py | 2 +- lms/djangoapps/ccx/tests/test_views.py | 2 +- lms/djangoapps/ccx/utils.py | 2 +- lms/djangoapps/ccx/views.py | 2 +- lms/djangoapps/certificates/api.py | 2 +- lms/djangoapps/certificates/apis/v0/tests/test_views.py | 2 +- lms/djangoapps/certificates/queue.py | 2 +- lms/djangoapps/certificates/tests/test_api.py | 2 +- lms/djangoapps/certificates/tests/test_support_views.py | 2 +- lms/djangoapps/certificates/tests/test_views.py | 2 +- lms/djangoapps/certificates/tests/test_webview_views.py | 2 +- lms/djangoapps/class_dashboard/tests/test_dashboard_data.py | 2 +- lms/djangoapps/commerce/api/v0/tests/test_views.py | 2 +- lms/djangoapps/commerce/api/v0/views.py | 2 +- lms/djangoapps/commerce/api/v1/tests/test_views.py | 2 +- lms/djangoapps/commerce/tests/test_views.py | 2 +- lms/djangoapps/commerce/utils.py | 2 +- lms/djangoapps/course_api/blocks/tests/test_views.py | 2 +- lms/djangoapps/course_api/serializers.py | 2 +- lms/djangoapps/course_api/tests/test_views.py | 2 +- lms/djangoapps/course_goals/tests/test_api.py | 2 +- lms/djangoapps/course_wiki/tests/tests.py | 2 +- lms/djangoapps/courseware/courses.py | 2 +- lms/djangoapps/courseware/date_summary.py | 2 +- lms/djangoapps/courseware/features/common.py | 2 +- lms/djangoapps/courseware/module_render.py | 2 +- lms/djangoapps/courseware/tests/helpers.py | 2 +- lms/djangoapps/courseware/tests/test_about.py | 2 +- lms/djangoapps/courseware/tests/test_access.py | 2 +- lms/djangoapps/courseware/tests/test_course_info.py | 2 +- lms/djangoapps/courseware/tests/test_course_survey.py | 2 +- lms/djangoapps/courseware/tests/test_courses.py | 2 +- lms/djangoapps/courseware/tests/test_credit_requirements.py | 2 +- lms/djangoapps/courseware/tests/test_date_summary.py | 2 +- lms/djangoapps/courseware/tests/test_discussion_xblock.py | 2 +- lms/djangoapps/courseware/tests/test_entrance_exam.py | 2 +- lms/djangoapps/courseware/tests/test_i18n.py | 2 +- lms/djangoapps/courseware/tests/test_lti_integration.py | 2 +- lms/djangoapps/courseware/tests/test_masquerade.py | 2 +- lms/djangoapps/courseware/tests/test_microsites.py | 2 +- lms/djangoapps/courseware/tests/test_module_render.py | 2 +- lms/djangoapps/courseware/tests/test_navigation.py | 2 +- lms/djangoapps/courseware/tests/test_password_history.py | 2 +- lms/djangoapps/courseware/tests/test_split_module.py | 2 +- lms/djangoapps/courseware/tests/test_submitting_problems.py | 2 +- lms/djangoapps/courseware/tests/test_tabs.py | 2 +- lms/djangoapps/courseware/tests/test_view_authentication.py | 2 +- lms/djangoapps/courseware/tests/test_views.py | 2 +- lms/djangoapps/courseware/tests/tests.py | 2 +- lms/djangoapps/courseware/url_helpers.py | 2 +- lms/djangoapps/courseware/views/index.py | 2 +- lms/djangoapps/courseware/views/views.py | 2 +- lms/djangoapps/dashboard/tests/test_sysadmin.py | 2 +- .../templates/discussion/discussion_board_fragment.html | 2 +- .../templates/discussion/discussion_profile_page.html | 2 +- lms/djangoapps/discussion/tests/test_views.py | 2 +- lms/djangoapps/discussion/views.py | 2 +- lms/djangoapps/discussion_api/api.py | 2 +- lms/djangoapps/discussion_api/serializers.py | 2 +- lms/djangoapps/discussion_api/tests/test_views.py | 2 +- .../django_comment_client/base/event_transformers.py | 2 +- lms/djangoapps/django_comment_client/base/tests.py | 2 +- lms/djangoapps/django_comment_client/tests/test_utils.py | 2 +- lms/djangoapps/django_comment_client/utils.py | 2 +- lms/djangoapps/edxnotes/helpers.py | 2 +- lms/djangoapps/edxnotes/tests.py | 2 +- lms/djangoapps/edxnotes/views.py | 2 +- lms/djangoapps/experiments/tests/test_views.py | 2 +- lms/djangoapps/grades/api/tests/test_views.py | 2 +- lms/djangoapps/grades/api/v1/tests/test_views.py | 2 +- lms/djangoapps/instructor/enrollment.py | 2 +- lms/djangoapps/instructor/tests/test_api.py | 2 +- .../instructor/tests/test_api_email_localization.py | 2 +- lms/djangoapps/instructor/tests/test_certificates.py | 2 +- lms/djangoapps/instructor/tests/test_ecommerce.py | 2 +- lms/djangoapps/instructor/tests/test_email.py | 2 +- lms/djangoapps/instructor/tests/test_proctoring.py | 2 +- lms/djangoapps/instructor/tests/test_registration_codes.py | 2 +- lms/djangoapps/instructor/tests/test_spoc_gradebook.py | 2 +- .../instructor/tests/views/test_instructor_dashboard.py | 2 +- lms/djangoapps/instructor/views/api.py | 2 +- lms/djangoapps/instructor/views/gradebook_api.py | 2 +- lms/djangoapps/instructor/views/instructor_dashboard.py | 2 +- lms/djangoapps/instructor/views/registration_codes.py | 2 +- lms/djangoapps/instructor_analytics/basic.py | 2 +- lms/djangoapps/instructor_analytics/tests/test_basic.py | 2 +- lms/djangoapps/instructor_task/tests/test_base.py | 2 +- lms/djangoapps/instructor_task/tests/test_integration.py | 2 +- lms/djangoapps/instructor_task/tests/test_tasks_helper.py | 2 +- lms/djangoapps/learner_dashboard/programs.py | 2 +- lms/djangoapps/learner_dashboard/tests/test_programs.py | 2 +- lms/djangoapps/lms_xblock/runtime.py | 2 +- lms/djangoapps/lti_provider/tests/test_views.py | 2 +- lms/djangoapps/mobile_api/testutils.py | 2 +- lms/djangoapps/notes/models.py | 2 +- lms/djangoapps/notes/tests.py | 2 +- lms/djangoapps/notification_prefs/tests.py | 2 +- lms/djangoapps/rss_proxy/tests/test_views.py | 2 +- lms/djangoapps/shoppingcart/api.py | 2 +- lms/djangoapps/shoppingcart/models.py | 2 +- .../shoppingcart/tests/test_configuration_overrides.py | 2 +- lms/djangoapps/shoppingcart/tests/test_models.py | 2 +- lms/djangoapps/shoppingcart/tests/test_views.py | 2 +- lms/djangoapps/shoppingcart/views.py | 2 +- lms/djangoapps/static_template_view/tests/test_views.py | 2 +- lms/djangoapps/staticbook/tests.py | 2 +- lms/djangoapps/student_account/test/test_views.py | 2 +- lms/djangoapps/student_account/views.py | 2 +- lms/djangoapps/support/tests/test_views.py | 2 +- lms/djangoapps/support/views/enrollments.py | 2 +- lms/djangoapps/support/views/index.py | 2 +- lms/djangoapps/support/views/manage_user.py | 2 +- lms/djangoapps/survey/tests/test_views.py | 2 +- lms/djangoapps/survey/views.py | 2 +- lms/djangoapps/teams/tests/test_views.py | 2 +- lms/djangoapps/verify_student/models.py | 2 +- lms/djangoapps/verify_student/services.py | 2 +- lms/djangoapps/verify_student/tests/fake_software_secure.py | 2 +- lms/djangoapps/verify_student/tests/test_integration.py | 2 +- lms/djangoapps/verify_student/tests/test_views.py | 2 +- lms/djangoapps/verify_student/views.py | 2 +- lms/lib/courseware_search/lms_result_processor.py | 2 +- lms/templates/api_admin/catalogs/edit.html | 2 +- lms/templates/api_admin/catalogs/list.html | 2 +- lms/templates/api_admin/catalogs/search.html | 2 +- lms/templates/api_admin/terms_of_service.html | 2 +- lms/templates/bookmark_button.html | 2 +- lms/templates/calculator/toggle_calculator.html | 2 +- lms/templates/ccx/coach_dashboard.html | 2 +- lms/templates/class_dashboard/all_section_metrics.js | 4 ++-- lms/templates/conditional_module.html | 2 +- lms/templates/course.html | 2 +- lms/templates/course_modes/choose.html | 2 +- lms/templates/courseware/accordion.html | 2 +- lms/templates/courseware/course_about.html | 2 +- lms/templates/courseware/course_about_sidebar_header.html | 2 +- lms/templates/courseware/course_navigation.html | 2 +- lms/templates/courseware/courseware.html | 2 +- lms/templates/courseware/gradebook.html | 2 +- lms/templates/courseware/info.html | 2 +- lms/templates/courseware/program_marketing.html | 2 +- lms/templates/courseware/progress.html | 2 +- lms/templates/courseware/tabs.html | 2 +- lms/templates/dashboard.html | 2 +- lms/templates/dashboard/_dashboard_course_listing.html | 2 +- lms/templates/dashboard/_dashboard_entitlement_actions.html | 2 +- lms/templates/dashboard/_dashboard_status_verification.html | 2 +- lms/templates/edxnotes/toggle_notes.html | 2 +- lms/templates/email_change_successful.html | 2 +- lms/templates/emails/confirm_email_change.txt | 2 +- lms/templates/financial-assistance/financial-assistance.html | 2 +- lms/templates/footer.html | 2 +- lms/templates/forgot_password_modal.html | 2 +- lms/templates/header/brand.html | 2 +- lms/templates/header/header.html | 2 +- lms/templates/header/navbar-authenticated.html | 2 +- lms/templates/header/navbar-logo-header.html | 2 +- lms/templates/header/navbar-not-authenticated.html | 2 +- lms/templates/header/user_dropdown.html | 2 +- lms/templates/help_modal.html | 2 +- lms/templates/index.html | 2 +- .../instructor/instructor_dashboard_2/add_coupon_modal.html | 2 +- .../instructor/instructor_dashboard_2/edit_coupon_modal.html | 2 +- .../generate_registarion_codes_modal.html | 2 +- .../instructor_dashboard_2/instructor_dashboard_2.html | 2 +- .../invalidate_registration_code_modal.html | 2 +- .../instructor_dashboard_2/set_course_mode_price_modal.html | 2 +- lms/templates/login-sidebar.html | 2 +- lms/templates/login.html | 2 +- lms/templates/main.html | 2 +- lms/templates/manage_user_standing.html | 2 +- lms/templates/modal/_modal-settings-language.html | 2 +- lms/templates/navigation/bootstrap/navbar-authenticated.html | 2 +- lms/templates/navigation/navbar-authenticated.html | 2 +- lms/templates/navigation/navbar-logo-header.html | 2 +- lms/templates/navigation/navbar-not-authenticated.html | 2 +- lms/templates/navigation/navigation.html | 2 +- lms/templates/notes.html | 2 +- lms/templates/provider/authorize.html | 2 +- lms/templates/register-shib.html | 2 +- lms/templates/register-sidebar.html | 2 +- lms/templates/register.html | 2 +- lms/templates/resubscribe.html | 2 +- lms/templates/shoppingcart/billing_details.html | 2 +- lms/templates/shoppingcart/download_report.html | 2 +- lms/templates/shoppingcart/error.html | 2 +- lms/templates/shoppingcart/receipt.html | 2 +- lms/templates/shoppingcart/registration_code_receipt.html | 2 +- lms/templates/shoppingcart/registration_code_redemption.html | 2 +- lms/templates/shoppingcart/shopping_cart.html | 2 +- lms/templates/signup_modal.html | 2 +- lms/templates/student_account/account_settings.html | 2 +- lms/templates/support/certificates.html | 2 +- lms/templates/support/contact_us.html | 2 +- lms/templates/support/index.html | 2 +- lms/templates/survey/survey.html | 2 +- lms/templates/sysadmin_dashboard.html | 2 +- lms/templates/sysadmin_dashboard_gitlogs.html | 2 +- lms/templates/unsubscribe.html | 2 +- lms/templates/user_dropdown.html | 2 +- lms/templates/verify_student/reverify_not_allowed.html | 2 +- lms/templates/wiki/includes/article_menu.html | 2 +- lms/templates/wiki/includes/breadcrumbs.html | 2 +- lms/tests.py | 2 +- openedx/core/djangoapps/ace_common/template_context.py | 2 +- openedx/core/djangoapps/api_admin/admin.py | 2 +- openedx/core/djangoapps/api_admin/decorators.py | 2 +- openedx/core/djangoapps/api_admin/models.py | 2 +- openedx/core/djangoapps/api_admin/tests/test_views.py | 2 +- openedx/core/djangoapps/api_admin/views.py | 2 +- openedx/core/djangoapps/api_admin/widgets.py | 2 +- openedx/core/djangoapps/auth_exchange/tests/test_views.py | 2 +- openedx/core/djangoapps/bookmarks/tests/test_views.py | 2 +- .../core/djangoapps/cache_toolbox/tests/test_middleware.py | 2 +- openedx/core/djangoapps/cors_csrf/tests/test_views.py | 2 +- openedx/core/djangoapps/course_groups/views.py | 2 +- openedx/core/djangoapps/credit/email_utils.py | 2 +- openedx/core/djangoapps/credit/tests/test_views.py | 2 +- openedx/core/djangoapps/embargo/middleware.py | 2 +- openedx/core/djangoapps/embargo/models.py | 2 +- openedx/core/djangoapps/embargo/test_utils.py | 2 +- openedx/core/djangoapps/embargo/tests/test_middleware.py | 2 +- openedx/core/djangoapps/embargo/tests/test_views.py | 2 +- openedx/core/djangoapps/external_auth/login_and_register.py | 2 +- .../djangoapps/external_auth/tests/test_openid_provider.py | 2 +- openedx/core/djangoapps/external_auth/tests/test_shib.py | 2 +- openedx/core/djangoapps/external_auth/tests/test_ssl.py | 2 +- openedx/core/djangoapps/external_auth/views.py | 2 +- openedx/core/djangoapps/heartbeat/tests/test_heartbeat.py | 2 +- openedx/core/djangoapps/lang_pref/tests/test_middleware.py | 2 +- openedx/core/djangoapps/lang_pref/tests/test_views.py | 2 +- .../oauth_dispatch/tests/test_client_credentials.py | 2 +- openedx/core/djangoapps/oauth_dispatch/tests/test_views.py | 2 +- openedx/core/djangoapps/oauth_dispatch/views.py | 2 +- openedx/core/djangoapps/profile_images/tests/test_views.py | 2 +- openedx/core/djangoapps/programs/tests/test_utils.py | 2 +- openedx/core/djangoapps/programs/utils.py | 2 +- openedx/core/djangoapps/schedules/admin.py | 2 +- openedx/core/djangoapps/schedules/resolvers.py | 2 +- openedx/core/djangoapps/service_status/test.py | 2 +- .../djangoapps/theming/tests/test_theme_style_overrides.py | 2 +- openedx/core/djangoapps/user_api/accounts/serializers.py | 2 +- openedx/core/djangoapps/user_api/accounts/tests/test_views.py | 2 +- openedx/core/djangoapps/user_api/api.py | 2 +- .../core/djangoapps/user_api/preferences/tests/test_views.py | 2 +- openedx/core/djangoapps/user_api/tests/test_views.py | 2 +- .../core/djangoapps/user_api/validation/tests/test_views.py | 2 +- .../djangoapps/user_api/verification_api/tests/test_views.py | 2 +- openedx/core/djangoapps/zendesk_proxy/tests/test_v0_views.py | 2 +- openedx/core/djangoapps/zendesk_proxy/tests/test_v1_views.py | 2 +- openedx/core/lib/gating/api.py | 2 +- .../xblock_discussion/xblock_discussion/__init__.py | 2 +- openedx/core/lib/xblock_utils/__init__.py | 2 +- openedx/features/course_bookmarks/plugins.py | 2 +- openedx/features/course_bookmarks/views/course_bookmarks.py | 2 +- openedx/features/course_experience/plugins.py | 2 +- .../templates/course_experience/course-home-fragment.html | 2 +- .../course_experience/tests/views/test_course_dates.py | 2 +- .../course_experience/tests/views/test_course_home.py | 2 +- .../course_experience/tests/views/test_course_outline.py | 2 +- .../course_experience/tests/views/test_course_updates.py | 2 +- .../course_experience/tests/views/test_welcome_message.py | 2 +- openedx/features/course_experience/views/course_home.py | 2 +- openedx/features/course_experience/views/course_reviews.py | 2 +- openedx/features/course_experience/views/course_updates.py | 2 +- openedx/features/course_experience/views/welcome_message.py | 2 +- .../templates/course_search/course-search-fragment.html | 2 +- openedx/features/course_search/views/course_search.py | 2 +- openedx/features/enterprise_support/api.py | 2 +- .../features/enterprise_support/tests/mixins/enterprise.py | 2 +- openedx/features/enterprise_support/tests/test_api.py | 2 +- openedx/features/enterprise_support/tests/test_middleware.py | 2 +- openedx/features/learner_analytics/views.py | 2 +- .../templates/learner_profile/learner_profile.html | 2 +- .../learner_profile/tests/views/test_learner_profile.py | 2 +- openedx/features/learner_profile/views/learner_profile.py | 2 +- openedx/tests/completion_integration/test_views.py | 2 +- openedx/tests/xblock_integration/test_crowdsource_hinter.py | 2 +- openedx/tests/xblock_integration/test_recommender.py | 2 +- openedx/tests/xblock_integration/test_review_xblock.py | 2 +- openedx/tests/xblock_integration/xblock_testcase.py | 2 +- themes/edx.org/cms/templates/widgets/sock.html | 2 +- themes/edx.org/lms/templates/course_modes/choose.html | 2 +- themes/edx.org/lms/templates/dashboard.html | 2 +- themes/edx.org/lms/templates/header/navbar-authenticated.html | 2 +- .../lms/templates/header/navbar-not-authenticated.html | 2 +- themes/red-theme/cms/templates/login.html | 2 +- themes/red-theme/lms/templates/footer.html | 2 +- themes/stanford-style/lms/templates/footer.html | 2 +- themes/stanford-style/lms/templates/register-shib.html | 2 +- themes/stanford-style/lms/templates/register-sidebar.html | 2 +- 402 files changed, 404 insertions(+), 405 deletions(-) diff --git a/cms/djangoapps/api/v1/tests/test_views/test_course_runs.py b/cms/djangoapps/api/v1/tests/test_views/test_course_runs.py index 62b09ccf7e1..61e18e77e6f 100644 --- a/cms/djangoapps/api/v1/tests/test_views/test_course_runs.py +++ b/cms/djangoapps/api/v1/tests/test_views/test_course_runs.py @@ -3,7 +3,7 @@ import datetime import ddt import pytz from django.core.files.uploadedfile import SimpleUploadedFile -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import RequestFactory from opaque_keys.edx.keys import CourseKey from openedx.core.lib.courses import course_image_url diff --git a/cms/djangoapps/cms_user_tasks/signals.py b/cms/djangoapps/cms_user_tasks/signals.py index 6640ab2a18d..f4761264dfc 100644 --- a/cms/djangoapps/cms_user_tasks/signals.py +++ b/cms/djangoapps/cms_user_tasks/signals.py @@ -5,7 +5,7 @@ from __future__ import absolute_import, print_function, unicode_literals import logging -from django.core.urlresolvers import reverse +from django.urls import reverse from django.dispatch import receiver from user_tasks.models import UserTaskArtifact from user_tasks.signals import user_task_stopped diff --git a/cms/djangoapps/cms_user_tasks/tests.py b/cms/djangoapps/cms_user_tasks/tests.py index 4672fc4915f..0ec1fb1d415 100644 --- a/cms/djangoapps/cms_user_tasks/tests.py +++ b/cms/djangoapps/cms_user_tasks/tests.py @@ -12,7 +12,7 @@ from boto.exception import NoAuthHandlerFound from django.conf import settings from django.contrib.auth.models import User from django.core import mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import override_settings from rest_framework.test import APITestCase from user_tasks.models import UserTaskArtifact, UserTaskStatus diff --git a/cms/djangoapps/contentstore/api/tests/test_views.py b/cms/djangoapps/contentstore/api/tests/test_views.py index 20a49a9751a..710663498d5 100644 --- a/cms/djangoapps/contentstore/api/tests/test_views.py +++ b/cms/djangoapps/contentstore/api/tests/test_views.py @@ -8,7 +8,7 @@ import tempfile from datetime import datetime from urllib import urlencode -from django.core.urlresolvers import reverse +from django.urls import reverse from path import Path as path from mock import patch from rest_framework import status diff --git a/cms/djangoapps/contentstore/courseware_index.py b/cms/djangoapps/contentstore/courseware_index.py index 29ad2487f5e..f5f67fc7cb2 100644 --- a/cms/djangoapps/contentstore/courseware_index.py +++ b/cms/djangoapps/contentstore/courseware_index.py @@ -7,7 +7,7 @@ from abc import ABCMeta, abstractmethod from datetime import timedelta from django.conf import settings -from django.core.urlresolvers import resolve +from django.urls import resolve from django.utils.translation import ugettext as _ from django.utils.translation import ugettext_lazy from search.search_engine_base import SearchEngine diff --git a/cms/djangoapps/contentstore/tests/test_course_create_rerun.py b/cms/djangoapps/contentstore/tests/test_course_create_rerun.py index 9912416c9c2..a1019fa40ae 100644 --- a/cms/djangoapps/contentstore/tests/test_course_create_rerun.py +++ b/cms/djangoapps/contentstore/tests/test_course_create_rerun.py @@ -4,7 +4,7 @@ Test view handler for rerun (and eventually create) from datetime import datetime import ddt -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from mock import patch from opaque_keys.edx.keys import CourseKey diff --git a/cms/djangoapps/contentstore/tests/test_request_event.py b/cms/djangoapps/contentstore/tests/test_request_event.py index 529fe4abb27..da0f0c7246f 100644 --- a/cms/djangoapps/contentstore/tests/test_request_event.py +++ b/cms/djangoapps/contentstore/tests/test_request_event.py @@ -1,6 +1,6 @@ """Tests for CMS's requests to logs""" import mock -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from contentstore.views.helpers import event as cms_user_track diff --git a/cms/djangoapps/contentstore/tests/tests.py b/cms/djangoapps/contentstore/tests/tests.py index b34d02fc21b..14fd564e1ee 100644 --- a/cms/djangoapps/contentstore/tests/tests.py +++ b/cms/djangoapps/contentstore/tests/tests.py @@ -11,7 +11,7 @@ from ddt import data, ddt, unpack from django.conf import settings from django.contrib.auth.models import User from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.utils import override_settings from freezegun import freeze_time diff --git a/cms/djangoapps/contentstore/utils.py b/cms/djangoapps/contentstore/utils.py index 70451ff0b44..e9f886605fb 100644 --- a/cms/djangoapps/contentstore/utils.py +++ b/cms/djangoapps/contentstore/utils.py @@ -6,7 +6,7 @@ import logging from datetime import datetime from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from opaque_keys.edx.keys import CourseKey, UsageKey from pytz import UTC diff --git a/cms/djangoapps/contentstore/views/course.py b/cms/djangoapps/contentstore/views/course.py index d88375b65a6..6e7833f9924 100644 --- a/cms/djangoapps/contentstore/views/course.py +++ b/cms/djangoapps/contentstore/views/course.py @@ -14,7 +14,7 @@ from ccx_keys.locator import CCXLocator from django.conf import settings from django.contrib.auth.decorators import login_required from django.core.exceptions import PermissionDenied, ValidationError -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404, HttpResponse, HttpResponseBadRequest, HttpResponseNotFound from django.shortcuts import redirect from django.utils.translation import ugettext as _ diff --git a/cms/djangoapps/contentstore/views/preview.py b/cms/djangoapps/contentstore/views/preview.py index a962ac450f3..0b2f0a297e9 100644 --- a/cms/djangoapps/contentstore/views/preview.py +++ b/cms/djangoapps/contentstore/views/preview.py @@ -5,7 +5,7 @@ from functools import partial from django.conf import settings from django.contrib.auth.decorators import login_required -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404, HttpResponseBadRequest from django.utils.translation import ugettext as _ from opaque_keys.edx.keys import UsageKey diff --git a/cms/djangoapps/contentstore/views/public.py b/cms/djangoapps/contentstore/views/public.py index 0a7e568ac7c..6306a11427e 100644 --- a/cms/djangoapps/contentstore/views/public.py +++ b/cms/djangoapps/contentstore/views/public.py @@ -3,7 +3,7 @@ Public views """ from django.conf import settings from django.template.context_processors import csrf -from django.core.urlresolvers import reverse +from django.urls import reverse from django.shortcuts import redirect from django.views.decorators.clickjacking import xframe_options_deny from django.views.decorators.csrf import ensure_csrf_cookie diff --git a/cms/djangoapps/contentstore/views/tests/test_item.py b/cms/djangoapps/contentstore/views/tests/test_item.py index ea7b8fcf7f5..9b979c94fd2 100644 --- a/cms/djangoapps/contentstore/views/tests/test_item.py +++ b/cms/djangoapps/contentstore/views/tests/test_item.py @@ -4,7 +4,7 @@ from datetime import datetime, timedelta import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404 from django.test import TestCase from django.test.client import RequestFactory diff --git a/cms/djangoapps/contentstore/views/tests/test_organizations.py b/cms/djangoapps/contentstore/views/tests/test_organizations.py index d8137a47d92..4a16f9f155b 100644 --- a/cms/djangoapps/contentstore/views/tests/test_organizations.py +++ b/cms/djangoapps/contentstore/views/tests/test_organizations.py @@ -1,7 +1,7 @@ """Tests covering the Organizations listing on the Studio home.""" import json -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from mock import patch diff --git a/cms/djangoapps/contentstore/views/tests/test_transcript_settings.py b/cms/djangoapps/contentstore/views/tests/test_transcript_settings.py index da838b18068..8d55c02bb9f 100644 --- a/cms/djangoapps/contentstore/views/tests/test_transcript_settings.py +++ b/cms/djangoapps/contentstore/views/tests/test_transcript_settings.py @@ -5,7 +5,7 @@ from io import BytesIO from mock import Mock, patch, ANY from django.test.testcases import TestCase -from django.core.urlresolvers import reverse +from django.urls import reverse from edxval import api from contentstore.tests.utils import CourseTestCase diff --git a/cms/djangoapps/contentstore/views/tests/test_transcripts.py b/cms/djangoapps/contentstore/views/tests/test_transcripts.py index 0fae175fd91..c47da48437d 100644 --- a/cms/djangoapps/contentstore/views/tests/test_transcripts.py +++ b/cms/djangoapps/contentstore/views/tests/test_transcripts.py @@ -10,7 +10,7 @@ import textwrap from uuid import uuid4 from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from edxval.api import create_video from opaque_keys.edx.keys import UsageKey diff --git a/cms/djangoapps/contentstore/views/videos.py b/cms/djangoapps/contentstore/views/videos.py index 4ed18809565..36df3f74cb9 100644 --- a/cms/djangoapps/contentstore/views/videos.py +++ b/cms/djangoapps/contentstore/views/videos.py @@ -15,7 +15,7 @@ from django.conf import settings from django.contrib.auth.decorators import login_required from django.contrib.staticfiles.storage import staticfiles_storage from django.core.files.images import get_image_dimensions -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpResponse, HttpResponseNotFound from django.utils.translation import ugettext as _ from django.utils.translation import ugettext_noop diff --git a/cms/djangoapps/course_creators/tests/test_views.py b/cms/djangoapps/course_creators/tests/test_views.py index fa951643cdd..6169f60ef33 100644 --- a/cms/djangoapps/course_creators/tests/test_views.py +++ b/cms/djangoapps/course_creators/tests/test_views.py @@ -5,7 +5,7 @@ Tests course_creators.views.py. import mock from django.contrib.auth.models import User from django.core.exceptions import PermissionDenied -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from course_creators.views import ( diff --git a/cms/djangoapps/maintenance/tests.py b/cms/djangoapps/maintenance/tests.py index ada62740500..981f1b2c702 100644 --- a/cms/djangoapps/maintenance/tests.py +++ b/cms/djangoapps/maintenance/tests.py @@ -5,7 +5,7 @@ import json import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from contentstore.management.commands.utils import get_course_versions from student.tests.factories import AdminFactory, UserFactory diff --git a/cms/lib/xblock/runtime.py b/cms/lib/xblock/runtime.py index 299f81b0367..53d2c08bb83 100644 --- a/cms/lib/xblock/runtime.py +++ b/cms/lib/xblock/runtime.py @@ -2,7 +2,7 @@ XBlock runtime implementations for edX Studio """ -from django.core.urlresolvers import reverse +from django.urls import reverse def handler_url(block, handler_name, suffix='', query='', thirdparty=False): diff --git a/cms/templates/accessibility.html b/cms/templates/accessibility.html index 80f4a421a79..07e30120ac8 100644 --- a/cms/templates/accessibility.html +++ b/cms/templates/accessibility.html @@ -2,7 +2,7 @@ <%inherit file="base.html" /> <%def name="online_help_token()"><% return "accessibility" %></%def> <%! - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangolib.markup import HTML, Text from openedx.core.djangolib.js_utils import js_escaped_string, dump_js_escaped_json diff --git a/cms/templates/asset_index.html b/cms/templates/asset_index.html index 5777b86bdaf..b68e1fbd3b0 100644 --- a/cms/templates/asset_index.html +++ b/cms/templates/asset_index.html @@ -2,7 +2,7 @@ <%inherit file="base.html" /> <%def name="online_help_token()"><% return "files" %></%def> <%! - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangolib.markup import HTML, Text from openedx.core.djangolib.js_utils import js_escaped_string, dump_js_escaped_json diff --git a/cms/templates/course-create-rerun.html b/cms/templates/course-create-rerun.html index 300153bde85..c8114a56a9d 100644 --- a/cms/templates/course-create-rerun.html +++ b/cms/templates/course-create-rerun.html @@ -3,7 +3,7 @@ <%def name="online_help_token()"><% return "course_rerun" %></%def> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.js_utils import js_escaped_string %> diff --git a/cms/templates/edit-tabs.html b/cms/templates/edit-tabs.html index 9541f07c35b..c356155f6df 100644 --- a/cms/templates/edit-tabs.html +++ b/cms/templates/edit-tabs.html @@ -4,7 +4,7 @@ <%namespace name='static' file='static_content.html'/> <%! from django.utils.translation import ugettext as _ - from django.core.urlresolvers import reverse + from django.urls import reverse from xmodule.tabs import StaticTab from openedx.core.djangolib.js_utils import js_escaped_string %> diff --git a/cms/templates/error.html b/cms/templates/error.html index 87df8232bdd..25aed65f884 100644 --- a/cms/templates/error.html +++ b/cms/templates/error.html @@ -2,7 +2,7 @@ <%inherit file="base.html" /> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.conf import settings %> <%block name="bodyclass">error</%block> diff --git a/cms/templates/export_git.html b/cms/templates/export_git.html index 584cb2270dc..65c8c3e08bc 100644 --- a/cms/templates/export_git.html +++ b/cms/templates/export_git.html @@ -3,7 +3,7 @@ <%namespace name='static' file='static_content.html'/> <%! - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ %> <%block name="title">${_("Export Course to Git")}</%block> diff --git a/cms/templates/howitworks.html b/cms/templates/howitworks.html index f1b9ad88ac4..0e0349a755a 100644 --- a/cms/templates/howitworks.html +++ b/cms/templates/howitworks.html @@ -3,7 +3,7 @@ <%def name="online_help_token()"><% return "welcome" %></%def> <%namespace name='static' file='static_content.html'/> <%! - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangolib.markup import HTML, Text %> diff --git a/cms/templates/html_error.html b/cms/templates/html_error.html index 6b80a6a1ff5..5cf980d73d3 100644 --- a/cms/templates/html_error.html +++ b/cms/templates/html_error.html @@ -1,5 +1,5 @@ <%! from django.utils.translation import ugettext as _ %> -<%! from django.core.urlresolvers import reverse %> +<%! from django.urls import reverse %> <%block name="content"> <div class="wrapper wrapper-alert wrapper-alert-error is-shown"> diff --git a/cms/templates/login.html b/cms/templates/login.html index c4966f8b669..7b980cee2fe 100644 --- a/cms/templates/login.html +++ b/cms/templates/login.html @@ -3,7 +3,7 @@ <%inherit file="base.html" /> <%def name="online_help_token()"><% return "login" %></%def> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangolib.js_utils import js_escaped_string %> diff --git a/cms/templates/maintenance/base.html b/cms/templates/maintenance/base.html index d0691063c2d..867e6e8c17d 100644 --- a/cms/templates/maintenance/base.html +++ b/cms/templates/maintenance/base.html @@ -3,7 +3,7 @@ <%def name='online_help_token()'><% return 'maintenance' %></%def> <%namespace name='static' file='../static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> <%block name="content"> diff --git a/cms/templates/maintenance/container.html b/cms/templates/maintenance/container.html index c72f6b00e47..417471a1bd6 100644 --- a/cms/templates/maintenance/container.html +++ b/cms/templates/maintenance/container.html @@ -2,7 +2,7 @@ <%inherit file="base.html" /> <%namespace name='static' file='../static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.js_utils import js_escaped_string %> <%block name="title">${view['name']}</%block> diff --git a/cms/templates/maintenance/index.html b/cms/templates/maintenance/index.html index f1f3224fe17..41c84223d2f 100644 --- a/cms/templates/maintenance/index.html +++ b/cms/templates/maintenance/index.html @@ -3,7 +3,7 @@ <%namespace name='static' file='../static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%block name="title">${_('Maintenance Dashboard')}</%block> <%block name="viewcontent"> diff --git a/cms/templates/manage_users.html b/cms/templates/manage_users.html index 858e66f33e6..50b7a9e3df4 100644 --- a/cms/templates/manage_users.html +++ b/cms/templates/manage_users.html @@ -1,7 +1,7 @@ <%inherit file="base.html" /> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.js_utils import ( dump_js_escaped_json, js_escaped_string diff --git a/cms/templates/manage_users_lib.html b/cms/templates/manage_users_lib.html index db5fb303dcf..4d9e4e1aa2c 100644 --- a/cms/templates/manage_users_lib.html +++ b/cms/templates/manage_users_lib.html @@ -1,7 +1,7 @@ <%inherit file="base.html" /> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.js_utils import ( dump_js_escaped_json, js_escaped_string diff --git a/cms/templates/register.html b/cms/templates/register.html index 86f639056e8..3af9949bb61 100644 --- a/cms/templates/register.html +++ b/cms/templates/register.html @@ -2,7 +2,7 @@ <%def name="online_help_token()"><% return "register" %></%def> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%block name="title">${_("Sign Up")}</%block> diff --git a/cms/templates/registration/activation_complete.html b/cms/templates/registration/activation_complete.html index f3bc1d68c86..86592dded3b 100644 --- a/cms/templates/registration/activation_complete.html +++ b/cms/templates/registration/activation_complete.html @@ -1,7 +1,7 @@ <%inherit file="../base.html" /> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%namespace name='static' file='../static_content.html'/> diff --git a/cms/templates/registration/activation_invalid.html b/cms/templates/registration/activation_invalid.html index 5160b46449e..27bd7533432 100644 --- a/cms/templates/registration/activation_invalid.html +++ b/cms/templates/registration/activation_invalid.html @@ -3,7 +3,7 @@ <%namespace name='static' file='../static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.markup import HTML, Text %> diff --git a/cms/templates/widgets/footer.html b/cms/templates/widgets/footer.html index a48fbdd9a38..53a96538f2f 100644 --- a/cms/templates/widgets/footer.html +++ b/cms/templates/widgets/footer.html @@ -1,6 +1,6 @@ <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from datetime import datetime from django.conf import settings import pytz diff --git a/cms/templates/widgets/header.html b/cms/templates/widgets/header.html index 512078e088d..8fcf07ceb5a 100644 --- a/cms/templates/widgets/header.html +++ b/cms/templates/widgets/header.html @@ -2,7 +2,7 @@ <%namespace name='static' file='../static_content.html'/> <%! from django.conf import settings - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangoapps.lang_pref.api import header_language_selector_is_enabled, released_languages %> diff --git a/cms/templates/widgets/user_dropdown.html b/cms/templates/widgets/user_dropdown.html index 773c43d5e04..d39d1ac4e2e 100644 --- a/cms/templates/widgets/user_dropdown.html +++ b/cms/templates/widgets/user_dropdown.html @@ -2,7 +2,7 @@ <%namespace name='static' file='../static_content.html'/> <%! from django.conf import settings - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ from student.roles import GlobalStaff %> @@ -57,4 +57,4 @@ </ul> </div> </div> -% endif \ No newline at end of file +% endif diff --git a/common/djangoapps/course_modes/tests/test_admin.py b/common/djangoapps/course_modes/tests/test_admin.py index 7bd230e7cb0..0827c5b2582 100644 --- a/common/djangoapps/course_modes/tests/test_admin.py +++ b/common/djangoapps/course_modes/tests/test_admin.py @@ -6,7 +6,7 @@ from datetime import datetime, timedelta import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from pytz import UTC, timezone from course_modes.admin import CourseModeForm diff --git a/common/djangoapps/course_modes/tests/test_views.py b/common/djangoapps/course_modes/tests/test_views.py index 4a576c3776e..b2a9979f55b 100644 --- a/common/djangoapps/course_modes/tests/test_views.py +++ b/common/djangoapps/course_modes/tests/test_views.py @@ -11,7 +11,7 @@ import freezegun import httpretty import pytz from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import patch from nose.plugins.attrib import attr diff --git a/common/djangoapps/course_modes/views.py b/common/djangoapps/course_modes/views.py index 00a50ed8b49..0943493a521 100644 --- a/common/djangoapps/course_modes/views.py +++ b/common/djangoapps/course_modes/views.py @@ -9,7 +9,7 @@ import urllib import waffle from babel.dates import format_datetime from django.contrib.auth.decorators import login_required -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import transaction from django.http import HttpResponse, HttpResponseBadRequest from django.shortcuts import redirect diff --git a/common/djangoapps/edxmako/shortcuts.py b/common/djangoapps/edxmako/shortcuts.py index f8045347e38..d187cd35408 100644 --- a/common/djangoapps/edxmako/shortcuts.py +++ b/common/djangoapps/edxmako/shortcuts.py @@ -16,7 +16,7 @@ import logging from urlparse import urljoin from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpResponse from django.template import engines diff --git a/common/djangoapps/edxmako/tests.py b/common/djangoapps/edxmako/tests.py index 6406b0f563b..23e30657051 100644 --- a/common/djangoapps/edxmako/tests.py +++ b/common/djangoapps/edxmako/tests.py @@ -2,7 +2,7 @@ import unittest import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpResponse from django.test import TestCase from django.test.client import RequestFactory diff --git a/common/djangoapps/enrollment/tests/test_views.py b/common/djangoapps/enrollment/tests/test_views.py index e1c91c04736..ef50c57b1d0 100644 --- a/common/djangoapps/enrollment/tests/test_views.py +++ b/common/djangoapps/enrollment/tests/test_views.py @@ -13,7 +13,7 @@ from django.conf import settings from django.core.cache import cache from django.core.exceptions import ImproperlyConfigured from django.core.handlers.wsgi import WSGIRequest -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import Client from django.test.utils import override_settings from mock import patch diff --git a/common/djangoapps/entitlements/api/v1/tests/test_views.py b/common/djangoapps/entitlements/api/v1/tests/test_views.py index 4423f933340..0135aa72644 100644 --- a/common/djangoapps/entitlements/api/v1/tests/test_views.py +++ b/common/djangoapps/entitlements/api/v1/tests/test_views.py @@ -8,7 +8,7 @@ from courseware.models import ( DynamicUpgradeDeadlineConfiguration ) from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.timezone import now from mock import patch from opaque_keys.edx.locator import CourseKey diff --git a/common/djangoapps/microsite_configuration/tests/backends/test_filebased.py b/common/djangoapps/microsite_configuration/tests/backends/test_filebased.py index c1d978fd254..a7d169a1891 100644 --- a/common/djangoapps/microsite_configuration/tests/backends/test_filebased.py +++ b/common/djangoapps/microsite_configuration/tests/backends/test_filebased.py @@ -6,7 +6,7 @@ from mock import patch from django.test import TestCase from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from microsite_configuration.backends.base import ( BaseMicrositeBackend, diff --git a/common/djangoapps/student/cookies.py b/common/djangoapps/student/cookies.py index a2103877e10..c064a3daf04 100644 --- a/common/djangoapps/student/cookies.py +++ b/common/djangoapps/student/cookies.py @@ -9,7 +9,7 @@ import time import six from django.conf import settings from django.contrib.auth.models import User -from django.core.urlresolvers import NoReverseMatch, reverse +from django.urls import NoReverseMatch, reverse from django.dispatch import Signal from django.utils.http import cookie_date diff --git a/common/djangoapps/student/forms.py b/common/djangoapps/student/forms.py index a5c9054dcc4..82a43053834 100644 --- a/common/djangoapps/student/forms.py +++ b/common/djangoapps/student/forms.py @@ -12,7 +12,7 @@ from django.contrib.auth.models import User from django.contrib.auth.tokens import default_token_generator from django.contrib.sites.models import Site from django.core.exceptions import ValidationError -from django.core.urlresolvers import reverse +from django.urls import reverse from django.core.validators import RegexValidator, slug_re from django.forms import widgets from django.utils.http import int_to_base36 diff --git a/common/djangoapps/student/helpers.py b/common/djangoapps/student/helpers.py index 32f98e6dd2e..b31651acad5 100644 --- a/common/djangoapps/student/helpers.py +++ b/common/djangoapps/student/helpers.py @@ -11,7 +11,7 @@ from datetime import datetime import django from django.conf import settings from django.core.exceptions import PermissionDenied -from django.core.urlresolvers import NoReverseMatch, reverse +from django.urls import NoReverseMatch, reverse from django.core.validators import ValidationError from django.contrib.auth import load_backend from django.contrib.auth.models import User diff --git a/common/djangoapps/student/tests/test_activate_account.py b/common/djangoapps/student/tests/test_activate_account.py index e32f6c78b4e..099516b53a4 100644 --- a/common/djangoapps/student/tests/test_activate_account.py +++ b/common/djangoapps/student/tests/test_activate_account.py @@ -3,7 +3,7 @@ import unittest from uuid import uuid4 from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase, override_settings from mock import patch diff --git a/common/djangoapps/student/tests/test_admin_views.py b/common/djangoapps/student/tests/test_admin_views.py index 0ee14a5691c..bd52275dcd9 100644 --- a/common/djangoapps/student/tests/test_admin_views.py +++ b/common/djangoapps/student/tests/test_admin_views.py @@ -3,7 +3,7 @@ Tests student admin.py """ from django.contrib.admin.sites import AdminSite from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from mock import Mock diff --git a/common/djangoapps/student/tests/test_bulk_email_settings.py b/common/djangoapps/student/tests/test_bulk_email_settings.py index 3f7fad07d57..43d9c6268f1 100644 --- a/common/djangoapps/student/tests/test_bulk_email_settings.py +++ b/common/djangoapps/student/tests/test_bulk_email_settings.py @@ -7,7 +7,7 @@ Course Auth is turned on. import unittest from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse # This import is for an lms djangoapp. # Its testcases are only run under lms. diff --git a/common/djangoapps/student/tests/test_certificates.py b/common/djangoapps/student/tests/test_certificates.py index 64485634dc6..d6a1260244a 100644 --- a/common/djangoapps/student/tests/test_certificates.py +++ b/common/djangoapps/student/tests/test_certificates.py @@ -6,7 +6,7 @@ import datetime import ddt import mock from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from mock import patch from pytz import UTC diff --git a/common/djangoapps/student/tests/test_configuration_overrides.py b/common/djangoapps/student/tests/test_configuration_overrides.py index 01fefe3a09c..6ce67ec1c76 100644 --- a/common/djangoapps/student/tests/test_configuration_overrides.py +++ b/common/djangoapps/student/tests/test_configuration_overrides.py @@ -5,7 +5,7 @@ import json import mock from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from student.models import UserSignupSource diff --git a/common/djangoapps/student/tests/test_cookies.py b/common/djangoapps/student/tests/test_cookies.py index 20577a91a12..0479fa5fbe5 100644 --- a/common/djangoapps/student/tests/test_cookies.py +++ b/common/djangoapps/student/tests/test_cookies.py @@ -3,7 +3,7 @@ from __future__ import unicode_literals import six from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import RequestFactory from openedx.core.djangoapps.user_api.accounts.utils import retrieve_last_sitewide_block_completed diff --git a/common/djangoapps/student/tests/test_create_account.py b/common/djangoapps/student/tests/test_create_account.py index 8a531f2bcfe..a1c235ecba7 100644 --- a/common/djangoapps/student/tests/test_create_account.py +++ b/common/djangoapps/student/tests/test_create_account.py @@ -10,7 +10,7 @@ import mock import pytz from django.conf import settings from django.contrib.auth.models import AnonymousUser, User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase, TransactionTestCase from django.test.client import RequestFactory from django.test.utils import override_settings diff --git a/common/djangoapps/student/tests/test_credit.py b/common/djangoapps/student/tests/test_credit.py index 68a45ffa698..ad47f09dfa0 100644 --- a/common/djangoapps/student/tests/test_credit.py +++ b/common/djangoapps/student/tests/test_credit.py @@ -7,7 +7,7 @@ import unittest import ddt import pytz from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from mock import patch diff --git a/common/djangoapps/student/tests/test_email.py b/common/djangoapps/student/tests/test_email.py index fdff0ea4af0..38824a1f47e 100644 --- a/common/djangoapps/student/tests/test_email.py +++ b/common/djangoapps/student/tests/test_email.py @@ -5,7 +5,7 @@ import unittest from django.conf import settings from django.contrib.auth.models import User from django.core import mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import transaction from django.http import HttpResponse from django.test import override_settings, TransactionTestCase diff --git a/common/djangoapps/student/tests/test_enrollment.py b/common/djangoapps/student/tests/test_enrollment.py index ed69ffec104..da8f26be6d7 100644 --- a/common/djangoapps/student/tests/test_enrollment.py +++ b/common/djangoapps/student/tests/test_enrollment.py @@ -5,7 +5,7 @@ import unittest import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import patch from nose.plugins.attrib import attr diff --git a/common/djangoapps/student/tests/test_helpers.py b/common/djangoapps/student/tests/test_helpers.py index c366a3262eb..a8aec32f0ff 100644 --- a/common/djangoapps/student/tests/test_helpers.py +++ b/common/djangoapps/student/tests/test_helpers.py @@ -5,7 +5,7 @@ import logging import ddt from django.conf import settings from django.contrib.sessions.middleware import SessionMiddleware -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.client import RequestFactory from django.test.utils import override_settings diff --git a/common/djangoapps/student/tests/test_login.py b/common/djangoapps/student/tests/test_login.py index 9da1e8cbd90..089cbb15af2 100644 --- a/common/djangoapps/student/tests/test_login.py +++ b/common/djangoapps/student/tests/test_login.py @@ -8,7 +8,7 @@ import httpretty from django.conf import settings from django.contrib.auth.models import User from django.core.cache import cache -from django.core.urlresolvers import NoReverseMatch, reverse +from django.urls import NoReverseMatch, reverse from django.http import HttpResponse, HttpResponseBadRequest from django.test import TestCase from django.test.client import Client diff --git a/common/djangoapps/student/tests/test_login_registration_forms.py b/common/djangoapps/student/tests/test_login_registration_forms.py index 3ddd0ed402b..842525af1b8 100644 --- a/common/djangoapps/student/tests/test_login_registration_forms.py +++ b/common/djangoapps/student/tests/test_login_registration_forms.py @@ -4,7 +4,7 @@ import urllib import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import patch from third_party_auth.tests.testutil import ThirdPartyAuthTestMixin diff --git a/common/djangoapps/student/tests/test_long_username_email.py b/common/djangoapps/student/tests/test_long_username_email.py index 73ffd882dc4..094a5fe1cf4 100644 --- a/common/djangoapps/student/tests/test_long_username_email.py +++ b/common/djangoapps/student/tests/test_long_username_email.py @@ -2,7 +2,7 @@ import json -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from openedx.core.djangoapps.user_api.accounts import USERNAME_BAD_LENGTH_MSG diff --git a/common/djangoapps/student/tests/test_password_policy.py b/common/djangoapps/student/tests/test_password_policy.py index a6691d740db..00e67648cb7 100644 --- a/common/djangoapps/student/tests/test_password_policy.py +++ b/common/djangoapps/student/tests/test_password_policy.py @@ -7,7 +7,7 @@ from importlib import import_module from django.conf import settings from django.contrib.auth.models import AnonymousUser -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.client import RequestFactory from django.test.utils import override_settings diff --git a/common/djangoapps/student/tests/test_recent_enrollments.py b/common/djangoapps/student/tests/test_recent_enrollments.py index 8050992cbd6..52e85d1924f 100644 --- a/common/djangoapps/student/tests/test_recent_enrollments.py +++ b/common/djangoapps/student/tests/test_recent_enrollments.py @@ -6,7 +6,7 @@ import unittest import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.timezone import now from nose.plugins.attrib import attr from opaque_keys.edx import locator diff --git a/common/djangoapps/student/tests/test_refunds.py b/common/djangoapps/student/tests/test_refunds.py index ee10756a0b3..033c6397e3e 100644 --- a/common/djangoapps/student/tests/test_refunds.py +++ b/common/djangoapps/student/tests/test_refunds.py @@ -11,7 +11,7 @@ import pytz # Explicitly import the cache from ConfigurationModel so we can reset it after each test from config_models.models import cache from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import Client from django.test.utils import override_settings from mock import patch diff --git a/common/djangoapps/student/tests/test_reset_password.py b/common/djangoapps/student/tests/test_reset_password.py index 1c80cd6a78a..77ad5c00758 100644 --- a/common/djangoapps/student/tests/test_reset_password.py +++ b/common/djangoapps/student/tests/test_reset_password.py @@ -12,7 +12,7 @@ from django.contrib.auth.models import User from django.contrib.auth.tokens import default_token_generator from django.core.cache import cache from django.core import mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from django.test.utils import override_settings from django.utils.http import int_to_base36 diff --git a/common/djangoapps/student/tests/test_retirement.py b/common/djangoapps/student/tests/test_retirement.py index 3f5e28e597a..73e9a52f943 100644 --- a/common/djangoapps/student/tests/test_retirement.py +++ b/common/djangoapps/student/tests/test_retirement.py @@ -7,7 +7,7 @@ import ddt from django.apps import apps from django.conf import settings from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase import pytest diff --git a/common/djangoapps/student/tests/test_userstanding.py b/common/djangoapps/student/tests/test_userstanding.py index 011019dfc0b..03a4328d067 100644 --- a/common/djangoapps/student/tests/test_userstanding.py +++ b/common/djangoapps/student/tests/test_userstanding.py @@ -5,7 +5,7 @@ that students with disabled accounts are unable to access the courseware. import unittest from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import Client, TestCase from student.models import UserStanding diff --git a/common/djangoapps/student/tests/test_verification_status.py b/common/djangoapps/student/tests/test_verification_status.py index f320be7aa23..57da86a9710 100644 --- a/common/djangoapps/student/tests/test_verification_status.py +++ b/common/djangoapps/student/tests/test_verification_status.py @@ -4,7 +4,7 @@ from datetime import datetime, timedelta import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import override_settings from mock import patch from nose.plugins.attrib import attr diff --git a/common/djangoapps/student/tests/test_views.py b/common/djangoapps/student/tests/test_views.py index 6a47a230d9b..7f1c1d400a6 100644 --- a/common/djangoapps/student/tests/test_views.py +++ b/common/djangoapps/student/tests/test_views.py @@ -10,7 +10,7 @@ from datetime import timedelta import ddt from completion.test_utils import submit_completions_for_testing, CompletionWaffleTestMixin from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import RequestFactory, TestCase from django.test.utils import override_settings from django.utils.timezone import now diff --git a/common/djangoapps/student/tests/tests.py b/common/djangoapps/student/tests/tests.py index 0a8c3e27dbc..3255ec723e8 100644 --- a/common/djangoapps/student/tests/tests.py +++ b/common/djangoapps/student/tests/tests.py @@ -12,7 +12,7 @@ import pytz from config_models.models import cache from django.conf import settings from django.contrib.auth.models import AnonymousUser, User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase, override_settings from django.test.client import Client from markupsafe import escape diff --git a/common/djangoapps/student/views/dashboard.py b/common/djangoapps/student/views/dashboard.py index cc7d42ef0b8..27e89f6a7ae 100644 --- a/common/djangoapps/student/views/dashboard.py +++ b/common/djangoapps/student/views/dashboard.py @@ -11,7 +11,7 @@ from completion.utilities import get_key_to_last_completed_course_block from django.conf import settings from django.contrib import messages from django.contrib.auth.decorators import login_required -from django.core.urlresolvers import reverse +from django.urls import reverse from django.shortcuts import redirect from django.utils.translation import ugettext as _ from django.views.decorators.csrf import ensure_csrf_cookie diff --git a/common/djangoapps/student/views/login.py b/common/djangoapps/student/views/login.py index 960a6a0440a..30a50be2110 100644 --- a/common/djangoapps/student/views/login.py +++ b/common/djangoapps/student/views/login.py @@ -18,7 +18,7 @@ from django.contrib.auth import authenticate, load_backend, login as django_logi from django.contrib.auth.decorators import login_required from django.contrib.auth.models import AnonymousUser, User from django.core.exceptions import ObjectDoesNotExist, PermissionDenied -from django.core.urlresolvers import NoReverseMatch, reverse, reverse_lazy +from django.urls import NoReverseMatch, reverse, reverse_lazy from django.core.validators import ValidationError, validate_email from django.http import Http404, HttpResponse, HttpResponseBadRequest, HttpResponseForbidden from django.shortcuts import redirect diff --git a/common/djangoapps/student/views/management.py b/common/djangoapps/student/views/management.py index 98199bab1a5..3e3f03995e7 100644 --- a/common/djangoapps/student/views/management.py +++ b/common/djangoapps/student/views/management.py @@ -20,7 +20,7 @@ from django.contrib.auth.decorators import login_required from django.contrib.auth.models import AnonymousUser, User from django.contrib.auth.views import password_reset_confirm from django.core import mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.core.validators import ValidationError, validate_email from django.db import transaction from django.db.models.signals import post_save diff --git a/common/djangoapps/third_party_auth/admin.py b/common/djangoapps/third_party_auth/admin.py index f6ebab7a473..703196e19e2 100644 --- a/common/djangoapps/third_party_auth/admin.py +++ b/common/djangoapps/third_party_auth/admin.py @@ -5,7 +5,7 @@ Admin site configuration for third party authentication from config_models.admin import KeyedConfigurationModelAdmin from django import forms from django.contrib import admin -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import DatabaseError, transaction from django.utils.translation import ugettext_lazy as _ diff --git a/common/djangoapps/third_party_auth/api/tests/test_views.py b/common/djangoapps/third_party_auth/api/tests/test_views.py index fa58a97f4f1..6dd5367eaaf 100644 --- a/common/djangoapps/third_party_auth/api/tests/test_views.py +++ b/common/djangoapps/third_party_auth/api/tests/test_views.py @@ -5,7 +5,7 @@ Tests for the Third Party Auth REST API import unittest import ddt -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import QueryDict from mock import patch from provider.constants import CONFIDENTIAL diff --git a/common/djangoapps/third_party_auth/decorators.py b/common/djangoapps/third_party_auth/decorators.py index 5f0f3e6b40e..c897004a957 100644 --- a/common/djangoapps/third_party_auth/decorators.py +++ b/common/djangoapps/third_party_auth/decorators.py @@ -4,7 +4,6 @@ Decorators that can be used to interact with third_party_auth. from functools import wraps from django.conf import settings -from django.core.urlresolvers import reverse from django.shortcuts import redirect from django.utils.decorators import available_attrs diff --git a/common/djangoapps/third_party_auth/pipeline.py b/common/djangoapps/third_party_auth/pipeline.py index da5875cf6d7..444db04c186 100644 --- a/common/djangoapps/third_party_auth/pipeline.py +++ b/common/djangoapps/third_party_auth/pipeline.py @@ -70,7 +70,7 @@ import analytics from django.conf import settings from django.contrib.auth.models import User from django.core.mail.message import EmailMessage -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpResponseBadRequest from django.shortcuts import redirect import social_django diff --git a/common/djangoapps/third_party_auth/tests/specs/base.py b/common/djangoapps/third_party_auth/tests/specs/base.py index ee22535ae3a..2842c56fa04 100644 --- a/common/djangoapps/third_party_auth/tests/specs/base.py +++ b/common/djangoapps/third_party_auth/tests/specs/base.py @@ -14,7 +14,7 @@ from django.contrib import auth from django.contrib.auth import models as auth_models from django.contrib.messages.storage import fallback from django.contrib.sessions.backends import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import utils as django_utils from django.conf import settings as django_settings from social_core import actions, exceptions diff --git a/common/djangoapps/third_party_auth/tests/specs/test_google.py b/common/djangoapps/third_party_auth/tests/specs/test_google.py index cd9666a05b6..cb66121dc03 100644 --- a/common/djangoapps/third_party_auth/tests/specs/test_google.py +++ b/common/djangoapps/third_party_auth/tests/specs/test_google.py @@ -3,7 +3,7 @@ import base64 import hashlib import hmac from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse import json from mock import patch from openedx.tests.util import expected_redirect_url diff --git a/common/djangoapps/third_party_auth/tests/specs/test_lti.py b/common/djangoapps/third_party_auth/tests/specs/test_lti.py index e09428bc307..08390afefb7 100644 --- a/common/djangoapps/third_party_auth/tests/specs/test_lti.py +++ b/common/djangoapps/third_party_auth/tests/specs/test_lti.py @@ -5,7 +5,7 @@ import unittest import django from django.conf import settings from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from oauthlib.oauth1.rfc5849 import Client, SIGNATURE_TYPE_BODY from openedx.tests.util import expected_redirect_url from third_party_auth.tests import testutil diff --git a/common/djangoapps/third_party_auth/tests/test_admin.py b/common/djangoapps/third_party_auth/tests/test_admin.py index c16bbe8ed80..32fe1377c80 100644 --- a/common/djangoapps/third_party_auth/tests/test_admin.py +++ b/common/djangoapps/third_party_auth/tests/test_admin.py @@ -5,7 +5,7 @@ import unittest from django.contrib.admin.sites import AdminSite from django.core.files.uploadedfile import SimpleUploadedFile -from django.core.urlresolvers import reverse +from django.urls import reverse from django.forms import models from student.tests.factories import UserFactory diff --git a/common/djangoapps/third_party_auth/views.py b/common/djangoapps/third_party_auth/views.py index 2324d1539cc..4360bef5ada 100644 --- a/common/djangoapps/third_party_auth/views.py +++ b/common/djangoapps/third_party_auth/views.py @@ -2,7 +2,7 @@ Extra views required for SSO """ from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404, HttpResponse, HttpResponseNotAllowed, HttpResponseServerError from django.shortcuts import redirect, render from django.views.decorators.csrf import csrf_exempt diff --git a/common/djangoapps/track/tests/test_logs.py b/common/djangoapps/track/tests/test_logs.py index 3b66a453299..b6d6acd7305 100644 --- a/common/djangoapps/track/tests/test_logs.py +++ b/common/djangoapps/track/tests/test_logs.py @@ -3,7 +3,7 @@ import unittest import mock from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from track.models import TrackingLog diff --git a/common/djangoapps/util/testing.py b/common/djangoapps/util/testing.py index e179497e50a..8113e499a33 100644 --- a/common/djangoapps/util/testing.py +++ b/common/djangoapps/util/testing.py @@ -6,7 +6,7 @@ import json import sys from django.conf import settings -from django.core.urlresolvers import clear_url_caches, resolve +from django.urls import clear_url_caches, resolve from django.test import TestCase from mock import patch diff --git a/common/djangoapps/util/url.py b/common/djangoapps/util/url.py index 38d6f350128..e8ece69c668 100644 --- a/common/djangoapps/util/url.py +++ b/common/djangoapps/util/url.py @@ -6,7 +6,7 @@ import sys from importlib import import_module from django.conf import settings -from django.core.urlresolvers import set_urlconf +from django.urls import set_urlconf def reload_django_url_config(): diff --git a/common/test/test-theme/cms/templates/login.html b/common/test/test-theme/cms/templates/login.html index 4e13b5cdc9e..4617c1e3b46 100644 --- a/common/test/test-theme/cms/templates/login.html +++ b/common/test/test-theme/cms/templates/login.html @@ -4,7 +4,7 @@ <%inherit file="base.html" /> <%def name="online_help_token()"><% return "login" %></%def> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangolib.js_utils import js_escaped_string %> diff --git a/common/test/test_sites/test_site/templates/courseware/tabs.html b/common/test/test_sites/test_site/templates/courseware/tabs.html index 2597ca2db92..8077ba73f06 100644 --- a/common/test/test_sites/test_site/templates/courseware/tabs.html +++ b/common/test/test_sites/test_site/templates/courseware/tabs.html @@ -2,7 +2,7 @@ <%namespace name='static' file='/static_content.html'/> <%! from django.utils.translation import ugettext as _ - from django.core.urlresolvers import reverse + from django.urls import reverse %> <%page args="tab_list, active_page, default_tab, tab_image" expression_filter="h" /> diff --git a/common/test/test_sites/test_site/templates/emails/confirm_email_change.txt b/common/test/test_sites/test_site/templates/emails/confirm_email_change.txt index 8886280c30c..50ddb809275 100644 --- a/common/test/test_sites/test_site/templates/emails/confirm_email_change.txt +++ b/common/test/test_sites/test_site/templates/emails/confirm_email_change.txt @@ -1,4 +1,4 @@ -<%! from django.core.urlresolvers import reverse %> +<%! from django.urls import reverse %> <%! from django.conf import settings %> <%! from edxmako.shortcuts import render_to_string, marketing_link %> diff --git a/common/test/test_sites/test_site/templates/footer.html b/common/test/test_sites/test_site/templates/footer.html index 06c4072c77d..45194e2067a 100644 --- a/common/test/test_sites/test_site/templates/footer.html +++ b/common/test/test_sites/test_site/templates/footer.html @@ -2,7 +2,7 @@ <%page expression_filter="h"/> <%namespace name='static' file='static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/common/test/test_sites/test_site/templates/login-sidebar.html b/common/test/test_sites/test_site/templates/login-sidebar.html index dcee7d38105..43f23e5301a 100644 --- a/common/test/test_sites/test_site/templates/login-sidebar.html +++ b/common/test/test_sites/test_site/templates/login-sidebar.html @@ -1,7 +1,7 @@ <%page expression_filter="h"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <header> @@ -16,4 +16,4 @@ from django.core.urlresolvers import reverse <p> Custom text </p> -</div> \ No newline at end of file +</div> diff --git a/common/test/test_sites/test_site/templates/register-sidebar.html b/common/test/test_sites/test_site/templates/register-sidebar.html index b8edbd2ba57..bdf9f815315 100644 --- a/common/test/test_sites/test_site/templates/register-sidebar.html +++ b/common/test/test_sites/test_site/templates/register-sidebar.html @@ -1,7 +1,7 @@ <%page expression_filter="h"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%namespace file='../../main.html' import="login_query"/> <%namespace name='static' file='../../static_content.html'/> diff --git a/common/test/test_sites/test_site/templates/static_templates/about.html b/common/test/test_sites/test_site/templates/static_templates/about.html index 5dfbfaf7ad5..c4840e95e87 100644 --- a/common/test/test_sites/test_site/templates/static_templates/about.html +++ b/common/test/test_sites/test_site/templates/static_templates/about.html @@ -1,5 +1,5 @@ <%page expression_filter="h"/> -<%! from django.core.urlresolvers import reverse %> +<%! from django.urls import reverse %> <%namespace name='static' file='../../../static_content.html'/> <%inherit file="../../../main.html" /> diff --git a/common/test/test_sites/test_site/templates/static_templates/contact.html b/common/test/test_sites/test_site/templates/static_templates/contact.html index a360a2563ee..3cd9120e9a1 100644 --- a/common/test/test_sites/test_site/templates/static_templates/contact.html +++ b/common/test/test_sites/test_site/templates/static_templates/contact.html @@ -3,7 +3,7 @@ <%namespace name='static' file='../static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%block name="title"><title>${_("Contact {platform_name}").format(platform_name=settings.PLATFORM_NAME)}</title></%block> diff --git a/common/test/test_sites/test_site/templates/static_templates/faq.html b/common/test/test_sites/test_site/templates/static_templates/faq.html index c13f3753481..8723f73871b 100644 --- a/common/test/test_sites/test_site/templates/static_templates/faq.html +++ b/common/test/test_sites/test_site/templates/static_templates/faq.html @@ -3,7 +3,7 @@ <%namespace name='static' file='../static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%block name="title"><title>${_("FAQ")}</title></%block> diff --git a/common/test/test_sites/test_site/templates/static_templates/tos.html b/common/test/test_sites/test_site/templates/static_templates/tos.html index 1d918c20857..607dd9daec6 100644 --- a/common/test/test_sites/test_site/templates/static_templates/tos.html +++ b/common/test/test_sites/test_site/templates/static_templates/tos.html @@ -3,7 +3,7 @@ <%namespace name='static' file='../static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%block name="pagetitle">${_("Terms of Service")}</%block> diff --git a/lms/djangoapps/badges/events/course_complete.py b/lms/djangoapps/badges/events/course_complete.py index 7cb9e4986c4..38ff2f1782c 100644 --- a/lms/djangoapps/badges/events/course_complete.py +++ b/lms/djangoapps/badges/events/course_complete.py @@ -4,7 +4,7 @@ Helper functions for the course complete event that was originally included with import hashlib import logging -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.text import slugify from django.utils.translation import ugettext_lazy as _ diff --git a/lms/djangoapps/branding/api.py b/lms/djangoapps/branding/api.py index b1efafb39e2..59823e423d0 100644 --- a/lms/djangoapps/branding/api.py +++ b/lms/djangoapps/branding/api.py @@ -17,7 +17,7 @@ import urlparse from django.conf import settings from django.contrib.staticfiles.storage import staticfiles_storage -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from branding.models import BrandingApiConfig diff --git a/lms/djangoapps/branding/tests/test_api.py b/lms/djangoapps/branding/tests/test_api.py index 828d5fe1af0..336ce3bd46d 100644 --- a/lms/djangoapps/branding/tests/test_api.py +++ b/lms/djangoapps/branding/tests/test_api.py @@ -4,7 +4,7 @@ from __future__ import unicode_literals import mock from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.utils import override_settings diff --git a/lms/djangoapps/branding/tests/test_page.py b/lms/djangoapps/branding/tests/test_page.py index ce8b14151a0..867170c8caa 100644 --- a/lms/djangoapps/branding/tests/test_page.py +++ b/lms/djangoapps/branding/tests/test_page.py @@ -5,7 +5,7 @@ import datetime from django.conf import settings from django.contrib.auth.models import AnonymousUser -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpResponseRedirect from django.test.client import RequestFactory from django.test.utils import override_settings diff --git a/lms/djangoapps/branding/tests/test_views.py b/lms/djangoapps/branding/tests/test_views.py index 7a2f923a3e8..599a9a9b7a1 100644 --- a/lms/djangoapps/branding/tests/test_views.py +++ b/lms/djangoapps/branding/tests/test_views.py @@ -8,7 +8,7 @@ import mock from config_models.models import cache from django.conf import settings from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from branding.models import BrandingApiConfig diff --git a/lms/djangoapps/branding/views.py b/lms/djangoapps/branding/views.py index 6a9f271c106..bde3416fd38 100644 --- a/lms/djangoapps/branding/views.py +++ b/lms/djangoapps/branding/views.py @@ -5,7 +5,7 @@ import urllib from django.conf import settings from django.contrib.staticfiles.storage import staticfiles_storage from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import transaction from django.http import Http404, HttpResponse from django.shortcuts import redirect diff --git a/lms/djangoapps/bulk_email/tasks.py b/lms/djangoapps/bulk_email/tasks.py index a92112a78bd..3526303d3ca 100644 --- a/lms/djangoapps/bulk_email/tasks.py +++ b/lms/djangoapps/bulk_email/tasks.py @@ -30,7 +30,7 @@ from django.conf import settings from django.contrib.auth.models import User from django.core.mail import EmailMultiAlternatives, get_connection from django.core.mail.message import forbid_multi_line_headers -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import override as override_language from django.utils.translation import ugettext as _ from markupsafe import escape diff --git a/lms/djangoapps/bulk_email/tests/test_course_optout.py b/lms/djangoapps/bulk_email/tests/test_course_optout.py index 91a640c437a..61a18f146b9 100644 --- a/lms/djangoapps/bulk_email/tests/test_course_optout.py +++ b/lms/djangoapps/bulk_email/tests/test_course_optout.py @@ -6,7 +6,7 @@ import json from django.core import mail from django.core.management import call_command -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import Mock, patch from nose.plugins.attrib import attr from six import text_type diff --git a/lms/djangoapps/bulk_email/tests/test_email.py b/lms/djangoapps/bulk_email/tests/test_email.py index 1b07e81b61e..9476039af97 100644 --- a/lms/djangoapps/bulk_email/tests/test_email.py +++ b/lms/djangoapps/bulk_email/tests/test_email.py @@ -11,7 +11,7 @@ from django.conf import settings from django.core import mail from django.core.mail.message import forbid_multi_line_headers from django.core.management import call_command -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from django.utils.translation import get_language from markupsafe import escape diff --git a/lms/djangoapps/bulk_email/tests/test_err_handling.py b/lms/djangoapps/bulk_email/tests/test_err_handling.py index f5f5d0f6b1b..14186b8af6d 100644 --- a/lms/djangoapps/bulk_email/tests/test_err_handling.py +++ b/lms/djangoapps/bulk_email/tests/test_err_handling.py @@ -10,7 +10,7 @@ import ddt from celery.states import RETRY, SUCCESS # pylint: disable=no-name-in-module, import-error from django.conf import settings from django.core.management import call_command -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import DatabaseError from mock import Mock, patch from nose.plugins.attrib import attr diff --git a/lms/djangoapps/bulk_email/tests/test_signals.py b/lms/djangoapps/bulk_email/tests/test_signals.py index 427708bd329..18969de2e61 100644 --- a/lms/djangoapps/bulk_email/tests/test_signals.py +++ b/lms/djangoapps/bulk_email/tests/test_signals.py @@ -5,7 +5,7 @@ import json from django.core import mail from django.core.management import call_command -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import Mock, patch from nose.plugins.attrib import attr from six import text_type diff --git a/lms/djangoapps/bulk_enroll/tests/test_views.py b/lms/djangoapps/bulk_enroll/tests/test_views.py index 00a92b569bc..45a84b290ad 100644 --- a/lms/djangoapps/bulk_enroll/tests/test_views.py +++ b/lms/djangoapps/bulk_enroll/tests/test_views.py @@ -6,7 +6,7 @@ import json from django.conf import settings from django.contrib.auth.models import User from django.core import mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from rest_framework.test import APIRequestFactory, APITestCase, force_authenticate diff --git a/lms/djangoapps/ccx/api/v0/tests/test_views.py b/lms/djangoapps/ccx/api/v0/tests/test_views.py index 1ad89d9ecb8..d89c01780d5 100644 --- a/lms/djangoapps/ccx/api/v0/tests/test_views.py +++ b/lms/djangoapps/ccx/api/v0/tests/test_views.py @@ -14,7 +14,7 @@ import mock from ccx_keys.locator import CCXLocator from django.conf import settings from django.contrib.auth.models import User -from django.core.urlresolvers import Resolver404, resolve, reverse +from django.urls import Resolver404, resolve, reverse from django.utils.timezone import now from nose.plugins.attrib import attr from oauth2_provider import models as dot_models diff --git a/lms/djangoapps/ccx/tests/test_views.py b/lms/djangoapps/ccx/tests/test_views.py index c3f4f7ce0a8..a9e607ae8e1 100644 --- a/lms/djangoapps/ccx/tests/test_views.py +++ b/lms/djangoapps/ccx/tests/test_views.py @@ -9,7 +9,7 @@ import urlparse import ddt from ccx_keys.locator import CCXLocator from django.conf import settings -from django.core.urlresolvers import resolve, reverse +from django.urls import resolve, reverse from django.test import RequestFactory from django.test.utils import override_settings from pytz import UTC diff --git a/lms/djangoapps/ccx/utils.py b/lms/djangoapps/ccx/utils.py index f45336ac348..f059759fed0 100644 --- a/lms/djangoapps/ccx/utils.py +++ b/lms/djangoapps/ccx/utils.py @@ -11,7 +11,7 @@ from smtplib import SMTPException import pytz from django.contrib.auth.models import User from django.core.exceptions import ValidationError -from django.core.urlresolvers import reverse +from django.urls import reverse from django.core.validators import validate_email from django.utils.translation import ugettext as _ diff --git a/lms/djangoapps/ccx/views.py b/lms/djangoapps/ccx/views.py index 81e32a34bdc..162086be6c7 100644 --- a/lms/djangoapps/ccx/views.py +++ b/lms/djangoapps/ccx/views.py @@ -14,7 +14,7 @@ from ccx_keys.locator import CCXLocator from django.conf import settings from django.contrib import messages from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import transaction from django.http import Http404, HttpResponse, HttpResponseForbidden from django.shortcuts import redirect diff --git a/lms/djangoapps/certificates/api.py b/lms/djangoapps/certificates/api.py index 3da013851a4..7e29360ffca 100644 --- a/lms/djangoapps/certificates/api.py +++ b/lms/djangoapps/certificates/api.py @@ -7,7 +7,7 @@ rather than importing Django models directly. import logging from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db.models import Q from opaque_keys.edx.django.models import CourseKeyField from opaque_keys.edx.keys import CourseKey diff --git a/lms/djangoapps/certificates/apis/v0/tests/test_views.py b/lms/djangoapps/certificates/apis/v0/tests/test_views.py index 1aa9aefc6b8..38f82c51b8c 100644 --- a/lms/djangoapps/certificates/apis/v0/tests/test_views.py +++ b/lms/djangoapps/certificates/apis/v0/tests/test_views.py @@ -3,7 +3,7 @@ Tests for the Certificate REST APIs. """ from datetime import datetime, timedelta -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils import timezone from freezegun import freeze_time from oauth2_provider import models as dot_models diff --git a/lms/djangoapps/certificates/queue.py b/lms/djangoapps/certificates/queue.py index e6faf4102f8..613e19ab06c 100644 --- a/lms/djangoapps/certificates/queue.py +++ b/lms/djangoapps/certificates/queue.py @@ -6,7 +6,7 @@ from uuid import uuid4 import lxml.html from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from lxml.etree import ParserError, XMLSyntaxError from requests.auth import HTTPBasicAuth diff --git a/lms/djangoapps/certificates/tests/test_api.py b/lms/djangoapps/certificates/tests/test_api.py index 13b1f252ec0..3033162d631 100644 --- a/lms/djangoapps/certificates/tests/test_api.py +++ b/lms/djangoapps/certificates/tests/test_api.py @@ -8,7 +8,7 @@ from datetime import datetime from datetime import timedelta from config_models.models import cache from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import RequestFactory, TestCase from django.test.utils import override_settings from django.utils import timezone diff --git a/lms/djangoapps/certificates/tests/test_support_views.py b/lms/djangoapps/certificates/tests/test_support_views.py index 959841a5e7d..144ee08f0d3 100644 --- a/lms/djangoapps/certificates/tests/test_support_views.py +++ b/lms/djangoapps/certificates/tests/test_support_views.py @@ -6,7 +6,7 @@ import json import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from opaque_keys.edx.keys import CourseKey diff --git a/lms/djangoapps/certificates/tests/test_views.py b/lms/djangoapps/certificates/tests/test_views.py index 527a1830007..7762988e439 100644 --- a/lms/djangoapps/certificates/tests/test_views.py +++ b/lms/djangoapps/certificates/tests/test_views.py @@ -7,7 +7,7 @@ import ddt import datetime from django.conf import settings from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import Client from django.test.utils import override_settings from nose.plugins.attrib import attr diff --git a/lms/djangoapps/certificates/tests/test_webview_views.py b/lms/djangoapps/certificates/tests/test_webview_views.py index 81a256c8014..c3a37d4f22a 100644 --- a/lms/djangoapps/certificates/tests/test_webview_views.py +++ b/lms/djangoapps/certificates/tests/test_webview_views.py @@ -8,7 +8,7 @@ from urllib import urlencode from uuid import uuid4 from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import Client, RequestFactory from django.test.utils import override_settings from django.utils import translation diff --git a/lms/djangoapps/class_dashboard/tests/test_dashboard_data.py b/lms/djangoapps/class_dashboard/tests/test_dashboard_data.py index 630dc4cdeb0..2b0dad8b175 100644 --- a/lms/djangoapps/class_dashboard/tests/test_dashboard_data.py +++ b/lms/djangoapps/class_dashboard/tests/test_dashboard_data.py @@ -4,7 +4,7 @@ Tests for class dashboard (Metrics tab in instructor dashboard) import json -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from mock import patch from nose.plugins.attrib import attr diff --git a/lms/djangoapps/commerce/api/v0/tests/test_views.py b/lms/djangoapps/commerce/api/v0/tests/test_views.py index 88608a09ef7..07f412da07a 100644 --- a/lms/djangoapps/commerce/api/v0/tests/test_views.py +++ b/lms/djangoapps/commerce/api/v0/tests/test_views.py @@ -8,7 +8,7 @@ import ddt import mock import pytz from django.conf import settings -from django.core.urlresolvers import reverse, reverse_lazy +from django.urls import reverse, reverse_lazy from django.test import TestCase from django.test.utils import override_settings from edx_rest_api_client import exceptions diff --git a/lms/djangoapps/commerce/api/v0/views.py b/lms/djangoapps/commerce/api/v0/views.py index a50e2afee89..e4657cbdf92 100644 --- a/lms/djangoapps/commerce/api/v0/views.py +++ b/lms/djangoapps/commerce/api/v0/views.py @@ -2,7 +2,7 @@ import logging from courseware import courses -from django.core.urlresolvers import reverse +from django.urls import reverse from edx_rest_api_client import exceptions from opaque_keys import InvalidKeyError from opaque_keys.edx.keys import CourseKey diff --git a/lms/djangoapps/commerce/api/v1/tests/test_views.py b/lms/djangoapps/commerce/api/v1/tests/test_views.py index 9252dcec402..2a27e589450 100644 --- a/lms/djangoapps/commerce/api/v1/tests/test_views.py +++ b/lms/djangoapps/commerce/api/v1/tests/test_views.py @@ -7,7 +7,7 @@ import ddt import pytz from django.conf import settings from django.contrib.auth.models import Permission -from django.core.urlresolvers import reverse, reverse_lazy +from django.urls import reverse, reverse_lazy from django.test import TestCase from django.test.utils import override_settings from edx_rest_api_client import exceptions diff --git a/lms/djangoapps/commerce/tests/test_views.py b/lms/djangoapps/commerce/tests/test_views.py index 601c13a7433..9f30d07e8fa 100644 --- a/lms/djangoapps/commerce/tests/test_views.py +++ b/lms/djangoapps/commerce/tests/test_views.py @@ -4,7 +4,7 @@ import json import ddt import mock -from django.core.urlresolvers import reverse +from django.urls import reverse from nose.plugins.attrib import attr from course_modes.models import CourseMode diff --git a/lms/djangoapps/commerce/utils.py b/lms/djangoapps/commerce/utils.py index d40c289fbbe..0589bd78c39 100644 --- a/lms/djangoapps/commerce/utils.py +++ b/lms/djangoapps/commerce/utils.py @@ -8,7 +8,7 @@ import requests import waffle from django.conf import settings from django.contrib.auth import get_user_model -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangoapps.commerce.utils import ecommerce_api_client, is_commerce_service_configured diff --git a/lms/djangoapps/course_api/blocks/tests/test_views.py b/lms/djangoapps/course_api/blocks/tests/test_views.py index 7c3f1c5a819..427b85fdcc7 100644 --- a/lms/djangoapps/course_api/blocks/tests/test_views.py +++ b/lms/djangoapps/course_api/blocks/tests/test_views.py @@ -6,7 +6,7 @@ from string import join from urllib import urlencode from urlparse import urlunparse -from django.core.urlresolvers import reverse +from django.urls import reverse from opaque_keys.edx.locator import CourseLocator from student.models import CourseEnrollment diff --git a/lms/djangoapps/course_api/serializers.py b/lms/djangoapps/course_api/serializers.py index 7c8f2ee8532..544339b445e 100644 --- a/lms/djangoapps/course_api/serializers.py +++ b/lms/djangoapps/course_api/serializers.py @@ -4,7 +4,7 @@ Course API Serializers. Representing course catalog data import urllib -from django.core.urlresolvers import reverse +from django.urls import reverse from rest_framework import serializers from openedx.core.djangoapps.models.course_details import CourseDetails diff --git a/lms/djangoapps/course_api/tests/test_views.py b/lms/djangoapps/course_api/tests/test_views.py index 0f2618c720b..ad243c1a5aa 100644 --- a/lms/djangoapps/course_api/tests/test_views.py +++ b/lms/djangoapps/course_api/tests/test_views.py @@ -3,7 +3,7 @@ Tests for Course API views. """ from hashlib import md5 -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import RequestFactory from django.test.utils import override_settings from nose.plugins.attrib import attr diff --git a/lms/djangoapps/course_goals/tests/test_api.py b/lms/djangoapps/course_goals/tests/test_api.py index 5593ce9d963..edca8d9fa50 100644 --- a/lms/djangoapps/course_goals/tests/test_api.py +++ b/lms/djangoapps/course_goals/tests/test_api.py @@ -4,7 +4,7 @@ Unit tests for course_goals.api methods. import mock from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from lms.djangoapps.course_goals.models import CourseGoal from rest_framework.test import APIClient diff --git a/lms/djangoapps/course_wiki/tests/tests.py b/lms/djangoapps/course_wiki/tests/tests.py index a18f051a454..02a79cb7619 100644 --- a/lms/djangoapps/course_wiki/tests/tests.py +++ b/lms/djangoapps/course_wiki/tests/tests.py @@ -2,7 +2,7 @@ Tests for course wiki """ -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import patch from nose.plugins.attrib import attr from six import text_type diff --git a/lms/djangoapps/courseware/courses.py b/lms/djangoapps/courseware/courses.py index cef3e7dd71e..0738d1c525c 100644 --- a/lms/djangoapps/courseware/courses.py +++ b/lms/djangoapps/courseware/courses.py @@ -21,7 +21,7 @@ from courseware.date_summary import ( from courseware.model_data import FieldDataCache from courseware.module_render import get_module from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404, QueryDict from enrollment.api import get_course_enrollment_details from edxmako.shortcuts import render_to_string diff --git a/lms/djangoapps/courseware/date_summary.py b/lms/djangoapps/courseware/date_summary.py index 85dda380742..20ca88ac85e 100644 --- a/lms/djangoapps/courseware/date_summary.py +++ b/lms/djangoapps/courseware/date_summary.py @@ -9,7 +9,7 @@ import datetime from babel.dates import format_timedelta from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.formats import date_format from django.utils.functional import cached_property from django.utils.translation import get_language, to_locale, ugettext_lazy diff --git a/lms/djangoapps/courseware/features/common.py b/lms/djangoapps/courseware/features/common.py index 160bba983b1..79e17f48169 100644 --- a/lms/djangoapps/courseware/features/common.py +++ b/lms/djangoapps/courseware/features/common.py @@ -7,7 +7,7 @@ import time from logging import getLogger from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from lettuce import step, world from lettuce.django import django_url diff --git a/lms/djangoapps/courseware/module_render.py b/lms/djangoapps/courseware/module_render.py index a48307ddd11..dd38fa8af94 100644 --- a/lms/djangoapps/courseware/module_render.py +++ b/lms/djangoapps/courseware/module_render.py @@ -15,7 +15,7 @@ from django.contrib.auth.models import User from django.core.cache import cache from django.template.context_processors import csrf from django.core.exceptions import PermissionDenied -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404, HttpResponse, HttpResponseForbidden from django.views.decorators.csrf import csrf_exempt from edx_proctoring.services import ProctoringService diff --git a/lms/djangoapps/courseware/tests/helpers.py b/lms/djangoapps/courseware/tests/helpers.py index 6387faa28ea..7b163f33570 100644 --- a/lms/djangoapps/courseware/tests/helpers.py +++ b/lms/djangoapps/courseware/tests/helpers.py @@ -5,7 +5,7 @@ import json from django.contrib import messages from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.client import Client, RequestFactory from six import text_type diff --git a/lms/djangoapps/courseware/tests/test_about.py b/lms/djangoapps/courseware/tests/test_about.py index 9aa1b70f92b..88350f45b30 100644 --- a/lms/djangoapps/courseware/tests/test_about.py +++ b/lms/djangoapps/courseware/tests/test_about.py @@ -6,7 +6,7 @@ import ddt import pytz from ccx_keys.locator import CCXLocator from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from milestones.tests.utils import MilestonesTestCaseMixin from mock import patch diff --git a/lms/djangoapps/courseware/tests/test_access.py b/lms/djangoapps/courseware/tests/test_access.py index 66ae0a6d736..6dabede6714 100644 --- a/lms/djangoapps/courseware/tests/test_access.py +++ b/lms/djangoapps/courseware/tests/test_access.py @@ -9,7 +9,7 @@ import ddt import pytz from ccx_keys.locator import CCXLocator from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.client import RequestFactory from milestones.tests.utils import MilestonesTestCaseMixin diff --git a/lms/djangoapps/courseware/tests/test_course_info.py b/lms/djangoapps/courseware/tests/test_course_info.py index 04ec1bf6885..60fa76eef20 100644 --- a/lms/djangoapps/courseware/tests/test_course_info.py +++ b/lms/djangoapps/courseware/tests/test_course_info.py @@ -5,7 +5,7 @@ Test the course_info xblock import ddt import mock from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import QueryDict from django.test.utils import override_settings diff --git a/lms/djangoapps/courseware/tests/test_course_survey.py b/lms/djangoapps/courseware/tests/test_course_survey.py index 9ac5032532f..c51e8abb2ad 100644 --- a/lms/djangoapps/courseware/tests/test_course_survey.py +++ b/lms/djangoapps/courseware/tests/test_course_survey.py @@ -6,7 +6,7 @@ from collections import OrderedDict from copy import deepcopy from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from nose.plugins.attrib import attr from common.test.utils import XssTestMixin diff --git a/lms/djangoapps/courseware/tests/test_courses.py b/lms/djangoapps/courseware/tests/test_courses.py index 41512357c98..92454ee2021 100644 --- a/lms/djangoapps/courseware/tests/test_courses.py +++ b/lms/djangoapps/courseware/tests/test_courses.py @@ -9,7 +9,7 @@ import ddt import mock import pytz from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from django.test.utils import override_settings from nose.plugins.attrib import attr diff --git a/lms/djangoapps/courseware/tests/test_credit_requirements.py b/lms/djangoapps/courseware/tests/test_credit_requirements.py index 416fe258742..e539b2d2daf 100644 --- a/lms/djangoapps/courseware/tests/test_credit_requirements.py +++ b/lms/djangoapps/courseware/tests/test_credit_requirements.py @@ -4,7 +4,7 @@ Tests for credit requirement display on the progress page. import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import patch from course_modes.models import CourseMode diff --git a/lms/djangoapps/courseware/tests/test_date_summary.py b/lms/djangoapps/courseware/tests/test_date_summary.py index 5ddb17704af..b58195f8645 100644 --- a/lms/djangoapps/courseware/tests/test_date_summary.py +++ b/lms/djangoapps/courseware/tests/test_date_summary.py @@ -5,7 +5,7 @@ from datetime import datetime, timedelta import ddt import waffle from django.contrib.messages.middleware import MessageMiddleware -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import RequestFactory from freezegun import freeze_time from mock import patch diff --git a/lms/djangoapps/courseware/tests/test_discussion_xblock.py b/lms/djangoapps/courseware/tests/test_discussion_xblock.py index 05db1e5a365..f01a3ddcc88 100644 --- a/lms/djangoapps/courseware/tests/test_discussion_xblock.py +++ b/lms/djangoapps/courseware/tests/test_discussion_xblock.py @@ -11,7 +11,7 @@ import uuid import ddt import mock -from django.core.urlresolvers import reverse +from django.urls import reverse from web_fragments.fragment import Fragment from xblock.field_data import DictFieldData diff --git a/lms/djangoapps/courseware/tests/test_entrance_exam.py b/lms/djangoapps/courseware/tests/test_entrance_exam.py index b56e1e074fa..eeeab157a40 100644 --- a/lms/djangoapps/courseware/tests/test_entrance_exam.py +++ b/lms/djangoapps/courseware/tests/test_entrance_exam.py @@ -1,7 +1,7 @@ """ Tests use cases related to LMS Entrance Exam behavior, such as gated content access (TOC) """ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from mock import Mock, patch diff --git a/lms/djangoapps/courseware/tests/test_i18n.py b/lms/djangoapps/courseware/tests/test_i18n.py index 71e1c8f7795..939cc697935 100644 --- a/lms/djangoapps/courseware/tests/test_i18n.py +++ b/lms/djangoapps/courseware/tests/test_i18n.py @@ -7,7 +7,7 @@ import re from django.conf import settings from django.contrib.auth.models import User -from django.core.urlresolvers import reverse, reverse_lazy +from django.urls import reverse, reverse_lazy from django.test import TestCase from django.test.client import Client from django.utils import translation diff --git a/lms/djangoapps/courseware/tests/test_lti_integration.py b/lms/djangoapps/courseware/tests/test_lti_integration.py index b6be3737a85..74a92ffefc6 100644 --- a/lms/djangoapps/courseware/tests/test_lti_integration.py +++ b/lms/djangoapps/courseware/tests/test_lti_integration.py @@ -7,7 +7,7 @@ from collections import OrderedDict import mock import pytest from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse import oauthlib from courseware.tests.helpers import BaseTestXmodule diff --git a/lms/djangoapps/courseware/tests/test_masquerade.py b/lms/djangoapps/courseware/tests/test_masquerade.py index d2e494ae414..7a7d1ae3dd9 100644 --- a/lms/djangoapps/courseware/tests/test_masquerade.py +++ b/lms/djangoapps/courseware/tests/test_masquerade.py @@ -6,7 +6,7 @@ import pickle from datetime import datetime from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from mock import patch from pytz import UTC diff --git a/lms/djangoapps/courseware/tests/test_microsites.py b/lms/djangoapps/courseware/tests/test_microsites.py index 46d35e3c539..2ba2f627aac 100644 --- a/lms/djangoapps/courseware/tests/test_microsites.py +++ b/lms/djangoapps/courseware/tests/test_microsites.py @@ -6,7 +6,7 @@ import pytest from bs4 import BeautifulSoup from contextlib import contextmanager from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from mock import patch from nose.plugins.attrib import attr diff --git a/lms/djangoapps/courseware/tests/test_module_render.py b/lms/djangoapps/courseware/tests/test_module_render.py index 0a454cf77bb..366cb42a310 100644 --- a/lms/djangoapps/courseware/tests/test_module_render.py +++ b/lms/djangoapps/courseware/tests/test_module_render.py @@ -15,7 +15,7 @@ from completion.models import BlockCompletion from completion import waffle as completion_waffle from django.conf import settings from django.contrib.auth.models import AnonymousUser -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404, HttpResponse from django.test.client import RequestFactory from django.test.utils import override_settings diff --git a/lms/djangoapps/courseware/tests/test_navigation.py b/lms/djangoapps/courseware/tests/test_navigation.py index d3abde6e82a..e5f61a34c5f 100644 --- a/lms/djangoapps/courseware/tests/test_navigation.py +++ b/lms/djangoapps/courseware/tests/test_navigation.py @@ -4,7 +4,7 @@ This test file will run through some LMS test scenarios regarding access and nav import time from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from mock import patch from nose.plugins.attrib import attr diff --git a/lms/djangoapps/courseware/tests/test_password_history.py b/lms/djangoapps/courseware/tests/test_password_history.py index 8a4e5a87f99..05d6ad72ffd 100644 --- a/lms/djangoapps/courseware/tests/test_password_history.py +++ b/lms/djangoapps/courseware/tests/test_password_history.py @@ -8,7 +8,7 @@ from uuid import uuid4 import ddt from django.contrib.auth.models import User from django.contrib.auth.tokens import default_token_generator -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from django.utils import timezone from django.utils.http import int_to_base36 diff --git a/lms/djangoapps/courseware/tests/test_split_module.py b/lms/djangoapps/courseware/tests/test_split_module.py index bc837e696e2..41b1fd91421 100644 --- a/lms/djangoapps/courseware/tests/test_split_module.py +++ b/lms/djangoapps/courseware/tests/test_split_module.py @@ -1,7 +1,7 @@ """ Test for split test XModule """ -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import MagicMock from nose.plugins.attrib import attr from six import text_type diff --git a/lms/djangoapps/courseware/tests/test_submitting_problems.py b/lms/djangoapps/courseware/tests/test_submitting_problems.py index bfd2ca66b82..5505520ad16 100644 --- a/lms/djangoapps/courseware/tests/test_submitting_problems.py +++ b/lms/djangoapps/courseware/tests/test_submitting_problems.py @@ -12,7 +12,7 @@ from textwrap import dedent import ddt from django.conf import settings from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.client import RequestFactory from django.utils.timezone import now diff --git a/lms/djangoapps/courseware/tests/test_tabs.py b/lms/djangoapps/courseware/tests/test_tabs.py index 121adf99c9b..de7fc6f7719 100644 --- a/lms/djangoapps/courseware/tests/test_tabs.py +++ b/lms/djangoapps/courseware/tests/test_tabs.py @@ -4,7 +4,7 @@ Test cases for tabs. import pytest from django.contrib.auth.models import AnonymousUser -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404 from milestones.tests.utils import MilestonesTestCaseMixin from mock import MagicMock, Mock, patch diff --git a/lms/djangoapps/courseware/tests/test_view_authentication.py b/lms/djangoapps/courseware/tests/test_view_authentication.py index e9ab065bb0b..c0bd58c7350 100644 --- a/lms/djangoapps/courseware/tests/test_view_authentication.py +++ b/lms/djangoapps/courseware/tests/test_view_authentication.py @@ -1,7 +1,7 @@ import datetime import pytz -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import patch from nose.plugins.attrib import attr from six import text_type diff --git a/lms/djangoapps/courseware/tests/test_views.py b/lms/djangoapps/courseware/tests/test_views.py index d4db7e8ddec..c28f4e300a2 100644 --- a/lms/djangoapps/courseware/tests/test_views.py +++ b/lms/djangoapps/courseware/tests/test_views.py @@ -13,7 +13,7 @@ from uuid import uuid4 import ddt from django.conf import settings from django.contrib.auth.models import AnonymousUser -from django.core.urlresolvers import reverse, reverse_lazy +from django.urls import reverse, reverse_lazy from django.http import Http404, HttpResponseBadRequest from django.test import TestCase from django.test.client import Client, RequestFactory diff --git a/lms/djangoapps/courseware/tests/tests.py b/lms/djangoapps/courseware/tests/tests.py index 92dde53e455..384d7a92e13 100644 --- a/lms/djangoapps/courseware/tests/tests.py +++ b/lms/djangoapps/courseware/tests/tests.py @@ -5,7 +5,7 @@ from textwrap import dedent from unittest import TestCase import mock -from django.core.urlresolvers import reverse +from django.urls import reverse from nose.plugins.attrib import attr from opaque_keys.edx.keys import CourseKey from six import text_type diff --git a/lms/djangoapps/courseware/url_helpers.py b/lms/djangoapps/courseware/url_helpers.py index 25ac8e49153..2c82f2a653c 100644 --- a/lms/djangoapps/courseware/url_helpers.py +++ b/lms/djangoapps/courseware/url_helpers.py @@ -3,7 +3,7 @@ Module to define url helpers functions """ from urllib import urlencode -from django.core.urlresolvers import reverse +from django.urls import reverse from xmodule.modulestore.django import modulestore from xmodule.modulestore.search import navigation_index, path_to_location diff --git a/lms/djangoapps/courseware/views/index.py b/lms/djangoapps/courseware/views/index.py index f6ad873cf93..50f0d82a690 100644 --- a/lms/djangoapps/courseware/views/index.py +++ b/lms/djangoapps/courseware/views/index.py @@ -10,7 +10,7 @@ import urllib from django.conf import settings from django.contrib.auth.models import User from django.contrib.auth.views import redirect_to_login -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404 from django.template.context_processors import csrf from django.utils.decorators import method_decorator diff --git a/lms/djangoapps/courseware/views/views.py b/lms/djangoapps/courseware/views/views.py index 31e2a635cf6..3496788e0be 100644 --- a/lms/djangoapps/courseware/views/views.py +++ b/lms/djangoapps/courseware/views/views.py @@ -12,7 +12,7 @@ from django.conf import settings from django.contrib.auth.decorators import login_required from django.contrib.auth.models import AnonymousUser, User from django.core.exceptions import PermissionDenied -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import transaction from django.db.models import Q from django.http import Http404, HttpResponse, HttpResponseBadRequest, HttpResponseForbidden diff --git a/lms/djangoapps/dashboard/tests/test_sysadmin.py b/lms/djangoapps/dashboard/tests/test_sysadmin.py index 10a65e27c79..fe3304a0ad8 100644 --- a/lms/djangoapps/dashboard/tests/test_sysadmin.py +++ b/lms/djangoapps/dashboard/tests/test_sysadmin.py @@ -11,7 +11,7 @@ from uuid import uuid4 import mongoengine from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import Client from django.test.utils import override_settings from pytz import UTC diff --git a/lms/djangoapps/discussion/templates/discussion/discussion_board_fragment.html b/lms/djangoapps/discussion/templates/discussion/discussion_board_fragment.html index 82863b484c1..0adb14423d5 100644 --- a/lms/djangoapps/discussion/templates/discussion/discussion_board_fragment.html +++ b/lms/djangoapps/discussion/templates/discussion/discussion_board_fragment.html @@ -8,7 +8,7 @@ import json from django.utils.translation import ugettext as _ from django.template.defaultfilters import escapejs -from django.core.urlresolvers import reverse +from django.urls import reverse from django_comment_client.permissions import has_permission from openedx.core.djangolib.js_utils import dump_js_escaped_json, js_escaped_string diff --git a/lms/djangoapps/discussion/templates/discussion/discussion_profile_page.html b/lms/djangoapps/discussion/templates/discussion/discussion_profile_page.html index f6e3bdf60fa..e28b32599fd 100644 --- a/lms/djangoapps/discussion/templates/discussion/discussion_profile_page.html +++ b/lms/djangoapps/discussion/templates/discussion/discussion_profile_page.html @@ -8,7 +8,7 @@ import json from django.utils.translation import ugettext as _, ungettext from django.template.defaultfilters import escapejs -from django.core.urlresolvers import reverse +from django.urls import reverse from django_comment_client.permissions import has_permission from openedx.core.djangolib.js_utils import dump_js_escaped_json, js_escaped_string diff --git a/lms/djangoapps/discussion/tests/test_views.py b/lms/djangoapps/discussion/tests/test_views.py index efabd929a4c..e454e19e226 100644 --- a/lms/djangoapps/discussion/tests/test_views.py +++ b/lms/djangoapps/discussion/tests/test_views.py @@ -3,7 +3,7 @@ import logging from datetime import datetime import ddt -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404 from django.test.client import Client, RequestFactory from django.test.utils import override_settings diff --git a/lms/djangoapps/discussion/views.py b/lms/djangoapps/discussion/views.py index b123a148e30..eedbc34156e 100644 --- a/lms/djangoapps/discussion/views.py +++ b/lms/djangoapps/discussion/views.py @@ -10,7 +10,7 @@ from django.contrib.auth.decorators import login_required from django.contrib.auth.models import User from django.contrib.staticfiles.storage import staticfiles_storage from django.template.context_processors import csrf -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404, HttpResponseServerError from django.shortcuts import render_to_response from django.template.loader import render_to_string diff --git a/lms/djangoapps/discussion_api/api.py b/lms/djangoapps/discussion_api/api.py index eeb30fc271c..6c26e9af6b0 100644 --- a/lms/djangoapps/discussion_api/api.py +++ b/lms/djangoapps/discussion_api/api.py @@ -7,7 +7,7 @@ from urllib import urlencode from urlparse import urlunparse from django.core.exceptions import ValidationError -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404 from enum import Enum from opaque_keys import InvalidKeyError diff --git a/lms/djangoapps/discussion_api/serializers.py b/lms/djangoapps/discussion_api/serializers.py index 4f7c1d14ff5..9c8f7dd50a6 100644 --- a/lms/djangoapps/discussion_api/serializers.py +++ b/lms/djangoapps/discussion_api/serializers.py @@ -6,7 +6,7 @@ from urlparse import urlunparse from django.contrib.auth.models import User as DjangoUser from django.core.exceptions import ValidationError -from django.core.urlresolvers import reverse +from django.urls import reverse from rest_framework import serializers from discussion_api.permissions import NON_UPDATABLE_COMMENT_FIELDS, NON_UPDATABLE_THREAD_FIELDS, get_editable_fields diff --git a/lms/djangoapps/discussion_api/tests/test_views.py b/lms/djangoapps/discussion_api/tests/test_views.py index 421d282ce78..9504e2bf849 100644 --- a/lms/djangoapps/discussion_api/tests/test_views.py +++ b/lms/djangoapps/discussion_api/tests/test_views.py @@ -10,7 +10,7 @@ from urlparse import urlparse import ddt import httpretty import mock -from django.core.urlresolvers import reverse +from django.urls import reverse from nose.plugins.attrib import attr from pytz import UTC from rest_framework.parsers import JSONParser diff --git a/lms/djangoapps/django_comment_client/base/event_transformers.py b/lms/djangoapps/django_comment_client/base/event_transformers.py index 736f344f46b..1441ca9a7bd 100644 --- a/lms/djangoapps/django_comment_client/base/event_transformers.py +++ b/lms/djangoapps/django_comment_client/base/event_transformers.py @@ -2,7 +2,7 @@ Transformers for Discussion-related events. """ from django.contrib.auth.models import User -from django.core.urlresolvers import reverse, NoReverseMatch +from django.urls import reverse, NoReverseMatch from eventtracking.processors.exceptions import EventEmissionExit from opaque_keys import InvalidKeyError diff --git a/lms/djangoapps/django_comment_client/base/tests.py b/lms/djangoapps/django_comment_client/base/tests.py index 603f0c37ebf..32030878195 100644 --- a/lms/djangoapps/django_comment_client/base/tests.py +++ b/lms/djangoapps/django_comment_client/base/tests.py @@ -9,7 +9,7 @@ import ddt import pytest from django.contrib.auth.models import User from django.core.management import call_command -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from eventtracking.processors.exceptions import EventEmissionExit from mock import ANY, Mock, patch diff --git a/lms/djangoapps/django_comment_client/tests/test_utils.py b/lms/djangoapps/django_comment_client/tests/test_utils.py index 4e237df82cc..d46a04c2bc7 100644 --- a/lms/djangoapps/django_comment_client/tests/test_utils.py +++ b/lms/djangoapps/django_comment_client/tests/test_utils.py @@ -6,7 +6,7 @@ import ddt import mock import pytest -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import RequestFactory, TestCase from mock import Mock, patch from nose.plugins.attrib import attr diff --git a/lms/djangoapps/django_comment_client/utils.py b/lms/djangoapps/django_comment_client/utils.py index 24c928c3492..abcbf5fa63c 100644 --- a/lms/djangoapps/django_comment_client/utils.py +++ b/lms/djangoapps/django_comment_client/utils.py @@ -5,7 +5,7 @@ from datetime import datetime from django.conf import settings from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import connection from django.http import HttpResponse from pytz import UTC diff --git a/lms/djangoapps/edxnotes/helpers.py b/lms/djangoapps/edxnotes/helpers.py index 4c981d9d70f..e01c0cc5397 100644 --- a/lms/djangoapps/edxnotes/helpers.py +++ b/lms/djangoapps/edxnotes/helpers.py @@ -13,7 +13,7 @@ import requests from dateutil.parser import parse as dateutil_parse from django.conf import settings from django.core.exceptions import ImproperlyConfigured -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from opaque_keys.edx.keys import UsageKey from provider.oauth2.models import Client diff --git a/lms/djangoapps/edxnotes/tests.py b/lms/djangoapps/edxnotes/tests.py index 4b45d6bba3b..173c6968715 100644 --- a/lms/djangoapps/edxnotes/tests.py +++ b/lms/djangoapps/edxnotes/tests.py @@ -13,7 +13,7 @@ import jwt from django.conf import settings from django.contrib.auth.models import AnonymousUser from django.core.exceptions import ImproperlyConfigured -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from django.test.utils import override_settings from edx_oauth2_provider.tests.factories import ClientFactory diff --git a/lms/djangoapps/edxnotes/views.py b/lms/djangoapps/edxnotes/views.py index bf4ed68e285..512beca9d21 100644 --- a/lms/djangoapps/edxnotes/views.py +++ b/lms/djangoapps/edxnotes/views.py @@ -6,7 +6,7 @@ import logging from django.conf import settings from django.contrib.auth.decorators import login_required -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404, HttpResponse from django.views.decorators.http import require_GET from opaque_keys.edx.keys import CourseKey diff --git a/lms/djangoapps/experiments/tests/test_views.py b/lms/djangoapps/experiments/tests/test_views.py index 71dbb648284..d3b48d4abc9 100644 --- a/lms/djangoapps/experiments/tests/test_views.py +++ b/lms/djangoapps/experiments/tests/test_views.py @@ -3,7 +3,7 @@ import unittest from django.conf import settings from django.core.handlers.wsgi import WSGIRequest -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from mock import patch from rest_framework.test import APITestCase diff --git a/lms/djangoapps/grades/api/tests/test_views.py b/lms/djangoapps/grades/api/tests/test_views.py index caaef711a08..311ad020442 100644 --- a/lms/djangoapps/grades/api/tests/test_views.py +++ b/lms/djangoapps/grades/api/tests/test_views.py @@ -5,7 +5,7 @@ from datetime import datetime from urllib import urlencode import ddt -from django.core.urlresolvers import reverse +from django.urls import reverse from edx_oauth2_provider.tests.factories import AccessTokenFactory, ClientFactory from mock import patch from opaque_keys import InvalidKeyError diff --git a/lms/djangoapps/grades/api/v1/tests/test_views.py b/lms/djangoapps/grades/api/v1/tests/test_views.py index e73361bf9ef..7ffb728376f 100644 --- a/lms/djangoapps/grades/api/v1/tests/test_views.py +++ b/lms/djangoapps/grades/api/v1/tests/test_views.py @@ -4,7 +4,7 @@ Tests for v1 views from datetime import datetime import ddt -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import MagicMock, patch from opaque_keys import InvalidKeyError from pytz import UTC diff --git a/lms/djangoapps/instructor/enrollment.py b/lms/djangoapps/instructor/enrollment.py index 6e8977e90c9..3fabe4630fd 100644 --- a/lms/djangoapps/instructor/enrollment.py +++ b/lms/djangoapps/instructor/enrollment.py @@ -12,7 +12,7 @@ import pytz from django.conf import settings from django.contrib.auth.models import User from django.core.mail import send_mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import override as override_language from six import text_type diff --git a/lms/djangoapps/instructor/tests/test_api.py b/lms/djangoapps/instructor/tests/test_api.py index 87041813238..5275f8d6c0d 100644 --- a/lms/djangoapps/instructor/tests/test_api.py +++ b/lms/djangoapps/instructor/tests/test_api.py @@ -16,7 +16,7 @@ from django.conf import settings from django.contrib.auth.models import User from django.core import mail from django.core.files.uploadedfile import SimpleUploadedFile -from django.core.urlresolvers import reverse as django_reverse +from django.urls import reverse as django_reverse from django.http import HttpRequest, HttpResponse from django.test import RequestFactory, TestCase from django.test.utils import override_settings diff --git a/lms/djangoapps/instructor/tests/test_api_email_localization.py b/lms/djangoapps/instructor/tests/test_api_email_localization.py index c48f843f499..a6c3e0a6412 100644 --- a/lms/djangoapps/instructor/tests/test_api_email_localization.py +++ b/lms/djangoapps/instructor/tests/test_api_email_localization.py @@ -4,7 +4,7 @@ Unit tests for the localization of emails sent by instructor.api methods. """ from django.core import mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from nose.plugins.attrib import attr from six import text_type diff --git a/lms/djangoapps/instructor/tests/test_certificates.py b/lms/djangoapps/instructor/tests/test_certificates.py index e6fe57cae21..54345f14ab1 100644 --- a/lms/djangoapps/instructor/tests/test_certificates.py +++ b/lms/djangoapps/instructor/tests/test_certificates.py @@ -11,7 +11,7 @@ from config_models.models import cache from django.conf import settings from django.core.exceptions import ObjectDoesNotExist from django.core.files.uploadedfile import SimpleUploadedFile -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from nose.plugins.attrib import attr diff --git a/lms/djangoapps/instructor/tests/test_ecommerce.py b/lms/djangoapps/instructor/tests/test_ecommerce.py index 2bc2f6b19c1..a9bbbe3a86b 100644 --- a/lms/djangoapps/instructor/tests/test_ecommerce.py +++ b/lms/djangoapps/instructor/tests/test_ecommerce.py @@ -5,7 +5,7 @@ Unit tests for Ecommerce feature flag in new instructor dashboard. import datetime import pytz -from django.core.urlresolvers import reverse +from django.urls import reverse from nose.plugins.attrib import attr from six import text_type diff --git a/lms/djangoapps/instructor/tests/test_email.py b/lms/djangoapps/instructor/tests/test_email.py index a889f62b6c6..f2f3be05f5e 100644 --- a/lms/djangoapps/instructor/tests/test_email.py +++ b/lms/djangoapps/instructor/tests/test_email.py @@ -5,7 +5,7 @@ non-Mongo backed courses, regardless of email feature flag, and that the view is conditionally available when Course Auth is turned on. """ -from django.core.urlresolvers import reverse +from django.urls import reverse from nose.plugins.attrib import attr from opaque_keys.edx.keys import CourseKey from six import text_type diff --git a/lms/djangoapps/instructor/tests/test_proctoring.py b/lms/djangoapps/instructor/tests/test_proctoring.py index ef1506cec29..a7746dffcfd 100644 --- a/lms/djangoapps/instructor/tests/test_proctoring.py +++ b/lms/djangoapps/instructor/tests/test_proctoring.py @@ -4,7 +4,7 @@ Unit tests for Edx Proctoring feature flag in new instructor dashboard. import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import patch from nose.plugins.attrib import attr from six import text_type diff --git a/lms/djangoapps/instructor/tests/test_registration_codes.py b/lms/djangoapps/instructor/tests/test_registration_codes.py index 9c7e7bde733..52c85afdbdf 100644 --- a/lms/djangoapps/instructor/tests/test_registration_codes.py +++ b/lms/djangoapps/instructor/tests/test_registration_codes.py @@ -3,7 +3,7 @@ Test for the registration code status information. """ import json -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from django.utils.translation import ugettext as _ from nose.plugins.attrib import attr diff --git a/lms/djangoapps/instructor/tests/test_spoc_gradebook.py b/lms/djangoapps/instructor/tests/test_spoc_gradebook.py index ec16a13dc3b..df0110c8656 100644 --- a/lms/djangoapps/instructor/tests/test_spoc_gradebook.py +++ b/lms/djangoapps/instructor/tests/test_spoc_gradebook.py @@ -2,7 +2,7 @@ Tests of the instructor dashboard spoc gradebook """ -from django.core.urlresolvers import reverse +from django.urls import reverse from nose.plugins.attrib import attr from six import text_type diff --git a/lms/djangoapps/instructor/tests/views/test_instructor_dashboard.py b/lms/djangoapps/instructor/tests/views/test_instructor_dashboard.py index 102d6c4a207..cfc8045381e 100644 --- a/lms/djangoapps/instructor/tests/views/test_instructor_dashboard.py +++ b/lms/djangoapps/instructor/tests/views/test_instructor_dashboard.py @@ -6,7 +6,7 @@ import datetime import ddt from django.conf import settings from django.contrib.sites.models import Site -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from django.test.utils import override_settings from mock import patch diff --git a/lms/djangoapps/instructor/views/api.py b/lms/djangoapps/instructor/views/api.py index 00886585f34..434ca59a7f5 100644 --- a/lms/djangoapps/instructor/views/api.py +++ b/lms/djangoapps/instructor/views/api.py @@ -25,7 +25,7 @@ from django.core.exceptions import ( ValidationError ) from django.core.mail.message import EmailMessage -from django.core.urlresolvers import reverse +from django.urls import reverse from django.core.validators import validate_email from django.db import IntegrityError, transaction from django.http import HttpResponse, HttpResponseBadRequest, HttpResponseForbidden, HttpResponseNotFound diff --git a/lms/djangoapps/instructor/views/gradebook_api.py b/lms/djangoapps/instructor/views/gradebook_api.py index aa690eddda0..922d351d082 100644 --- a/lms/djangoapps/instructor/views/gradebook_api.py +++ b/lms/djangoapps/instructor/views/gradebook_api.py @@ -5,7 +5,7 @@ which is currently use by ccx and instructor apps. import math from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import transaction from django.views.decorators.cache import cache_control from opaque_keys.edx.keys import CourseKey diff --git a/lms/djangoapps/instructor/views/instructor_dashboard.py b/lms/djangoapps/instructor/views/instructor_dashboard.py index 97ac3eaec35..65bfdb7b068 100644 --- a/lms/djangoapps/instructor/views/instructor_dashboard.py +++ b/lms/djangoapps/instructor/views/instructor_dashboard.py @@ -9,7 +9,7 @@ import uuid import pytz from django.conf import settings from django.contrib.auth.decorators import login_required -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404, HttpResponseServerError from django.utils.html import escape from django.utils.translation import ugettext as _ diff --git a/lms/djangoapps/instructor/views/registration_codes.py b/lms/djangoapps/instructor/views/registration_codes.py index ad8c00fe6e4..357de69be63 100644 --- a/lms/djangoapps/instructor/views/registration_codes.py +++ b/lms/djangoapps/instructor/views/registration_codes.py @@ -3,7 +3,7 @@ E-commerce Tab Instructor Dashboard Query Registration Code Status. """ import logging -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from django.views.decorators.cache import cache_control from django.views.decorators.http import require_GET, require_POST diff --git a/lms/djangoapps/instructor_analytics/basic.py b/lms/djangoapps/instructor_analytics/basic.py index 0851f4a6ac0..3a5130c116c 100644 --- a/lms/djangoapps/instructor_analytics/basic.py +++ b/lms/djangoapps/instructor_analytics/basic.py @@ -10,7 +10,7 @@ from django.conf import settings from django.contrib.auth.models import User from django.core.exceptions import ObjectDoesNotExist from django.core.serializers.json import DjangoJSONEncoder -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db.models import Count, Q from edx_proctoring.api import get_exam_violation_report from opaque_keys.edx.keys import UsageKey diff --git a/lms/djangoapps/instructor_analytics/tests/test_basic.py b/lms/djangoapps/instructor_analytics/tests/test_basic.py index 6d2b616e52d..1d851609866 100644 --- a/lms/djangoapps/instructor_analytics/tests/test_basic.py +++ b/lms/djangoapps/instructor_analytics/tests/test_basic.py @@ -6,7 +6,7 @@ import datetime import json import pytz -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db.models import Q from edx_proctoring.api import create_exam from edx_proctoring.models import ProctoredExamStudentAttempt diff --git a/lms/djangoapps/instructor_task/tests/test_base.py b/lms/djangoapps/instructor_task/tests/test_base.py index 1bd6277bd4f..80bad8b4c5c 100644 --- a/lms/djangoapps/instructor_task/tests/test_base.py +++ b/lms/djangoapps/instructor_task/tests/test_base.py @@ -12,7 +12,7 @@ from uuid import uuid4 import unicodecsv from celery.states import FAILURE, SUCCESS from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import Mock, patch from opaque_keys.edx.locations import Location from opaque_keys.edx.keys import CourseKey diff --git a/lms/djangoapps/instructor_task/tests/test_integration.py b/lms/djangoapps/instructor_task/tests/test_integration.py index 092f0107b58..1c2ea4ec287 100644 --- a/lms/djangoapps/instructor_task/tests/test_integration.py +++ b/lms/djangoapps/instructor_task/tests/test_integration.py @@ -13,7 +13,7 @@ from collections import namedtuple import ddt from celery.states import FAILURE, SUCCESS from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import patch from nose.plugins.attrib import attr from six import text_type diff --git a/lms/djangoapps/instructor_task/tests/test_tasks_helper.py b/lms/djangoapps/instructor_task/tests/test_tasks_helper.py index 5efde29c064..502d83adc1c 100644 --- a/lms/djangoapps/instructor_task/tests/test_tasks_helper.py +++ b/lms/djangoapps/instructor_task/tests/test_tasks_helper.py @@ -22,7 +22,7 @@ from course_modes.models import CourseMode from course_modes.tests.factories import CourseModeFactory from courseware.tests.factories import InstructorFactory from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from freezegun import freeze_time from instructor_analytics.basic import UNAVAILABLE, list_problem_responses diff --git a/lms/djangoapps/learner_dashboard/programs.py b/lms/djangoapps/learner_dashboard/programs.py index 82a88b128e9..d08e40b2557 100644 --- a/lms/djangoapps/learner_dashboard/programs.py +++ b/lms/djangoapps/learner_dashboard/programs.py @@ -6,7 +6,7 @@ import json from django.http import Http404 from django.template.loader import render_to_string from django.utils.translation import get_language_bidi -from django.core.urlresolvers import reverse +from django.urls import reverse from web_fragments.fragment import Fragment diff --git a/lms/djangoapps/learner_dashboard/tests/test_programs.py b/lms/djangoapps/learner_dashboard/tests/test_programs.py index 5387b733aa5..627893bd036 100644 --- a/lms/djangoapps/learner_dashboard/tests/test_programs.py +++ b/lms/djangoapps/learner_dashboard/tests/test_programs.py @@ -10,7 +10,7 @@ from uuid import uuid4 import mock from bs4 import BeautifulSoup from django.conf import settings -from django.core.urlresolvers import reverse, reverse_lazy +from django.urls import reverse, reverse_lazy from django.test import override_settings from lms.envs.test import CREDENTIALS_PUBLIC_SERVICE_URL diff --git a/lms/djangoapps/lms_xblock/runtime.py b/lms/djangoapps/lms_xblock/runtime.py index 52179f10e0d..ce3b8cf2215 100644 --- a/lms/djangoapps/lms_xblock/runtime.py +++ b/lms/djangoapps/lms_xblock/runtime.py @@ -3,7 +3,7 @@ Module implementing `xblock.runtime.Runtime` functionality for the LMS """ from completion.services import CompletionService from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse import xblock.reference.plugins from badges.service import BadgingService diff --git a/lms/djangoapps/lti_provider/tests/test_views.py b/lms/djangoapps/lti_provider/tests/test_views.py index d4dd15ec4cd..64461be81be 100644 --- a/lms/djangoapps/lti_provider/tests/test_views.py +++ b/lms/djangoapps/lti_provider/tests/test_views.py @@ -3,7 +3,7 @@ Tests for the LTI provider views """ import pytest -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.client import RequestFactory from mock import MagicMock, patch diff --git a/lms/djangoapps/mobile_api/testutils.py b/lms/djangoapps/mobile_api/testutils.py index 3739e5c0d10..b1af12a70e4 100644 --- a/lms/djangoapps/mobile_api/testutils.py +++ b/lms/djangoapps/mobile_api/testutils.py @@ -14,7 +14,7 @@ Test utilities for mobile API tests: import ddt import datetime from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils import timezone from mock import patch from opaque_keys.edx.keys import CourseKey diff --git a/lms/djangoapps/notes/models.py b/lms/djangoapps/notes/models.py index 60776d7b632..4515b272490 100644 --- a/lms/djangoapps/notes/models.py +++ b/lms/djangoapps/notes/models.py @@ -2,7 +2,7 @@ import json from django.contrib.auth.models import User from django.core.exceptions import ValidationError -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import models from django.utils.html import strip_tags from opaque_keys.edx.django.models import CourseKeyField diff --git a/lms/djangoapps/notes/tests.py b/lms/djangoapps/notes/tests.py index b32b99910d5..2ee2e263b35 100644 --- a/lms/djangoapps/notes/tests.py +++ b/lms/djangoapps/notes/tests.py @@ -6,7 +6,7 @@ import json from django.contrib.auth.models import User from django.core.exceptions import ValidationError -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import RequestFactory, TestCase from django.test.client import Client from mock import Mock, patch diff --git a/lms/djangoapps/notification_prefs/tests.py b/lms/djangoapps/notification_prefs/tests.py index 8aac28453e5..85bc646876c 100644 --- a/lms/djangoapps/notification_prefs/tests.py +++ b/lms/djangoapps/notification_prefs/tests.py @@ -2,7 +2,7 @@ import json from django.contrib.auth.models import AnonymousUser from django.core.exceptions import PermissionDenied -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404 from django.test import TestCase from django.test.client import RequestFactory diff --git a/lms/djangoapps/rss_proxy/tests/test_views.py b/lms/djangoapps/rss_proxy/tests/test_views.py index ae5abea07d2..2d89dccb0f6 100644 --- a/lms/djangoapps/rss_proxy/tests/test_views.py +++ b/lms/djangoapps/rss_proxy/tests/test_views.py @@ -1,7 +1,7 @@ """ Tests for the rss_proxy views """ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from mock import Mock, patch diff --git a/lms/djangoapps/shoppingcart/api.py b/lms/djangoapps/shoppingcart/api.py index b8157cab37e..f466bd61599 100644 --- a/lms/djangoapps/shoppingcart/api.py +++ b/lms/djangoapps/shoppingcart/api.py @@ -1,7 +1,7 @@ """ API for for getting information about the user's shopping cart. """ -from django.core.urlresolvers import reverse +from django.urls import reverse from shoppingcart.models import OrderItem from xmodule.modulestore.django import ModuleI18nService diff --git a/lms/djangoapps/shoppingcart/models.py b/lms/djangoapps/shoppingcart/models.py index 54edf2df702..809f08414d7 100644 --- a/lms/djangoapps/shoppingcart/models.py +++ b/lms/djangoapps/shoppingcart/models.py @@ -20,7 +20,7 @@ from django.contrib.auth.models import User from django.core.exceptions import ObjectDoesNotExist from django.core.mail import send_mail from django.core.mail.message import EmailMessage -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import models, transaction from django.db.models import Count, F, Q, Sum from django.db.models.signals import post_delete, post_save diff --git a/lms/djangoapps/shoppingcart/tests/test_configuration_overrides.py b/lms/djangoapps/shoppingcart/tests/test_configuration_overrides.py index 3ecfb38b955..ed9849a7408 100644 --- a/lms/djangoapps/shoppingcart/tests/test_configuration_overrides.py +++ b/lms/djangoapps/shoppingcart/tests/test_configuration_overrides.py @@ -2,7 +2,7 @@ """ Dashboard with Shopping Cart History tests with configuration overrides. """ -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import patch from course_modes.models import CourseMode diff --git a/lms/djangoapps/shoppingcart/tests/test_models.py b/lms/djangoapps/shoppingcart/tests/test_models.py index 6c085870aed..b64f786162e 100644 --- a/lms/djangoapps/shoppingcart/tests/test_models.py +++ b/lms/djangoapps/shoppingcart/tests/test_models.py @@ -15,7 +15,7 @@ from django.conf import settings from django.contrib.auth.models import AnonymousUser from django.core import mail from django.core.mail.message import EmailMessage -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import DatabaseError from django.test import TestCase from django.test.utils import override_settings diff --git a/lms/djangoapps/shoppingcart/tests/test_views.py b/lms/djangoapps/shoppingcart/tests/test_views.py index cc44487943c..ad34161f521 100644 --- a/lms/djangoapps/shoppingcart/tests/test_views.py +++ b/lms/djangoapps/shoppingcart/tests/test_views.py @@ -15,7 +15,7 @@ from django.contrib.auth.models import Group, User from django.contrib.messages.storage.fallback import FallbackStorage from django.core import mail from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpRequest from django.test import TestCase from django.test.utils import override_settings diff --git a/lms/djangoapps/shoppingcart/views.py b/lms/djangoapps/shoppingcart/views.py index 966790754f6..2781a8b947e 100644 --- a/lms/djangoapps/shoppingcart/views.py +++ b/lms/djangoapps/shoppingcart/views.py @@ -8,7 +8,7 @@ from config_models.decorators import require_config from django.conf import settings from django.contrib.auth.decorators import login_required from django.contrib.auth.models import Group -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db.models import Q from django.http import ( Http404, diff --git a/lms/djangoapps/static_template_view/tests/test_views.py b/lms/djangoapps/static_template_view/tests/test_views.py index ff062605d65..ed8f00e488a 100644 --- a/lms/djangoapps/static_template_view/tests/test_views.py +++ b/lms/djangoapps/static_template_view/tests/test_views.py @@ -2,7 +2,7 @@ Tests for static templates """ from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from openedx.core.djangoapps.site_configuration.tests.test_util import with_site_configuration_context diff --git a/lms/djangoapps/staticbook/tests.py b/lms/djangoapps/staticbook/tests.py index e4347f1618e..e8c62ac321e 100644 --- a/lms/djangoapps/staticbook/tests.py +++ b/lms/djangoapps/staticbook/tests.py @@ -6,7 +6,7 @@ import textwrap import mock import requests -from django.core.urlresolvers import NoReverseMatch, reverse +from django.urls import NoReverseMatch, reverse from six import text_type from student.tests.factories import CourseEnrollmentFactory, UserFactory diff --git a/lms/djangoapps/student_account/test/test_views.py b/lms/djangoapps/student_account/test/test_views.py index e5f2b207ec7..30b69f69835 100644 --- a/lms/djangoapps/student_account/test/test_views.py +++ b/lms/djangoapps/student_account/test/test_views.py @@ -17,7 +17,7 @@ from django.contrib.messages.middleware import MessageMiddleware from django.contrib.sessions.middleware import SessionMiddleware from django.core import mail from django.core.files.uploadedfile import SimpleUploadedFile -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpRequest from django.test import TestCase from django.test.client import RequestFactory diff --git a/lms/djangoapps/student_account/views.py b/lms/djangoapps/student_account/views.py index 38f9be8d994..bec05327cea 100644 --- a/lms/djangoapps/student_account/views.py +++ b/lms/djangoapps/student_account/views.py @@ -10,7 +10,7 @@ from django.contrib import messages from django.contrib.auth import get_user_model from django.contrib.auth.decorators import login_required from django.contrib.sites.models import Site -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpRequest, HttpResponse, HttpResponseBadRequest, HttpResponseForbidden from django.shortcuts import redirect from django.utils.translation import ugettext as _ diff --git a/lms/djangoapps/support/tests/test_views.py b/lms/djangoapps/support/tests/test_views.py index 587f112630b..0e778930a92 100644 --- a/lms/djangoapps/support/tests/test_views.py +++ b/lms/djangoapps/support/tests/test_views.py @@ -11,7 +11,7 @@ from datetime import datetime, timedelta import ddt import pytest from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db.models import signals from nose.plugins.attrib import attr from pytz import UTC diff --git a/lms/djangoapps/support/views/enrollments.py b/lms/djangoapps/support/views/enrollments.py index 87e4041f2fb..c6f7fcdcd86 100644 --- a/lms/djangoapps/support/views/enrollments.py +++ b/lms/djangoapps/support/views/enrollments.py @@ -2,7 +2,7 @@ Support tool for changing course enrollments. """ from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import transaction from django.db.models import Q from django.http import HttpResponseBadRequest diff --git a/lms/djangoapps/support/views/index.py b/lms/djangoapps/support/views/index.py index 4bc51d0b1dc..8b6630fe5ef 100644 --- a/lms/djangoapps/support/views/index.py +++ b/lms/djangoapps/support/views/index.py @@ -1,7 +1,7 @@ """ Index view for the support app. """ -from django.core.urlresolvers import reverse_lazy +from django.urls import reverse_lazy from django.utils.translation import ugettext_lazy as _ from edxmako.shortcuts import render_to_response diff --git a/lms/djangoapps/support/views/manage_user.py b/lms/djangoapps/support/views/manage_user.py index 17101299ac5..02ce16ef5f0 100644 --- a/lms/djangoapps/support/views/manage_user.py +++ b/lms/djangoapps/support/views/manage_user.py @@ -2,7 +2,7 @@ Support tool for disabling user accounts. """ from django.contrib.auth import get_user_model -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db.models import Q from django.utils.decorators import method_decorator from django.utils.translation import ugettext as _ diff --git a/lms/djangoapps/survey/tests/test_views.py b/lms/djangoapps/survey/tests/test_views.py index 61438f24204..6e1e5bde0e9 100644 --- a/lms/djangoapps/survey/tests/test_views.py +++ b/lms/djangoapps/survey/tests/test_views.py @@ -5,7 +5,7 @@ Python tests for the Survey views import json from collections import OrderedDict -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import Client from student.tests.factories import UserFactory diff --git a/lms/djangoapps/survey/views.py b/lms/djangoapps/survey/views.py index db54ddf8917..93fe837014c 100644 --- a/lms/djangoapps/survey/views.py +++ b/lms/djangoapps/survey/views.py @@ -7,7 +7,7 @@ import logging from django.conf import settings from django.contrib.auth.decorators import login_required -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpResponse, HttpResponseNotFound, HttpResponseRedirect from django.utils.html import escape from django.views.decorators.http import require_POST diff --git a/lms/djangoapps/teams/tests/test_views.py b/lms/djangoapps/teams/tests/test_views.py index 36a0e55adfc..6000d5b39c3 100644 --- a/lms/djangoapps/teams/tests/test_views.py +++ b/lms/djangoapps/teams/tests/test_views.py @@ -9,7 +9,7 @@ import pytest import pytz from dateutil import parser from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db.models.signals import post_save from django.utils import translation from elasticsearch.exceptions import ConnectionError diff --git a/lms/djangoapps/verify_student/models.py b/lms/djangoapps/verify_student/models.py index 6502e680065..29dc0dc9c3b 100644 --- a/lms/djangoapps/verify_student/models.py +++ b/lms/djangoapps/verify_student/models.py @@ -25,7 +25,7 @@ from django.contrib.contenttypes.fields import GenericForeignKey from django.contrib.contenttypes.models import ContentType from django.core.cache import cache from django.core.files.base import ContentFile -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import models from django.dispatch import receiver from django.utils.functional import cached_property diff --git a/lms/djangoapps/verify_student/services.py b/lms/djangoapps/verify_student/services.py index 3105db64dbb..8e8cbc026a8 100644 --- a/lms/djangoapps/verify_student/services.py +++ b/lms/djangoapps/verify_student/services.py @@ -6,7 +6,7 @@ import logging from itertools import chain from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from course_modes.models import CourseMode diff --git a/lms/djangoapps/verify_student/tests/fake_software_secure.py b/lms/djangoapps/verify_student/tests/fake_software_secure.py index fab26690d25..cbae6181e82 100644 --- a/lms/djangoapps/verify_student/tests/fake_software_secure.py +++ b/lms/djangoapps/verify_student/tests/fake_software_secure.py @@ -4,7 +4,7 @@ Fake Software Secure page for use in acceptance tests. from django.conf import settings from django.contrib.auth.decorators import login_required -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.decorators import method_decorator from django.views.generic.base import View diff --git a/lms/djangoapps/verify_student/tests/test_integration.py b/lms/djangoapps/verify_student/tests/test_integration.py index 35d5ef23c32..7c8eec40cb1 100644 --- a/lms/djangoapps/verify_student/tests/test_integration.py +++ b/lms/djangoapps/verify_student/tests/test_integration.py @@ -2,7 +2,7 @@ Integration tests of the payment flow, including course mode selection. """ -from django.core.urlresolvers import reverse +from django.urls import reverse from course_modes.tests.factories import CourseModeFactory from student.models import CourseEnrollment diff --git a/lms/djangoapps/verify_student/tests/test_views.py b/lms/djangoapps/verify_student/tests/test_views.py index 2b8882adf53..d9c1416c718 100644 --- a/lms/djangoapps/verify_student/tests/test_views.py +++ b/lms/djangoapps/verify_student/tests/test_views.py @@ -18,7 +18,7 @@ import requests from bs4 import BeautifulSoup from django.conf import settings from django.core import mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.client import Client, RequestFactory from django.test.utils import override_settings diff --git a/lms/djangoapps/verify_student/views.py b/lms/djangoapps/verify_student/views.py index b81c86dfc15..7d2a63e4204 100644 --- a/lms/djangoapps/verify_student/views.py +++ b/lms/djangoapps/verify_student/views.py @@ -13,7 +13,7 @@ from django.conf import settings from django.contrib.auth.decorators import login_required from django.contrib.staticfiles.storage import staticfiles_storage from django.core.mail import send_mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import transaction from django.http import Http404, HttpResponse, HttpResponseBadRequest from django.shortcuts import redirect diff --git a/lms/lib/courseware_search/lms_result_processor.py b/lms/lib/courseware_search/lms_result_processor.py index 633528c03ec..89e1fa0d00b 100644 --- a/lms/lib/courseware_search/lms_result_processor.py +++ b/lms/lib/courseware_search/lms_result_processor.py @@ -3,7 +3,7 @@ This file contains implementation override of SearchResultProcessor which will a * Blends in "location" property * Confirms user access to object """ -from django.core.urlresolvers import reverse +from django.urls import reverse from opaque_keys.edx.keys import CourseKey, UsageKey from search.result_processor import SearchResultProcessor diff --git a/lms/templates/api_admin/catalogs/edit.html b/lms/templates/api_admin/catalogs/edit.html index f66590d332c..a12dca712ba 100644 --- a/lms/templates/api_admin/catalogs/edit.html +++ b/lms/templates/api_admin/catalogs/edit.html @@ -2,7 +2,7 @@ <%page expression_filter="h"/> <%inherit file="../../main.html"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/api_admin/catalogs/list.html b/lms/templates/api_admin/catalogs/list.html index ddf20f3159c..843b7102942 100644 --- a/lms/templates/api_admin/catalogs/list.html +++ b/lms/templates/api_admin/catalogs/list.html @@ -2,7 +2,7 @@ <%page expression_filter="h"/> <%inherit file="../../main.html"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/api_admin/catalogs/search.html b/lms/templates/api_admin/catalogs/search.html index 36db13b7e08..9b3d2881ea0 100644 --- a/lms/templates/api_admin/catalogs/search.html +++ b/lms/templates/api_admin/catalogs/search.html @@ -2,7 +2,7 @@ <%page expression_filter="h"/> <%inherit file="../../main.html"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/api_admin/terms_of_service.html b/lms/templates/api_admin/terms_of_service.html index 1bbcac0a29e..82bb53bd406 100644 --- a/lms/templates/api_admin/terms_of_service.html +++ b/lms/templates/api_admin/terms_of_service.html @@ -2,7 +2,7 @@ <%page expression_filter="h"/> <%inherit file="../main.html"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/bookmark_button.html b/lms/templates/bookmark_button.html index 21fe05420e3..57cba749dd3 100644 --- a/lms/templates/bookmark_button.html +++ b/lms/templates/bookmark_button.html @@ -1,7 +1,7 @@ <%page expression_filter="h" args="bookmark_id, is_bookmarked" /> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/calculator/toggle_calculator.html b/lms/templates/calculator/toggle_calculator.html index 287e090cd1e..3a080164435 100644 --- a/lms/templates/calculator/toggle_calculator.html +++ b/lms/templates/calculator/toggle_calculator.html @@ -2,7 +2,7 @@ <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.markup import HTML, Text %> diff --git a/lms/templates/ccx/coach_dashboard.html b/lms/templates/ccx/coach_dashboard.html index acea0a12f25..498a8d583a1 100644 --- a/lms/templates/ccx/coach_dashboard.html +++ b/lms/templates/ccx/coach_dashboard.html @@ -3,7 +3,7 @@ <%namespace name='static' file='/static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.js_utils import ( dump_js_escaped_json, js_escaped_string ) diff --git a/lms/templates/class_dashboard/all_section_metrics.js b/lms/templates/class_dashboard/all_section_metrics.js index 16c8f89c422..05edde730fb 100644 --- a/lms/templates/class_dashboard/all_section_metrics.js +++ b/lms/templates/class_dashboard/all_section_metrics.js @@ -1,7 +1,7 @@ <%page args="id_opened_prefix, id_grade_prefix, id_attempt_prefix, id_tooltip_prefix, course_id, allSubsectionTooltipArr, allProblemTooltipArr, **kwargs"/> <%! import json - from django.core.urlresolvers import reverse + from django.urls import reverse from six import text_type %> @@ -105,4 +105,4 @@ $(function () { }); -}); \ No newline at end of file +}); diff --git a/lms/templates/conditional_module.html b/lms/templates/conditional_module.html index a35a822bcb0..a4667b8b661 100644 --- a/lms/templates/conditional_module.html +++ b/lms/templates/conditional_module.html @@ -1,5 +1,5 @@ <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from six import text_type %> diff --git a/lms/templates/course.html b/lms/templates/course.html index 1d438e59683..295101da824 100644 --- a/lms/templates/course.html +++ b/lms/templates/course.html @@ -2,7 +2,7 @@ <%namespace name='static' file='static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from six import text_type %> <%page args="course" expression_filter="h"/> diff --git a/lms/templates/course_modes/choose.html b/lms/templates/course_modes/choose.html index 05551831633..9d0cafd9d7f 100644 --- a/lms/templates/course_modes/choose.html +++ b/lms/templates/course_modes/choose.html @@ -2,7 +2,7 @@ <%inherit file="../main.html" /> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.js_utils import js_escaped_string from openedx.core.djangolib.markup import HTML, Text %> diff --git a/lms/templates/courseware/accordion.html b/lms/templates/courseware/accordion.html index 0fd6c9a4c3f..a1a3e1290bf 100644 --- a/lms/templates/courseware/accordion.html +++ b/lms/templates/courseware/accordion.html @@ -1,7 +1,7 @@ <%page expression_filter="h"/> <%namespace name='static' file='../static_content.html'/> <%! - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ from django.conf import settings from openedx.core.djangolib.markup import HTML, Text diff --git a/lms/templates/courseware/course_about.html b/lms/templates/courseware/course_about.html index d9b495df892..6fb28f0084b 100644 --- a/lms/templates/courseware/course_about.html +++ b/lms/templates/courseware/course_about.html @@ -2,7 +2,7 @@ <%! from django.utils.translation import ugettext as _ from django.utils.translation import pgettext -from django.core.urlresolvers import reverse +from django.urls import reverse from courseware.courses import get_course_about_section from django.conf import settings from six import text_type diff --git a/lms/templates/courseware/course_about_sidebar_header.html b/lms/templates/courseware/course_about_sidebar_header.html index 520226b75e9..ee39af0a65a 100644 --- a/lms/templates/courseware/course_about_sidebar_header.html +++ b/lms/templates/courseware/course_about_sidebar_header.html @@ -3,7 +3,7 @@ import urllib from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.conf import settings from six import text_type %> diff --git a/lms/templates/courseware/course_navigation.html b/lms/templates/courseware/course_navigation.html index 8babf99804b..141957db04b 100644 --- a/lms/templates/courseware/course_navigation.html +++ b/lms/templates/courseware/course_navigation.html @@ -6,7 +6,7 @@ <%! from courseware.tabs import get_course_tab_list from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/courseware/courseware.html b/lms/templates/courseware/courseware.html index c54a73e2c5c..77ae67c3c04 100644 --- a/lms/templates/courseware/courseware.html +++ b/lms/templates/courseware/courseware.html @@ -6,7 +6,7 @@ import waffle from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from edxnotes.helpers import is_feature_enabled as is_edxnotes_enabled diff --git a/lms/templates/courseware/gradebook.html b/lms/templates/courseware/gradebook.html index db1545b8a2e..ebf1b5586b6 100644 --- a/lms/templates/courseware/gradebook.html +++ b/lms/templates/courseware/gradebook.html @@ -2,7 +2,7 @@ <%namespace name='static' file='/static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from six import text_type %> diff --git a/lms/templates/courseware/info.html b/lms/templates/courseware/info.html index 1798241d29f..29067cfecbf 100644 --- a/lms/templates/courseware/info.html +++ b/lms/templates/courseware/info.html @@ -6,7 +6,7 @@ from datetime import datetime from pytz import timezone, utc -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from courseware.courses import get_course_info_section, get_course_date_blocks diff --git a/lms/templates/courseware/program_marketing.html b/lms/templates/courseware/program_marketing.html index 3103147bd5d..8889d054ac9 100644 --- a/lms/templates/courseware/program_marketing.html +++ b/lms/templates/courseware/program_marketing.html @@ -5,7 +5,7 @@ <%! from datetime import datetime -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from mako import exceptions diff --git a/lms/templates/courseware/progress.html b/lms/templates/courseware/progress.html index f80738146b2..1ea48d838bc 100644 --- a/lms/templates/courseware/progress.html +++ b/lms/templates/courseware/progress.html @@ -7,7 +7,7 @@ from course_modes.models import CourseMode from lms.djangoapps.certificates.models import CertificateStatuses from django.utils.translation import ugettext as _ from openedx.core.djangolib.markup import HTML, Text -from django.core.urlresolvers import reverse +from django.urls import reverse from django.conf import settings from django.utils.http import urlquote_plus from six import text_type diff --git a/lms/templates/courseware/tabs.html b/lms/templates/courseware/tabs.html index bf68f8baad4..8dd79f22bb5 100644 --- a/lms/templates/courseware/tabs.html +++ b/lms/templates/courseware/tabs.html @@ -3,7 +3,7 @@ <%namespace name='static' file='/static_content.html'/> <%! from django.utils.translation import ugettext as _ - from django.core.urlresolvers import reverse + from django.urls import reverse %> <%page args="tab_list, active_page, default_tab, tab_image" expression_filter="h" /> diff --git a/lms/templates/dashboard.html b/lms/templates/dashboard.html index 5369c2e9f27..1fc45e6c1ec 100644 --- a/lms/templates/dashboard.html +++ b/lms/templates/dashboard.html @@ -5,7 +5,7 @@ <%! import pytz from datetime import datetime, timedelta -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from django.template import RequestContext from entitlements.models import CourseEntitlement diff --git a/lms/templates/dashboard/_dashboard_course_listing.html b/lms/templates/dashboard/_dashboard_course_listing.html index 17628ff53b2..680bd640c93 100644 --- a/lms/templates/dashboard/_dashboard_course_listing.html +++ b/lms/templates/dashboard/_dashboard_course_listing.html @@ -5,7 +5,7 @@ import urllib from django.utils.translation import ugettext as _ from django.utils.translation import ungettext -from django.core.urlresolvers import reverse +from django.urls import reverse from course_modes.models import CourseMode from course_modes.helpers import enrollment_mode_display from openedx.core.djangolib.js_utils import dump_js_escaped_json, js_escaped_string diff --git a/lms/templates/dashboard/_dashboard_entitlement_actions.html b/lms/templates/dashboard/_dashboard_entitlement_actions.html index 5316c536487..0c3a61c0287 100644 --- a/lms/templates/dashboard/_dashboard_entitlement_actions.html +++ b/lms/templates/dashboard/_dashboard_entitlement_actions.html @@ -2,7 +2,7 @@ <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <% diff --git a/lms/templates/dashboard/_dashboard_status_verification.html b/lms/templates/dashboard/_dashboard_status_verification.html index 8ed8899a8f6..fa7e09c5676 100644 --- a/lms/templates/dashboard/_dashboard_status_verification.html +++ b/lms/templates/dashboard/_dashboard_status_verification.html @@ -1,7 +1,7 @@ <%page expression_filter="h"/> <%namespace name='static' file='../static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/edxnotes/toggle_notes.html b/lms/templates/edxnotes/toggle_notes.html index 90ef42b2206..47533dcee43 100644 --- a/lms/templates/edxnotes/toggle_notes.html +++ b/lms/templates/edxnotes/toggle_notes.html @@ -1,7 +1,7 @@ <%page args="course" expression_filter="h"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.js_utils import dump_js_escaped_json, js_escaped_string %> <%namespace name='static' file='/static_content.html'/> diff --git a/lms/templates/email_change_successful.html b/lms/templates/email_change_successful.html index 764e58576f9..b58972785c7 100644 --- a/lms/templates/email_change_successful.html +++ b/lms/templates/email_change_successful.html @@ -1,7 +1,7 @@ <%inherit file="main.html" /> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <section class="container activation"> diff --git a/lms/templates/emails/confirm_email_change.txt b/lms/templates/emails/confirm_email_change.txt index 2890c54f483..8f5df7083e2 100644 --- a/lms/templates/emails/confirm_email_change.txt +++ b/lms/templates/emails/confirm_email_change.txt @@ -1,4 +1,4 @@ -<%! from django.core.urlresolvers import reverse %> +<%! from django.urls import reverse %> <%! from django.utils.translation import ugettext as _ %> <%! from openedx.core.djangoapps.site_configuration import helpers as configuration_helpers %> <%! from edxmako.shortcuts import render_to_string, marketing_link %> diff --git a/lms/templates/financial-assistance/financial-assistance.html b/lms/templates/financial-assistance/financial-assistance.html index c6582ec240e..3418260d2ac 100644 --- a/lms/templates/financial-assistance/financial-assistance.html +++ b/lms/templates/financial-assistance/financial-assistance.html @@ -1,6 +1,6 @@ <%inherit file="../main.html"/> <% -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from edxmako.shortcuts import marketing_link diff --git a/lms/templates/footer.html b/lms/templates/footer.html index 743599be27f..bf76031d26d 100644 --- a/lms/templates/footer.html +++ b/lms/templates/footer.html @@ -1,7 +1,7 @@ ## mako <%page expression_filter="h"/> <%! - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ from branding.api import get_footer from openedx.core.djangoapps.lang_pref.api import footer_language_selector_is_enabled diff --git a/lms/templates/forgot_password_modal.html b/lms/templates/forgot_password_modal.html index a18db5db4a1..15e6bd362a4 100644 --- a/lms/templates/forgot_password_modal.html +++ b/lms/templates/forgot_password_modal.html @@ -2,7 +2,7 @@ <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <section id="forgot-password-modal" class="modal" role="dialog" tabindex="-1" aria-label="${_('Password Reset')}"> diff --git a/lms/templates/header/brand.html b/lms/templates/header/brand.html index c5cd260ea8c..2ad7c3d9de4 100644 --- a/lms/templates/header/brand.html +++ b/lms/templates/header/brand.html @@ -5,7 +5,7 @@ <%namespace name='static' file='/static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangoapps.site_configuration import helpers as configuration_helpers diff --git a/lms/templates/header/header.html b/lms/templates/header/header.html index 94cbcb1ca49..82a36cdb18c 100644 --- a/lms/templates/header/header.html +++ b/lms/templates/header/header.html @@ -5,7 +5,7 @@ <%namespace name='static' file='../static_content.html'/> <%namespace file='../main.html' import="login_query"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from lms.djangoapps.ccx.overrides import get_current_ccx diff --git a/lms/templates/header/navbar-authenticated.html b/lms/templates/header/navbar-authenticated.html index d4f180d883a..332522828ac 100644 --- a/lms/templates/header/navbar-authenticated.html +++ b/lms/templates/header/navbar-authenticated.html @@ -5,7 +5,7 @@ <%namespace name='static' file='../static_content.html'/> <%namespace file='../main.html' import="login_query"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangoapps.site_configuration import helpers as configuration_helpers %> diff --git a/lms/templates/header/navbar-logo-header.html b/lms/templates/header/navbar-logo-header.html index 36f729f38b9..933e4c25710 100644 --- a/lms/templates/header/navbar-logo-header.html +++ b/lms/templates/header/navbar-logo-header.html @@ -4,7 +4,7 @@ <%namespace name='static' file='../static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from lms.djangoapps.ccx.overrides import get_current_ccx from openedx.core.djangoapps.site_configuration import helpers as configuration_helpers diff --git a/lms/templates/header/navbar-not-authenticated.html b/lms/templates/header/navbar-not-authenticated.html index 0d6889c4c52..9dbcf2d6af0 100644 --- a/lms/templates/header/navbar-not-authenticated.html +++ b/lms/templates/header/navbar-not-authenticated.html @@ -6,7 +6,7 @@ <%namespace file='../main.html' import="login_query"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from six import text_type %> diff --git a/lms/templates/header/user_dropdown.html b/lms/templates/header/user_dropdown.html index 73bb1e8820f..675ccc320c8 100644 --- a/lms/templates/header/user_dropdown.html +++ b/lms/templates/header/user_dropdown.html @@ -3,7 +3,7 @@ <%namespace name='static' file='static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangoapps.user_api.accounts.image_helpers import get_profile_image_urls_for_user diff --git a/lms/templates/help_modal.html b/lms/templates/help_modal.html index e1a4c34dba0..13703d2a431 100644 --- a/lms/templates/help_modal.html +++ b/lms/templates/help_modal.html @@ -6,7 +6,7 @@ from datetime import datetime import pytz from django.conf import settings from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.js_utils import js_escaped_string from openedx.core.djangolib.markup import HTML, Text from xmodule.tabs import CourseTabList diff --git a/lms/templates/index.html b/lms/templates/index.html index c06fe4f0006..09c77faf7ce 100644 --- a/lms/templates/index.html +++ b/lms/templates/index.html @@ -3,7 +3,7 @@ <%namespace name='static' file='static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.markup import HTML, Text %> diff --git a/lms/templates/instructor/instructor_dashboard_2/add_coupon_modal.html b/lms/templates/instructor/instructor_dashboard_2/add_coupon_modal.html index 14760bd69bb..28008c6834b 100644 --- a/lms/templates/instructor/instructor_dashboard_2/add_coupon_modal.html +++ b/lms/templates/instructor/instructor_dashboard_2/add_coupon_modal.html @@ -1,7 +1,7 @@ <%page args="section_data" expression_filter="h"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <section id="add-coupon-modal" class="modal" role="dialog" tabindex="-1" aria-labelledby="header-coupon-code"> <h2 id="header-coupon-code" class="hd hd-2">${_("Add Coupon Code")}</h2> diff --git a/lms/templates/instructor/instructor_dashboard_2/edit_coupon_modal.html b/lms/templates/instructor/instructor_dashboard_2/edit_coupon_modal.html index e59d3608636..38d11f282c2 100644 --- a/lms/templates/instructor/instructor_dashboard_2/edit_coupon_modal.html +++ b/lms/templates/instructor/instructor_dashboard_2/edit_coupon_modal.html @@ -1,7 +1,7 @@ <%page args="section_data" expression_filter="h"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <section id="edit-coupon-modal" class="modal" role="dialog" tabindex="-1" aria-labelledby="header-edit-coupon-code"> <h2 id="header-edit-coupon-code" class="hd hd-2">${_("Edit Coupon Code")}</h2> diff --git a/lms/templates/instructor/instructor_dashboard_2/generate_registarion_codes_modal.html b/lms/templates/instructor/instructor_dashboard_2/generate_registarion_codes_modal.html index 1c2120be78e..4c81c080dec 100644 --- a/lms/templates/instructor/instructor_dashboard_2/generate_registarion_codes_modal.html +++ b/lms/templates/instructor/instructor_dashboard_2/generate_registarion_codes_modal.html @@ -1,7 +1,7 @@ <%page args="section_data" expression_filter="h"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <section id="registration_code_generation_modal" class="modal" role="dialog" tabindex="-1" aria-labelledby="header-registration-code"> <h2 id="header-registration-code" class="hd hd-2">${_("Generate Registration Code Modal")}</h2> diff --git a/lms/templates/instructor/instructor_dashboard_2/instructor_dashboard_2.html b/lms/templates/instructor/instructor_dashboard_2/instructor_dashboard_2.html index bf0f6e83f1c..a42547bcc66 100644 --- a/lms/templates/instructor/instructor_dashboard_2/instructor_dashboard_2.html +++ b/lms/templates/instructor/instructor_dashboard_2/instructor_dashboard_2.html @@ -4,7 +4,7 @@ <%def name="online_help_token()"><% return "instructor" %></%def> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.markup import HTML %> <%block name="bodyclass">view-in-course view-instructordash</%block> diff --git a/lms/templates/instructor/instructor_dashboard_2/invalidate_registration_code_modal.html b/lms/templates/instructor/instructor_dashboard_2/invalidate_registration_code_modal.html index bb5a5d6a3ec..3275681faa4 100644 --- a/lms/templates/instructor/instructor_dashboard_2/invalidate_registration_code_modal.html +++ b/lms/templates/instructor/instructor_dashboard_2/invalidate_registration_code_modal.html @@ -1,6 +1,6 @@ <%page args="section_data" expression_filter="h"/> <%! from django.utils.translation import ugettext as _ %> -<%! from django.core.urlresolvers import reverse %> +<%! from django.urls import reverse %> <section id="invalidate_registration_code_modal" class="modal" role="dialog" tabindex="-1" aria-labelledby="header-enrollment-code-status"> <h2 id="header-enrollment-code-status" class="hd hd-2">${_("Enrollment Code Status")}</h2> <div class="inner-wrapper"> diff --git a/lms/templates/instructor/instructor_dashboard_2/set_course_mode_price_modal.html b/lms/templates/instructor/instructor_dashboard_2/set_course_mode_price_modal.html index 928102819c3..0b30fec6a3d 100644 --- a/lms/templates/instructor/instructor_dashboard_2/set_course_mode_price_modal.html +++ b/lms/templates/instructor/instructor_dashboard_2/set_course_mode_price_modal.html @@ -1,7 +1,7 @@ <%page args="section_data" expression_filter="h"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <section id="set-course-mode-price-modal" class="modal" role="dialog" tabindex="-1" aria-labelledby="header-course-price"> <h2 id="header-course-price" class="hd hd-2">${_("Set Course Mode Price")}</h2> diff --git a/lms/templates/login-sidebar.html b/lms/templates/login-sidebar.html index e6c28506934..9577724ec6b 100644 --- a/lms/templates/login-sidebar.html +++ b/lms/templates/login-sidebar.html @@ -1,6 +1,6 @@ <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <header> diff --git a/lms/templates/login.html b/lms/templates/login.html index bd8060685f4..ad273585300 100644 --- a/lms/templates/login.html +++ b/lms/templates/login.html @@ -2,7 +2,7 @@ <%namespace name='static' file='static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ import third_party_auth from third_party_auth import provider, pipeline diff --git a/lms/templates/main.html b/lms/templates/main.html index e35290e5621..019d8384352 100644 --- a/lms/templates/main.html +++ b/lms/templates/main.html @@ -14,7 +14,7 @@ <% online_help_token = self.online_help_token() if hasattr(self, 'online_help_token') else None %> <%! from branding import api as branding_api -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.http import urlquote_plus from django.utils.translation import ugettext as _ from django.utils.translation import get_language_bidi diff --git a/lms/templates/manage_user_standing.html b/lms/templates/manage_user_standing.html index 0e096504b5e..fed5fd75419 100644 --- a/lms/templates/manage_user_standing.html +++ b/lms/templates/manage_user_standing.html @@ -1,7 +1,7 @@ <%inherit file="main.html" /> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/modal/_modal-settings-language.html b/lms/templates/modal/_modal-settings-language.html index 0a3055c7ed2..8c50d0e3ef6 100644 --- a/lms/templates/modal/_modal-settings-language.html +++ b/lms/templates/modal/_modal-settings-language.html @@ -1,7 +1,7 @@ <%namespace name='static' file='../static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <section id="change_language" class="modal modal-settings-language" aria-hidden="true"> diff --git a/lms/templates/navigation/bootstrap/navbar-authenticated.html b/lms/templates/navigation/bootstrap/navbar-authenticated.html index 6cf6f7e46ef..1d9c27a0304 100644 --- a/lms/templates/navigation/bootstrap/navbar-authenticated.html +++ b/lms/templates/navigation/bootstrap/navbar-authenticated.html @@ -5,7 +5,7 @@ <%namespace name='static' file='../../static_content.html'/> <%namespace file='../../main.html' import="login_query"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/navigation/navbar-authenticated.html b/lms/templates/navigation/navbar-authenticated.html index b62b36d7d3c..8c4846ab162 100644 --- a/lms/templates/navigation/navbar-authenticated.html +++ b/lms/templates/navigation/navbar-authenticated.html @@ -5,7 +5,7 @@ <%namespace name='static' file='../static_content.html'/> <%namespace file='../main.html' import="login_query"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/navigation/navbar-logo-header.html b/lms/templates/navigation/navbar-logo-header.html index 49aa321a98c..487cac1fa7f 100644 --- a/lms/templates/navigation/navbar-logo-header.html +++ b/lms/templates/navigation/navbar-logo-header.html @@ -4,7 +4,7 @@ <%namespace name='static' file='../static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from lms.djangoapps.ccx.overrides import get_current_ccx from openedx.core.djangoapps.site_configuration import helpers as configuration_helpers diff --git a/lms/templates/navigation/navbar-not-authenticated.html b/lms/templates/navigation/navbar-not-authenticated.html index f6c3828e768..b88c8866160 100644 --- a/lms/templates/navigation/navbar-not-authenticated.html +++ b/lms/templates/navigation/navbar-not-authenticated.html @@ -5,7 +5,7 @@ <%namespace name='static' file='../static_content.html'/> <%namespace file='../main.html' import="login_query"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from six import text_type %> diff --git a/lms/templates/navigation/navigation.html b/lms/templates/navigation/navigation.html index fa2202330f4..2e399419a99 100644 --- a/lms/templates/navigation/navigation.html +++ b/lms/templates/navigation/navigation.html @@ -9,7 +9,7 @@ <%namespace name='static' file='../static_content.html'/> <%namespace file='../main.html' import="login_query"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from lms.djangoapps.ccx.overrides import get_current_ccx diff --git a/lms/templates/notes.html b/lms/templates/notes.html index 137a85f9028..de7db780b13 100644 --- a/lms/templates/notes.html +++ b/lms/templates/notes.html @@ -5,7 +5,7 @@ ${static.css(group='style-vendor-tinymce-skin', raw=True)} ${static.css(group='style-xmodule-annotations', raw=True)} <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%block name="headextra"> diff --git a/lms/templates/provider/authorize.html b/lms/templates/provider/authorize.html index b6baa0fd0f9..8387c21b20b 100644 --- a/lms/templates/provider/authorize.html +++ b/lms/templates/provider/authorize.html @@ -5,7 +5,7 @@ <%! from django.utils.translation import ugettext as _ from provider.templatetags.scope import scopes -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.markup import HTML, Text %> diff --git a/lms/templates/register-shib.html b/lms/templates/register-shib.html index 5d89b72ffa1..9ec866e1180 100644 --- a/lms/templates/register-shib.html +++ b/lms/templates/register-shib.html @@ -3,7 +3,7 @@ <%namespace file='main.html' import="login_query"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils import html from django_countries import countries from student.models import UserProfile diff --git a/lms/templates/register-sidebar.html b/lms/templates/register-sidebar.html index 0482decd262..a3a43cfb33a 100644 --- a/lms/templates/register-sidebar.html +++ b/lms/templates/register-sidebar.html @@ -1,7 +1,7 @@ <%page expression_filter="h"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%namespace file='main.html' import="login_query"/> <%namespace name='static' file='static_content.html'/> diff --git a/lms/templates/register.html b/lms/templates/register.html index 1eaff34fe3a..b95c83304c1 100644 --- a/lms/templates/register.html +++ b/lms/templates/register.html @@ -3,7 +3,7 @@ <%namespace file='main.html' import="login_query"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils import html from django_countries import countries from student.models import UserProfile diff --git a/lms/templates/resubscribe.html b/lms/templates/resubscribe.html index e20d4ca5ca9..ac924d57ffb 100644 --- a/lms/templates/resubscribe.html +++ b/lms/templates/resubscribe.html @@ -1,5 +1,5 @@ <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from django.conf import settings %> diff --git a/lms/templates/shoppingcart/billing_details.html b/lms/templates/shoppingcart/billing_details.html index bb1620d331c..5b6de5d66a8 100644 --- a/lms/templates/shoppingcart/billing_details.html +++ b/lms/templates/shoppingcart/billing_details.html @@ -1,7 +1,7 @@ <%inherit file="shopping_cart_flow.html" /> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%block name="billing_details_highlight"><li class="active" >${_('Billing Details')}</li></%block> diff --git a/lms/templates/shoppingcart/download_report.html b/lms/templates/shoppingcart/download_report.html index 6e855a6ddca..83094091b11 100644 --- a/lms/templates/shoppingcart/download_report.html +++ b/lms/templates/shoppingcart/download_report.html @@ -1,7 +1,7 @@ <%inherit file="../main.html" /> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.conf import settings %> diff --git a/lms/templates/shoppingcart/error.html b/lms/templates/shoppingcart/error.html index e0fb8a35466..042fbf406a4 100644 --- a/lms/templates/shoppingcart/error.html +++ b/lms/templates/shoppingcart/error.html @@ -1,7 +1,7 @@ <%inherit file="../main.html" /> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%block name="pagetitle">${_("Payment Error")}</%block> diff --git a/lms/templates/shoppingcart/receipt.html b/lms/templates/shoppingcart/receipt.html index 4ae016b7735..c0a0870ebc4 100644 --- a/lms/templates/shoppingcart/receipt.html +++ b/lms/templates/shoppingcart/receipt.html @@ -4,7 +4,7 @@ <%! from django.utils.translation import ugettext as _ from django.utils.translation import ungettext -from django.core.urlresolvers import reverse +from django.urls import reverse from markupsafe import escape from openedx.core.lib.courses import course_image_url %> diff --git a/lms/templates/shoppingcart/registration_code_receipt.html b/lms/templates/shoppingcart/registration_code_receipt.html index 19943a154ce..d1cf6fd44b3 100644 --- a/lms/templates/shoppingcart/registration_code_receipt.html +++ b/lms/templates/shoppingcart/registration_code_receipt.html @@ -1,6 +1,6 @@ <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from six import text_type from openedx.core.lib.courses import course_image_url from openedx.features.course_experience import course_home_url_name diff --git a/lms/templates/shoppingcart/registration_code_redemption.html b/lms/templates/shoppingcart/registration_code_redemption.html index 266db3b9550..6ea7a9efb11 100644 --- a/lms/templates/shoppingcart/registration_code_redemption.html +++ b/lms/templates/shoppingcart/registration_code_redemption.html @@ -1,6 +1,6 @@ <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.lib.courses import course_image_url %> <%inherit file="../main.html" /> diff --git a/lms/templates/shoppingcart/shopping_cart.html b/lms/templates/shoppingcart/shopping_cart.html index edeeb1d36d8..2dc0ec793e4 100644 --- a/lms/templates/shoppingcart/shopping_cart.html +++ b/lms/templates/shoppingcart/shopping_cart.html @@ -2,7 +2,7 @@ <%block name="review_highlight">class="active"</%block> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from edxmako.shortcuts import marketing_link from django.utils.translation import ugettext as _ from django.utils.translation import ungettext diff --git a/lms/templates/signup_modal.html b/lms/templates/signup_modal.html index 4fa8da2b186..0b5cc19f1bd 100644 --- a/lms/templates/signup_modal.html +++ b/lms/templates/signup_modal.html @@ -1,7 +1,7 @@ <%namespace name='static' file='static_content.html'/> <%! from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django_countries import countries from student.models import UserProfile from datetime import date diff --git a/lms/templates/student_account/account_settings.html b/lms/templates/student_account/account_settings.html index 831ba7e7559..ffc83b1f94b 100644 --- a/lms/templates/student_account/account_settings.html +++ b/lms/templates/student_account/account_settings.html @@ -3,7 +3,7 @@ <%! import json -from django.core.urlresolvers import reverse +from django.urls import reverse from django.conf import settings from django.utils.translation import ugettext as _ diff --git a/lms/templates/support/certificates.html b/lms/templates/support/certificates.html index 8022e6ccd80..29aa102f93d 100644 --- a/lms/templates/support/certificates.html +++ b/lms/templates/support/certificates.html @@ -1,5 +1,5 @@ <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> <%namespace name='static' file='../static_content.html'/> diff --git a/lms/templates/support/contact_us.html b/lms/templates/support/contact_us.html index 9f8ce914a99..dbdb93171fe 100644 --- a/lms/templates/support/contact_us.html +++ b/lms/templates/support/contact_us.html @@ -1,7 +1,7 @@ <%page expression_filter="h"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangolib.js_utils import js_escaped_string, dump_js_escaped_json diff --git a/lms/templates/support/index.html b/lms/templates/support/index.html index ec25d7c175c..b270deb22f1 100644 --- a/lms/templates/support/index.html +++ b/lms/templates/support/index.html @@ -1,6 +1,6 @@ ## mako <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> <%namespace name='static' file='../static_content.html'/> diff --git a/lms/templates/survey/survey.html b/lms/templates/survey/survey.html index 04f7a1d8155..be9c5a0f810 100644 --- a/lms/templates/survey/survey.html +++ b/lms/templates/survey/survey.html @@ -3,7 +3,7 @@ <%namespace name='static' file='../static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils import html from openedx.core.djangolib.markup import Text, HTML %> diff --git a/lms/templates/sysadmin_dashboard.html b/lms/templates/sysadmin_dashboard.html index 043522e8990..90d3a554e23 100644 --- a/lms/templates/sysadmin_dashboard.html +++ b/lms/templates/sysadmin_dashboard.html @@ -1,7 +1,7 @@ <%inherit file="/main.html" /> <%namespace name='static' file='/static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/templates/sysadmin_dashboard_gitlogs.html b/lms/templates/sysadmin_dashboard_gitlogs.html index df1f571553a..19ee0304412 100644 --- a/lms/templates/sysadmin_dashboard_gitlogs.html +++ b/lms/templates/sysadmin_dashboard_gitlogs.html @@ -1,6 +1,6 @@ <%inherit file="/main.html" /> <%! - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ from django.utils.timezone import utc as UTC from util.date_utils import get_time_display, DEFAULT_DATE_TIME_FORMAT diff --git a/lms/templates/unsubscribe.html b/lms/templates/unsubscribe.html index b065476ac5c..f4db2a39def 100644 --- a/lms/templates/unsubscribe.html +++ b/lms/templates/unsubscribe.html @@ -1,7 +1,7 @@ <%page expression_filter="h"/> <%! from openedx.core.djangolib.markup import HTML, Text -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from django.conf import settings %> diff --git a/lms/templates/user_dropdown.html b/lms/templates/user_dropdown.html index 1deddfac924..43b2948ba97 100644 --- a/lms/templates/user_dropdown.html +++ b/lms/templates/user_dropdown.html @@ -3,7 +3,7 @@ <%namespace name='static' file='static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangoapps.user_api.accounts.image_helpers import get_profile_image_urls_for_user diff --git a/lms/templates/verify_student/reverify_not_allowed.html b/lms/templates/verify_student/reverify_not_allowed.html index a5d4b2c39f5..019ce416619 100644 --- a/lms/templates/verify_student/reverify_not_allowed.html +++ b/lms/templates/verify_student/reverify_not_allowed.html @@ -1,7 +1,7 @@ <%page expression_filter="h"/> <%! from django.utils.translation import ugettext as _ - from django.core.urlresolvers import reverse + from django.urls import reverse %> <%inherit file="../main.html" /> diff --git a/lms/templates/wiki/includes/article_menu.html b/lms/templates/wiki/includes/article_menu.html index a6d86084573..0c5fd0d0342 100644 --- a/lms/templates/wiki/includes/article_menu.html +++ b/lms/templates/wiki/includes/article_menu.html @@ -1,7 +1,7 @@ ## mako <%page expression_filter="h"/> <%! - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangolib.markup import HTML, Text from wiki.core.permissions import can_change_permissions diff --git a/lms/templates/wiki/includes/breadcrumbs.html b/lms/templates/wiki/includes/breadcrumbs.html index 6673a2c0295..3746d57ecc3 100644 --- a/lms/templates/wiki/includes/breadcrumbs.html +++ b/lms/templates/wiki/includes/breadcrumbs.html @@ -1,7 +1,7 @@ ## mako <%page expression_filter="h"/> <%! - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ %> diff --git a/lms/tests.py b/lms/tests.py index bbd44904034..49e08e99e95 100644 --- a/lms/tests.py +++ b/lms/tests.py @@ -3,7 +3,7 @@ import logging import mimetypes -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from mock import patch from six import text_type diff --git a/openedx/core/djangoapps/ace_common/template_context.py b/openedx/core/djangoapps/ace_common/template_context.py index 7ae2769823a..8a255e9df55 100644 --- a/openedx/core/djangoapps/ace_common/template_context.py +++ b/openedx/core/djangoapps/ace_common/template_context.py @@ -2,7 +2,7 @@ Context dictionary for templates that use the ace_common base template. """ from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from edxmako.shortcuts import marketing_link from openedx.core.djangoapps.theming.helpers import get_config_value_from_site_or_settings diff --git a/openedx/core/djangoapps/api_admin/admin.py b/openedx/core/djangoapps/api_admin/admin.py index 45add91f45d..c004449d39a 100644 --- a/openedx/core/djangoapps/api_admin/admin.py +++ b/openedx/core/djangoapps/api_admin/admin.py @@ -1,7 +1,7 @@ """Admin views for API managment.""" from config_models.admin import ConfigurationModelAdmin from django.contrib import admin -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangoapps.api_admin.models import ApiAccessConfig, ApiAccessRequest diff --git a/openedx/core/djangoapps/api_admin/decorators.py b/openedx/core/djangoapps/api_admin/decorators.py index 089f2cf2d29..ebabcd89e89 100644 --- a/openedx/core/djangoapps/api_admin/decorators.py +++ b/openedx/core/djangoapps/api_admin/decorators.py @@ -1,7 +1,7 @@ """Decorators for API access management.""" from functools import wraps -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpResponseNotFound from django.shortcuts import redirect diff --git a/openedx/core/djangoapps/api_admin/models.py b/openedx/core/djangoapps/api_admin/models.py index 94666e345d4..7e71564ab28 100644 --- a/openedx/core/djangoapps/api_admin/models.py +++ b/openedx/core/djangoapps/api_admin/models.py @@ -8,7 +8,7 @@ from django.conf import settings from django.contrib.auth.models import User from django.contrib.sites.models import Site from django.core.mail import send_mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import models from django.db.models.signals import post_save, pre_save from django.dispatch import receiver diff --git a/openedx/core/djangoapps/api_admin/tests/test_views.py b/openedx/core/djangoapps/api_admin/tests/test_views.py index 7e86f63fe87..2b818238a93 100644 --- a/openedx/core/djangoapps/api_admin/tests/test_views.py +++ b/openedx/core/djangoapps/api_admin/tests/test_views.py @@ -5,7 +5,7 @@ import json import ddt import httpretty from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.utils import override_settings from oauth2_provider.models import get_application_model diff --git a/openedx/core/djangoapps/api_admin/views.py b/openedx/core/djangoapps/api_admin/views.py index ca8fb2390c7..7dfa37199cd 100644 --- a/openedx/core/djangoapps/api_admin/views.py +++ b/openedx/core/djangoapps/api_admin/views.py @@ -3,7 +3,7 @@ import logging from django.conf import settings from django.contrib.sites.shortcuts import get_current_site -from django.core.urlresolvers import reverse, reverse_lazy +from django.urls import reverse, reverse_lazy from django.http.response import JsonResponse from django.shortcuts import redirect from django.views.generic import View diff --git a/openedx/core/djangoapps/api_admin/widgets.py b/openedx/core/djangoapps/api_admin/widgets.py index 6eb031000ef..ae50044af41 100644 --- a/openedx/core/djangoapps/api_admin/widgets.py +++ b/openedx/core/djangoapps/api_admin/widgets.py @@ -2,7 +2,7 @@ import django from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.forms.utils import flatatt from django.forms.widgets import CheckboxInput from django.utils.encoding import force_text diff --git a/openedx/core/djangoapps/auth_exchange/tests/test_views.py b/openedx/core/djangoapps/auth_exchange/tests/test_views.py index 6448c7ffd98..f9ce0ab7602 100644 --- a/openedx/core/djangoapps/auth_exchange/tests/test_views.py +++ b/openedx/core/djangoapps/auth_exchange/tests/test_views.py @@ -11,7 +11,7 @@ import unittest import ddt from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase import httpretty import provider.constants diff --git a/openedx/core/djangoapps/bookmarks/tests/test_views.py b/openedx/core/djangoapps/bookmarks/tests/test_views.py index 5d9ef55d43c..b7b260b8398 100644 --- a/openedx/core/djangoapps/bookmarks/tests/test_views.py +++ b/openedx/core/djangoapps/bookmarks/tests/test_views.py @@ -7,7 +7,7 @@ import urllib import ddt import pytest from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from mock import patch from nose.plugins.attrib import attr from rest_framework.test import APIClient diff --git a/openedx/core/djangoapps/cache_toolbox/tests/test_middleware.py b/openedx/core/djangoapps/cache_toolbox/tests/test_middleware.py index adef0877f99..04f77e6204a 100644 --- a/openedx/core/djangoapps/cache_toolbox/tests/test_middleware.py +++ b/openedx/core/djangoapps/cache_toolbox/tests/test_middleware.py @@ -1,6 +1,6 @@ """Tests for cached authentication middleware.""" from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from mock import patch diff --git a/openedx/core/djangoapps/cors_csrf/tests/test_views.py b/openedx/core/djangoapps/cors_csrf/tests/test_views.py index 29782b73869..278991fd2ab 100644 --- a/openedx/core/djangoapps/cors_csrf/tests/test_views.py +++ b/openedx/core/djangoapps/cors_csrf/tests/test_views.py @@ -4,7 +4,7 @@ import json import unittest from django.conf import settings -from django.core.urlresolvers import NoReverseMatch, reverse +from django.urls import NoReverseMatch, reverse from django.test import TestCase import ddt diff --git a/openedx/core/djangoapps/course_groups/views.py b/openedx/core/djangoapps/course_groups/views.py index d89db702577..da9f65612c4 100644 --- a/openedx/core/djangoapps/course_groups/views.py +++ b/openedx/core/djangoapps/course_groups/views.py @@ -9,7 +9,7 @@ from django.contrib.auth.decorators import login_required from django.contrib.auth.models import User from django.core.exceptions import ValidationError from django.core.paginator import EmptyPage, Paginator -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import transaction from django.http import Http404, HttpResponseBadRequest from django.utils.translation import ugettext diff --git a/openedx/core/djangoapps/credit/email_utils.py b/openedx/core/djangoapps/credit/email_utils.py index a674e3edb82..fc5108d96ba 100644 --- a/openedx/core/djangoapps/credit/email_utils.py +++ b/openedx/core/djangoapps/credit/email_utils.py @@ -15,7 +15,7 @@ from django.contrib.auth.models import User from django.contrib.staticfiles import finders from django.core.cache import cache from django.core.mail import EmailMessage, SafeMIMEText -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from edxmako.shortcuts import render_to_string diff --git a/openedx/core/djangoapps/credit/tests/test_views.py b/openedx/core/djangoapps/credit/tests/test_views.py index c6165da6a43..a61f80e0541 100644 --- a/openedx/core/djangoapps/credit/tests/test_views.py +++ b/openedx/core/djangoapps/credit/tests/test_views.py @@ -12,7 +12,7 @@ import json import ddt import pytz from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase, Client from django.test.utils import override_settings from edx_oauth2_provider.tests.factories import AccessTokenFactory, ClientFactory diff --git a/openedx/core/djangoapps/embargo/middleware.py b/openedx/core/djangoapps/embargo/middleware.py index 293000f7314..1b0f7f194c2 100644 --- a/openedx/core/djangoapps/embargo/middleware.py +++ b/openedx/core/djangoapps/embargo/middleware.py @@ -30,7 +30,7 @@ import re from django.conf import settings from django.core.exceptions import MiddlewareNotUsed -from django.core.urlresolvers import reverse +from django.urls import reverse from django.shortcuts import redirect from ipware.ip import get_ip diff --git a/openedx/core/djangoapps/embargo/models.py b/openedx/core/djangoapps/embargo/models.py index 54f9eead64f..4ee8679813e 100644 --- a/openedx/core/djangoapps/embargo/models.py +++ b/openedx/core/djangoapps/embargo/models.py @@ -17,7 +17,7 @@ import logging import ipaddr from config_models.models import ConfigurationModel from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db import models from django.db.models.signals import post_delete, post_save from django.utils.translation import ugettext as _ diff --git a/openedx/core/djangoapps/embargo/test_utils.py b/openedx/core/djangoapps/embargo/test_utils.py index 5f5e825c218..57f70399730 100644 --- a/openedx/core/djangoapps/embargo/test_utils.py +++ b/openedx/core/djangoapps/embargo/test_utils.py @@ -3,7 +3,7 @@ import contextlib import mock from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse import pygeoip diff --git a/openedx/core/djangoapps/embargo/tests/test_middleware.py b/openedx/core/djangoapps/embargo/tests/test_middleware.py index d3d7f2d6368..83563f0a101 100644 --- a/openedx/core/djangoapps/embargo/tests/test_middleware.py +++ b/openedx/core/djangoapps/embargo/tests/test_middleware.py @@ -6,7 +6,7 @@ from mock import patch from nose.plugins.attrib import attr import ddt -from django.core.urlresolvers import reverse +from django.urls import reverse from django.conf import settings from django.core.cache import cache as django_cache diff --git a/openedx/core/djangoapps/embargo/tests/test_views.py b/openedx/core/djangoapps/embargo/tests/test_views.py index e5b9afa89ac..f4114065d33 100644 --- a/openedx/core/djangoapps/embargo/tests/test_views.py +++ b/openedx/core/djangoapps/embargo/tests/test_views.py @@ -4,7 +4,7 @@ import ddt import mock import pygeoip -from django.core.urlresolvers import reverse +from django.urls import reverse from django.conf import settings from mock import patch diff --git a/openedx/core/djangoapps/external_auth/login_and_register.py b/openedx/core/djangoapps/external_auth/login_and_register.py index 4d5082f253d..0dec4ba2011 100644 --- a/openedx/core/djangoapps/external_auth/login_and_register.py +++ b/openedx/core/djangoapps/external_auth/login_and_register.py @@ -5,7 +5,7 @@ This module contains legacy code originally from `student.views`. import re from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.shortcuts import redirect from opaque_keys.edx.keys import CourseKey from six import text_type diff --git a/openedx/core/djangoapps/external_auth/tests/test_openid_provider.py b/openedx/core/djangoapps/external_auth/tests/test_openid_provider.py index 174715bfcea..734ba525592 100644 --- a/openedx/core/djangoapps/external_auth/tests/test_openid_provider.py +++ b/openedx/core/djangoapps/external_auth/tests/test_openid_provider.py @@ -12,7 +12,7 @@ from django.conf import settings from django.test import TestCase, LiveServerTestCase from django.core.cache import cache from django.test.utils import override_settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from unittest import skipUnless diff --git a/openedx/core/djangoapps/external_auth/tests/test_shib.py b/openedx/core/djangoapps/external_auth/tests/test_shib.py index 2b94f3d3b7c..d9ed8d86203 100644 --- a/openedx/core/djangoapps/external_auth/tests/test_shib.py +++ b/openedx/core/djangoapps/external_auth/tests/test_shib.py @@ -16,7 +16,7 @@ from django.http import HttpResponseRedirect from django.test import TestCase from django.test.client import RequestFactory, Client as DjangoTestClient from django.test.utils import override_settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.contrib.auth.models import AnonymousUser, User from openedx.core.djangoapps.external_auth.models import ExternalAuthMap from openedx.core.djangoapps.external_auth.views import ( diff --git a/openedx/core/djangoapps/external_auth/tests/test_ssl.py b/openedx/core/djangoapps/external_auth/tests/test_ssl.py index b9a2f3ffe68..de5454ee935 100644 --- a/openedx/core/djangoapps/external_auth/tests/test_ssl.py +++ b/openedx/core/djangoapps/external_auth/tests/test_ssl.py @@ -11,7 +11,7 @@ from django.conf import settings from django.contrib.auth import SESSION_KEY from django.contrib.auth.models import AnonymousUser, User from django.contrib.sessions.middleware import SessionMiddleware -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import Client from django.test.client import RequestFactory from django.test.utils import override_settings diff --git a/openedx/core/djangoapps/external_auth/views.py b/openedx/core/djangoapps/external_auth/views.py index c735436818a..bd1ca41aa41 100644 --- a/openedx/core/djangoapps/external_auth/views.py +++ b/openedx/core/djangoapps/external_auth/views.py @@ -17,7 +17,7 @@ from django.conf import settings from django.contrib.auth import REDIRECT_FIELD_NAME, authenticate, login from django.contrib.auth.models import User from django.core.exceptions import ValidationError -from django.core.urlresolvers import reverse +from django.urls import reverse from django.core.validators import validate_email from django.db import transaction from django.http import HttpResponse, HttpResponseForbidden, HttpResponseRedirect diff --git a/openedx/core/djangoapps/heartbeat/tests/test_heartbeat.py b/openedx/core/djangoapps/heartbeat/tests/test_heartbeat.py index e999cda7b5f..1d79916d53f 100644 --- a/openedx/core/djangoapps/heartbeat/tests/test_heartbeat.py +++ b/openedx/core/djangoapps/heartbeat/tests/test_heartbeat.py @@ -3,7 +3,7 @@ Test the heartbeat """ import json -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db.utils import DatabaseError from django.test.client import Client from xmodule.modulestore.tests.django_utils import ModuleStoreTestCase diff --git a/openedx/core/djangoapps/lang_pref/tests/test_middleware.py b/openedx/core/djangoapps/lang_pref/tests/test_middleware.py index 385a1424164..08ef38be592 100644 --- a/openedx/core/djangoapps/lang_pref/tests/test_middleware.py +++ b/openedx/core/djangoapps/lang_pref/tests/test_middleware.py @@ -8,7 +8,7 @@ import mock import ddt from django.conf import settings from django.test import TestCase -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from django.http import HttpResponse from django.contrib.sessions.middleware import SessionMiddleware diff --git a/openedx/core/djangoapps/lang_pref/tests/test_views.py b/openedx/core/djangoapps/lang_pref/tests/test_views.py index 055345c0175..ac365ee4b90 100644 --- a/openedx/core/djangoapps/lang_pref/tests/test_views.py +++ b/openedx/core/djangoapps/lang_pref/tests/test_views.py @@ -4,7 +4,7 @@ Tests: lang pref views import json from django.test import TestCase from django.test.client import RequestFactory -from django.core.urlresolvers import reverse +from django.urls import reverse from student.tests.factories import UserFactory from django.utils.translation import LANGUAGE_SESSION_KEY from django.contrib.sessions.middleware import SessionMiddleware diff --git a/openedx/core/djangoapps/oauth_dispatch/tests/test_client_credentials.py b/openedx/core/djangoapps/oauth_dispatch/tests/test_client_credentials.py index d171e2107a2..433c7092761 100644 --- a/openedx/core/djangoapps/oauth_dispatch/tests/test_client_credentials.py +++ b/openedx/core/djangoapps/oauth_dispatch/tests/test_client_credentials.py @@ -5,7 +5,7 @@ import json import unittest from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from edx_oauth2_provider.tests.factories import ClientFactory from oauth2_provider.models import Application diff --git a/openedx/core/djangoapps/oauth_dispatch/tests/test_views.py b/openedx/core/djangoapps/oauth_dispatch/tests/test_views.py index edd7183463b..347bae8684c 100644 --- a/openedx/core/djangoapps/oauth_dispatch/tests/test_views.py +++ b/openedx/core/djangoapps/oauth_dispatch/tests/test_views.py @@ -9,7 +9,7 @@ import ddt import httpretty from Cryptodome.PublicKey import RSA from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import RequestFactory, TestCase, override_settings from oauth2_provider import models as dot_models diff --git a/openedx/core/djangoapps/oauth_dispatch/views.py b/openedx/core/djangoapps/oauth_dispatch/views.py index 910a6d724b0..8429fb333d1 100644 --- a/openedx/core/djangoapps/oauth_dispatch/views.py +++ b/openedx/core/djangoapps/oauth_dispatch/views.py @@ -10,7 +10,7 @@ import json from Cryptodome.PublicKey import RSA from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import JsonResponse from django.views.generic import View from edx_oauth2_provider import views as dop_views # django-oauth2-provider views diff --git a/openedx/core/djangoapps/profile_images/tests/test_views.py b/openedx/core/djangoapps/profile_images/tests/test_views.py index e6f60049a49..3d8e6d59989 100644 --- a/openedx/core/djangoapps/profile_images/tests/test_views.py +++ b/openedx/core/djangoapps/profile_images/tests/test_views.py @@ -6,7 +6,7 @@ import datetime from nose.plugins.attrib import attr from pytz import UTC -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpResponse import ddt diff --git a/openedx/core/djangoapps/programs/tests/test_utils.py b/openedx/core/djangoapps/programs/tests/test_utils.py index 5dcfdf9e38f..55e8ef0065c 100644 --- a/openedx/core/djangoapps/programs/tests/test_utils.py +++ b/openedx/core/djangoapps/programs/tests/test_utils.py @@ -10,7 +10,7 @@ import httpretty import mock import pytest from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.utils import override_settings from nose.plugins.attrib import attr diff --git a/openedx/core/djangoapps/programs/utils.py b/openedx/core/djangoapps/programs/utils.py index b9b10b26910..5f178b92dc9 100644 --- a/openedx/core/djangoapps/programs/utils.py +++ b/openedx/core/djangoapps/programs/utils.py @@ -11,7 +11,7 @@ from dateutil.parser import parse from django.conf import settings from django.contrib.auth import get_user_model from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.functional import cached_property from edx_rest_api_client.exceptions import SlumberBaseException from opaque_keys.edx.keys import CourseKey diff --git a/openedx/core/djangoapps/schedules/admin.py b/openedx/core/djangoapps/schedules/admin.py index 96a65c67432..2658bd5c65b 100644 --- a/openedx/core/djangoapps/schedules/admin.py +++ b/openedx/core/djangoapps/schedules/admin.py @@ -3,7 +3,7 @@ import functools from django.contrib import admin from django import forms from django.db.models import F -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext_lazy as _ from openedx.core.djangolib.markup import HTML diff --git a/openedx/core/djangoapps/schedules/resolvers.py b/openedx/core/djangoapps/schedules/resolvers.py index 2e9e91cf7c7..59c056e22bb 100644 --- a/openedx/core/djangoapps/schedules/resolvers.py +++ b/openedx/core/djangoapps/schedules/resolvers.py @@ -6,7 +6,7 @@ import attr from django.conf import settings from django.contrib.auth.models import User from django.contrib.staticfiles.templatetags.staticfiles import static -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db.models import F, Q from edx_ace.recipient_resolver import RecipientResolver diff --git a/openedx/core/djangoapps/service_status/test.py b/openedx/core/djangoapps/service_status/test.py index f006a82d682..8e946f8c96a 100644 --- a/openedx/core/djangoapps/service_status/test.py +++ b/openedx/core/djangoapps/service_status/test.py @@ -2,7 +2,7 @@ import json -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import Client import unittest diff --git a/openedx/core/djangoapps/theming/tests/test_theme_style_overrides.py b/openedx/core/djangoapps/theming/tests/test_theme_style_overrides.py index 865fc280968..d21846cd52f 100644 --- a/openedx/core/djangoapps/theming/tests/test_theme_style_overrides.py +++ b/openedx/core/djangoapps/theming/tests/test_theme_style_overrides.py @@ -2,7 +2,7 @@ Tests for comprehensive themes. """ from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.contrib import staticfiles diff --git a/openedx/core/djangoapps/user_api/accounts/serializers.py b/openedx/core/djangoapps/user_api/accounts/serializers.py index 005cf70c616..d7434e14573 100644 --- a/openedx/core/djangoapps/user_api/accounts/serializers.py +++ b/openedx/core/djangoapps/user_api/accounts/serializers.py @@ -8,7 +8,7 @@ from rest_framework import serializers from django.contrib.auth.models import User from django.conf import settings from django.core.exceptions import ObjectDoesNotExist -from django.core.urlresolvers import reverse +from django.urls import reverse from six import text_type from lms.djangoapps.badges.utils import badges_enabled diff --git a/openedx/core/djangoapps/user_api/accounts/tests/test_views.py b/openedx/core/djangoapps/user_api/accounts/tests/test_views.py index 4f99e5a1d56..ce0b80ba71e 100644 --- a/openedx/core/djangoapps/user_api/accounts/tests/test_views.py +++ b/openedx/core/djangoapps/user_api/accounts/tests/test_views.py @@ -15,7 +15,7 @@ from django.contrib.auth.models import User from django.contrib.sites.models import Site from django.core import mail from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.testcases import TransactionTestCase from django.test.utils import override_settings diff --git a/openedx/core/djangoapps/user_api/api.py b/openedx/core/djangoapps/user_api/api.py index ad5ebba9bc8..68c7cff5b69 100644 --- a/openedx/core/djangoapps/user_api/api.py +++ b/openedx/core/djangoapps/user_api/api.py @@ -3,7 +3,7 @@ import crum from django.conf import settings from django.core.exceptions import ImproperlyConfigured -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from django_countries import countries diff --git a/openedx/core/djangoapps/user_api/preferences/tests/test_views.py b/openedx/core/djangoapps/user_api/preferences/tests/test_views.py index aeb68a9392d..eabc42e315a 100644 --- a/openedx/core/djangoapps/user_api/preferences/tests/test_views.py +++ b/openedx/core/djangoapps/user_api/preferences/tests/test_views.py @@ -7,7 +7,7 @@ import ddt import json from mock import patch -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.testcases import TransactionTestCase from rest_framework.test import APIClient from student.tests.factories import UserFactory, TEST_PASSWORD diff --git a/openedx/core/djangoapps/user_api/tests/test_views.py b/openedx/core/djangoapps/user_api/tests/test_views.py index 351389c86d0..d98ce4f668a 100644 --- a/openedx/core/djangoapps/user_api/tests/test_views.py +++ b/openedx/core/djangoapps/user_api/tests/test_views.py @@ -10,7 +10,7 @@ import mock from django.conf import settings from django.contrib.auth.models import User from django.core import mail -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from django.test.testcases import TransactionTestCase from django.test.utils import override_settings diff --git a/openedx/core/djangoapps/user_api/validation/tests/test_views.py b/openedx/core/djangoapps/user_api/validation/tests/test_views.py index b0421e82e06..892d1c1b5a4 100644 --- a/openedx/core/djangoapps/user_api/validation/tests/test_views.py +++ b/openedx/core/djangoapps/user_api/validation/tests/test_views.py @@ -8,7 +8,7 @@ import unittest import ddt from django.conf import settings from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from six import text_type from openedx.core.djangoapps.user_api import accounts diff --git a/openedx/core/djangoapps/user_api/verification_api/tests/test_views.py b/openedx/core/djangoapps/user_api/verification_api/tests/test_views.py index 79e732aac5e..94ec8161765 100644 --- a/openedx/core/djangoapps/user_api/verification_api/tests/test_views.py +++ b/openedx/core/djangoapps/user_api/verification_api/tests/test_views.py @@ -6,7 +6,7 @@ import freezegun import json from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.utils import override_settings diff --git a/openedx/core/djangoapps/zendesk_proxy/tests/test_v0_views.py b/openedx/core/djangoapps/zendesk_proxy/tests/test_v0_views.py index 817807999ef..fd1b22dc087 100644 --- a/openedx/core/djangoapps/zendesk_proxy/tests/test_v0_views.py +++ b/openedx/core/djangoapps/zendesk_proxy/tests/test_v0_views.py @@ -3,7 +3,7 @@ import json from copy import deepcopy import ddt -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from mock import MagicMock, patch diff --git a/openedx/core/djangoapps/zendesk_proxy/tests/test_v1_views.py b/openedx/core/djangoapps/zendesk_proxy/tests/test_v1_views.py index 6f4a17370b4..8dc13c41ec7 100644 --- a/openedx/core/djangoapps/zendesk_proxy/tests/test_v1_views.py +++ b/openedx/core/djangoapps/zendesk_proxy/tests/test_v1_views.py @@ -3,7 +3,7 @@ import json from copy import deepcopy import ddt -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.utils import override_settings from mock import MagicMock, patch diff --git a/openedx/core/lib/gating/api.py b/openedx/core/lib/gating/api.py index b9bc9800ecc..3e6ed5db772 100644 --- a/openedx/core/lib/gating/api.py +++ b/openedx/core/lib/gating/api.py @@ -5,7 +5,7 @@ import json import logging from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from completion.models import BlockCompletion diff --git a/openedx/core/lib/xblock_builtin/xblock_discussion/xblock_discussion/__init__.py b/openedx/core/lib/xblock_builtin/xblock_discussion/xblock_discussion/__init__.py index 634f3dc190b..81873169281 100644 --- a/openedx/core/lib/xblock_builtin/xblock_discussion/xblock_discussion/__init__.py +++ b/openedx/core/lib/xblock_builtin/xblock_discussion/xblock_discussion/__init__.py @@ -6,7 +6,7 @@ import logging import urllib from django.contrib.staticfiles.storage import staticfiles_storage -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import get_language_bidi from xblock.completable import XBlockCompletionMode from xblock.core import XBlock diff --git a/openedx/core/lib/xblock_utils/__init__.py b/openedx/core/lib/xblock_utils/__init__.py index 7de04b70bdf..c46739976ee 100644 --- a/openedx/core/lib/xblock_utils/__init__.py +++ b/openedx/core/lib/xblock_utils/__init__.py @@ -14,7 +14,7 @@ from contracts import contract from django.conf import settings from django.contrib.staticfiles.storage import staticfiles_storage -from django.core.urlresolvers import reverse +from django.urls import reverse from pytz import UTC from django.utils.html import escape from django.contrib.auth.models import User diff --git a/openedx/features/course_bookmarks/plugins.py b/openedx/features/course_bookmarks/plugins.py index bb8921823c2..01f13c5b105 100644 --- a/openedx/features/course_bookmarks/plugins.py +++ b/openedx/features/course_bookmarks/plugins.py @@ -3,7 +3,7 @@ Platform plugins to support course bookmarks. """ from courseware.access import has_access -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.features.course_experience.course_tools import CourseTool from student.models import CourseEnrollment diff --git a/openedx/features/course_bookmarks/views/course_bookmarks.py b/openedx/features/course_bookmarks/views/course_bookmarks.py index b1f4464ae12..8f82e70e248 100644 --- a/openedx/features/course_bookmarks/views/course_bookmarks.py +++ b/openedx/features/course_bookmarks/views/course_bookmarks.py @@ -4,7 +4,7 @@ Views to show a course's bookmarks. from django.contrib.auth.decorators import login_required from django.template.context_processors import csrf -from django.core.urlresolvers import reverse +from django.urls import reverse from django.shortcuts import render_to_response from django.template.loader import render_to_string from django.utils.decorators import method_decorator diff --git a/openedx/features/course_experience/plugins.py b/openedx/features/course_experience/plugins.py index 50613f9b5ea..e478a8b923a 100644 --- a/openedx/features/course_experience/plugins.py +++ b/openedx/features/course_experience/plugins.py @@ -3,7 +3,7 @@ Platform plugins to support the course experience. This includes any locally defined CourseTools. """ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from courseware.courses import get_course_by_id diff --git a/openedx/features/course_experience/templates/course_experience/course-home-fragment.html b/openedx/features/course_experience/templates/course_experience/course-home-fragment.html index d499fcf4164..e99d9f7d782 100644 --- a/openedx/features/course_experience/templates/course_experience/course-home-fragment.html +++ b/openedx/features/course_experience/templates/course_experience/course-home-fragment.html @@ -9,7 +9,7 @@ import json from django.conf import settings from django.utils.translation import ugettext as _ from django.template.defaultfilters import escapejs -from django.core.urlresolvers import reverse +from django.urls import reverse from django_comment_client.permissions import has_permission from openedx.core.djangolib.js_utils import dump_js_escaped_json, js_escaped_string diff --git a/openedx/features/course_experience/tests/views/test_course_dates.py b/openedx/features/course_experience/tests/views/test_course_dates.py index ab2fb356722..1df810ec558 100644 --- a/openedx/features/course_experience/tests/views/test_course_dates.py +++ b/openedx/features/course_experience/tests/views/test_course_dates.py @@ -2,7 +2,7 @@ Tests for course dates fragment. """ from datetime import timedelta, datetime -from django.core.urlresolvers import reverse +from django.urls import reverse from student.tests.factories import UserFactory from xmodule.modulestore import ModuleStoreEnum diff --git a/openedx/features/course_experience/tests/views/test_course_home.py b/openedx/features/course_experience/tests/views/test_course_home.py index c4363dfa77b..4deaf83272a 100644 --- a/openedx/features/course_experience/tests/views/test_course_home.py +++ b/openedx/features/course_experience/tests/views/test_course_home.py @@ -7,7 +7,7 @@ from datetime import datetime, timedelta import ddt import mock from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import QueryDict from django.utils.http import urlquote_plus from django.utils.timezone import now diff --git a/openedx/features/course_experience/tests/views/test_course_outline.py b/openedx/features/course_experience/tests/views/test_course_outline.py index dfbf8aca53d..406389aee5a 100644 --- a/openedx/features/course_experience/tests/views/test_course_outline.py +++ b/openedx/features/course_experience/tests/views/test_course_outline.py @@ -9,7 +9,7 @@ from completion import waffle from completion.models import BlockCompletion from completion.test_utils import CompletionWaffleTestMixin from django.contrib.sites.models import Site -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import override_settings from mock import Mock, patch from six import text_type diff --git a/openedx/features/course_experience/tests/views/test_course_updates.py b/openedx/features/course_experience/tests/views/test_course_updates.py index a2f8eaa93b4..607cca19ed2 100644 --- a/openedx/features/course_experience/tests/views/test_course_updates.py +++ b/openedx/features/course_experience/tests/views/test_course_updates.py @@ -2,7 +2,7 @@ Tests for the course updates page. """ from courseware.courses import get_course_info_usage_key -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangoapps.waffle_utils.testutils import WAFFLE_TABLES from openedx.features.course_experience.views.course_updates import STATUS_VISIBLE from student.models import CourseEnrollment diff --git a/openedx/features/course_experience/tests/views/test_welcome_message.py b/openedx/features/course_experience/tests/views/test_welcome_message.py index 05efb3af590..0d68dcd11c3 100644 --- a/openedx/features/course_experience/tests/views/test_welcome_message.py +++ b/openedx/features/course_experience/tests/views/test_welcome_message.py @@ -2,7 +2,7 @@ Tests for course welcome messages. """ import ddt -from django.core.urlresolvers import reverse +from django.urls import reverse from student.models import CourseEnrollment from student.tests.factories import UserFactory diff --git a/openedx/features/course_experience/views/course_home.py b/openedx/features/course_experience/views/course_home.py index bf09c2f919d..0f3eb2801f7 100644 --- a/openedx/features/course_experience/views/course_home.py +++ b/openedx/features/course_experience/views/course_home.py @@ -2,7 +2,7 @@ Views for the course home page. """ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.template.context_processors import csrf from django.template.loader import render_to_string from django.utils.decorators import method_decorator diff --git a/openedx/features/course_experience/views/course_reviews.py b/openedx/features/course_experience/views/course_reviews.py index b1ccf6d924c..11ae627d107 100644 --- a/openedx/features/course_experience/views/course_reviews.py +++ b/openedx/features/course_experience/views/course_reviews.py @@ -3,7 +3,7 @@ Fragment for rendering the course reviews panel """ from django.conf import settings from django.contrib.auth.decorators import login_required -from django.core.urlresolvers import reverse +from django.urls import reverse from django.template.loader import render_to_string from django.utils.decorators import method_decorator from django.views.decorators.cache import cache_control diff --git a/openedx/features/course_experience/views/course_updates.py b/openedx/features/course_experience/views/course_updates.py index 5b39cbb064d..f84a33e2235 100644 --- a/openedx/features/course_experience/views/course_updates.py +++ b/openedx/features/course_experience/views/course_updates.py @@ -5,7 +5,7 @@ from datetime import datetime from django.contrib.auth.decorators import login_required from django.template.context_processors import csrf -from django.core.urlresolvers import reverse +from django.urls import reverse from django.template.loader import render_to_string from django.utils.decorators import method_decorator from django.views.decorators.cache import cache_control diff --git a/openedx/features/course_experience/views/welcome_message.py b/openedx/features/course_experience/views/welcome_message.py index 028f45a673e..98d965ef5c8 100644 --- a/openedx/features/course_experience/views/welcome_message.py +++ b/openedx/features/course_experience/views/welcome_message.py @@ -2,7 +2,7 @@ View logic for handling course welcome messages. """ -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpResponse, HttpResponseBadRequest from django.template.loader import render_to_string from django.views.decorators.csrf import ensure_csrf_cookie diff --git a/openedx/features/course_search/templates/course_search/course-search-fragment.html b/openedx/features/course_search/templates/course_search/course-search-fragment.html index fc185c78866..4a2bc45745b 100644 --- a/openedx/features/course_search/templates/course_search/course-search-fragment.html +++ b/openedx/features/course_search/templates/course_search/course-search-fragment.html @@ -10,7 +10,7 @@ import waffle from django.conf import settings from django.utils.translation import ugettext as _ from django.template.defaultfilters import escapejs -from django.core.urlresolvers import reverse +from django.urls import reverse from django_comment_client.permissions import has_permission from openedx.core.djangolib.js_utils import dump_js_escaped_json, js_escaped_string diff --git a/openedx/features/course_search/views/course_search.py b/openedx/features/course_search/views/course_search.py index c9b704f120a..f0cbd574891 100644 --- a/openedx/features/course_search/views/course_search.py +++ b/openedx/features/course_search/views/course_search.py @@ -4,7 +4,7 @@ Views for the course search page. from django.contrib.auth.decorators import login_required from django.template.context_processors import csrf -from django.core.urlresolvers import reverse +from django.urls import reverse from django.template.loader import render_to_string from django.utils.decorators import method_decorator from django.views.decorators.cache import cache_control diff --git a/openedx/features/enterprise_support/api.py b/openedx/features/enterprise_support/api.py index 35a358f9e8b..04ccfcb8a0c 100644 --- a/openedx/features/enterprise_support/api.py +++ b/openedx/features/enterprise_support/api.py @@ -7,7 +7,7 @@ from functools import wraps from django.conf import settings from django.contrib.auth.models import User from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.shortcuts import redirect from django.template.loader import render_to_string from django.utils.http import urlencode diff --git a/openedx/features/enterprise_support/tests/mixins/enterprise.py b/openedx/features/enterprise_support/tests/mixins/enterprise.py index 84f49e49c1e..c307b8ae287 100644 --- a/openedx/features/enterprise_support/tests/mixins/enterprise.py +++ b/openedx/features/enterprise_support/tests/mixins/enterprise.py @@ -7,7 +7,7 @@ import mock import httpretty from django.conf import settings from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import SimpleTestCase from openedx.features.enterprise_support.tests import FAKE_ENTERPRISE_CUSTOMER diff --git a/openedx/features/enterprise_support/tests/test_api.py b/openedx/features/enterprise_support/tests/test_api.py index 6a41ab97cbd..077e10f6bb0 100644 --- a/openedx/features/enterprise_support/tests/test_api.py +++ b/openedx/features/enterprise_support/tests/test_api.py @@ -8,7 +8,7 @@ import mock from django.conf import settings from django.contrib.auth.models import User from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import HttpResponseRedirect from django.test.utils import override_settings diff --git a/openedx/features/enterprise_support/tests/test_middleware.py b/openedx/features/enterprise_support/tests/test_middleware.py index 460f20192d4..5f7b2b17fdf 100644 --- a/openedx/features/enterprise_support/tests/test_middleware.py +++ b/openedx/features/enterprise_support/tests/test_middleware.py @@ -4,7 +4,7 @@ Tests for Enterprise middleware. import mock -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test import TestCase from django.test.utils import override_settings diff --git a/openedx/features/learner_analytics/views.py b/openedx/features/learner_analytics/views.py index 226a02d0641..0edf212db5a 100644 --- a/openedx/features/learner_analytics/views.py +++ b/openedx/features/learner_analytics/views.py @@ -12,7 +12,7 @@ from analyticsclient.client import Client from django.conf import settings from django.contrib.auth.decorators import login_required from django.core.cache import cache -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404 from django.shortcuts import render_to_response from django.utils.decorators import method_decorator diff --git a/openedx/features/learner_profile/templates/learner_profile/learner_profile.html b/openedx/features/learner_profile/templates/learner_profile/learner_profile.html index 010bc2193f8..e53f7583072 100644 --- a/openedx/features/learner_profile/templates/learner_profile/learner_profile.html +++ b/openedx/features/learner_profile/templates/learner_profile/learner_profile.html @@ -7,7 +7,7 @@ <%! import json -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangolib.js_utils import dump_js_escaped_json from openedx.core.djangolib.markup import HTML diff --git a/openedx/features/learner_profile/tests/views/test_learner_profile.py b/openedx/features/learner_profile/tests/views/test_learner_profile.py index b3ecbf62176..0499e536909 100644 --- a/openedx/features/learner_profile/tests/views/test_learner_profile.py +++ b/openedx/features/learner_profile/tests/views/test_learner_profile.py @@ -9,7 +9,7 @@ from lms.djangoapps.certificates.tests.factories import GeneratedCertificateFact from lms.envs.test import CREDENTIALS_PUBLIC_SERVICE_URL from course_modes.models import CourseMode from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from django.test.client import RequestFactory from lms.djangoapps.certificates.api import is_passing_status from opaque_keys.edx.locator import CourseLocator diff --git a/openedx/features/learner_profile/views/learner_profile.py b/openedx/features/learner_profile/views/learner_profile.py index 8f56d42c6f5..31450209f89 100644 --- a/openedx/features/learner_profile/views/learner_profile.py +++ b/openedx/features/learner_profile/views/learner_profile.py @@ -5,7 +5,7 @@ from django.conf import settings from django.contrib.auth.decorators import login_required from django.contrib.staticfiles.storage import staticfiles_storage from django.core.exceptions import ObjectDoesNotExist -from django.core.urlresolvers import reverse +from django.urls import reverse from django.http import Http404 from django.shortcuts import render_to_response from django.utils.translation import ugettext as _ diff --git a/openedx/tests/completion_integration/test_views.py b/openedx/tests/completion_integration/test_views.py index f9edcdb2fb0..5801a39f06c 100644 --- a/openedx/tests/completion_integration/test_views.py +++ b/openedx/tests/completion_integration/test_views.py @@ -5,7 +5,7 @@ Test models, managers, and validators. from completion import waffle from completion.test_utils import CompletionWaffleTestMixin import ddt -from django.core.urlresolvers import reverse +from django.urls import reverse from rest_framework.test import APIClient from student.tests.factories import UserFactory, CourseEnrollmentFactory diff --git a/openedx/tests/xblock_integration/test_crowdsource_hinter.py b/openedx/tests/xblock_integration/test_crowdsource_hinter.py index 1fc0b9c7a70..db6f3030591 100644 --- a/openedx/tests/xblock_integration/test_crowdsource_hinter.py +++ b/openedx/tests/xblock_integration/test_crowdsource_hinter.py @@ -5,7 +5,7 @@ import json import unittest from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from nose.plugins.attrib import attr from six import text_type diff --git a/openedx/tests/xblock_integration/test_recommender.py b/openedx/tests/xblock_integration/test_recommender.py index 32f2c979a17..a5cd83244d7 100644 --- a/openedx/tests/xblock_integration/test_recommender.py +++ b/openedx/tests/xblock_integration/test_recommender.py @@ -10,7 +10,7 @@ import unittest from copy import deepcopy from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from ddt import data, ddt from lms.djangoapps.courseware.tests.factories import GlobalStaffFactory diff --git a/openedx/tests/xblock_integration/test_review_xblock.py b/openedx/tests/xblock_integration/test_review_xblock.py index 42df514bfa2..14eab4feef2 100644 --- a/openedx/tests/xblock_integration/test_review_xblock.py +++ b/openedx/tests/xblock_integration/test_review_xblock.py @@ -6,7 +6,7 @@ import unittest from django.conf import settings from django.contrib.auth.models import User -from django.core.urlresolvers import reverse +from django.urls import reverse from nose.plugins.attrib import attr from lms.djangoapps.courseware.tests.factories import GlobalStaffFactory diff --git a/openedx/tests/xblock_integration/xblock_testcase.py b/openedx/tests/xblock_integration/xblock_testcase.py index b96bc898bd0..9ea51c4c2e6 100644 --- a/openedx/tests/xblock_integration/xblock_testcase.py +++ b/openedx/tests/xblock_integration/xblock_testcase.py @@ -46,7 +46,7 @@ import mock import pytz from bs4 import BeautifulSoup from django.conf import settings -from django.core.urlresolvers import reverse +from django.urls import reverse from xblock.plugin import Plugin import lms.djangoapps.lms_xblock.runtime diff --git a/themes/edx.org/cms/templates/widgets/sock.html b/themes/edx.org/cms/templates/widgets/sock.html index 571d90320c9..dd01db031be 100644 --- a/themes/edx.org/cms/templates/widgets/sock.html +++ b/themes/edx.org/cms/templates/widgets/sock.html @@ -1,7 +1,7 @@ <%page expression_filter="h" args="online_help_token"/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <div class="wrapper-sock wrapper"> <ul class="list-actions list-cta"> diff --git a/themes/edx.org/lms/templates/course_modes/choose.html b/themes/edx.org/lms/templates/course_modes/choose.html index 9ab6ce2dc19..62af72ba096 100644 --- a/themes/edx.org/lms/templates/course_modes/choose.html +++ b/themes/edx.org/lms/templates/course_modes/choose.html @@ -3,7 +3,7 @@ <%namespace name='static' file='/static_content.html'/> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from opaque_keys.edx.keys import CourseKey from openedx.core.djangolib.js_utils import js_escaped_string from openedx.core.djangolib.markup import HTML, Text diff --git a/themes/edx.org/lms/templates/dashboard.html b/themes/edx.org/lms/templates/dashboard.html index f58c050bd6a..e05515c7f59 100644 --- a/themes/edx.org/lms/templates/dashboard.html +++ b/themes/edx.org/lms/templates/dashboard.html @@ -11,7 +11,7 @@ from django.utils import timezone from django.utils.translation import ugettext as _ from django.template import RequestContext from third_party_auth import pipeline -from django.core.urlresolvers import reverse +from django.urls import reverse from util.date_utils import strftime_localized from opaque_keys.edx.keys import CourseKey from openedx.core.djangoapps.content.course_overviews.models import CourseOverview diff --git a/themes/edx.org/lms/templates/header/navbar-authenticated.html b/themes/edx.org/lms/templates/header/navbar-authenticated.html index eb76f36ab3a..449bd6ff3bf 100644 --- a/themes/edx.org/lms/templates/header/navbar-authenticated.html +++ b/themes/edx.org/lms/templates/header/navbar-authenticated.html @@ -5,7 +5,7 @@ <%namespace name='static' file='../static_content.html'/> <%namespace file='../main.html' import="login_query"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangoapps.site_configuration import helpers as configuration_helpers %> diff --git a/themes/edx.org/lms/templates/header/navbar-not-authenticated.html b/themes/edx.org/lms/templates/header/navbar-not-authenticated.html index 4d233b80985..174ca60a403 100644 --- a/themes/edx.org/lms/templates/header/navbar-not-authenticated.html +++ b/themes/edx.org/lms/templates/header/navbar-not-authenticated.html @@ -6,7 +6,7 @@ <%namespace file='../main.html' import="login_query"/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from six import text_type %> diff --git a/themes/red-theme/cms/templates/login.html b/themes/red-theme/cms/templates/login.html index 721104311d0..90659bc0ebf 100644 --- a/themes/red-theme/cms/templates/login.html +++ b/themes/red-theme/cms/templates/login.html @@ -4,7 +4,7 @@ <%inherit file="base.html" /> <%def name="online_help_token()"><% return "login" %></%def> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ %> <%block name="title">${_("Sign In")}</%block> diff --git a/themes/red-theme/lms/templates/footer.html b/themes/red-theme/lms/templates/footer.html index 825ed082c55..320478a155e 100755 --- a/themes/red-theme/lms/templates/footer.html +++ b/themes/red-theme/lms/templates/footer.html @@ -1,7 +1,7 @@ ## mako <%namespace name='static' file='static_content.html'/> <%! -from django.core.urlresolvers import reverse +from django.urls import reverse from django.utils.translation import ugettext as _ from django.conf import settings diff --git a/themes/stanford-style/lms/templates/footer.html b/themes/stanford-style/lms/templates/footer.html index 15faea08121..454272c49d9 100644 --- a/themes/stanford-style/lms/templates/footer.html +++ b/themes/stanford-style/lms/templates/footer.html @@ -1,7 +1,7 @@ ## mako <%! from datetime import date - from django.core.urlresolvers import reverse + from django.urls import reverse from django.utils.translation import ugettext as _ from openedx.core.djangoapps.lang_pref.api import footer_language_selector_is_enabled %> diff --git a/themes/stanford-style/lms/templates/register-shib.html b/themes/stanford-style/lms/templates/register-shib.html index 6fd6b6b769f..80e8db77a24 100644 --- a/themes/stanford-style/lms/templates/register-shib.html +++ b/themes/stanford-style/lms/templates/register-shib.html @@ -1,7 +1,7 @@ <%inherit file="main.html" /> <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse from openedx.core.djangolib.js_utils import js_escaped_string %> diff --git a/themes/stanford-style/lms/templates/register-sidebar.html b/themes/stanford-style/lms/templates/register-sidebar.html index e661d5adbe6..d3738c529b1 100644 --- a/themes/stanford-style/lms/templates/register-sidebar.html +++ b/themes/stanford-style/lms/templates/register-sidebar.html @@ -1,6 +1,6 @@ <%! from django.utils.translation import ugettext as _ -from django.core.urlresolvers import reverse +from django.urls import reverse %> <%namespace file='main.html' import="login_query"/> -- GitLab