Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix!: use full import path to safe_lxml #324

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion edx_sga/sga.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
from django.utils.timezone import now as django_now
from django.utils.translation import gettext as _
from lms.djangoapps.courseware.models import StudentModule
from safe_lxml import etree
from openedx.core.lib.safe_lxml import etree
from common.djangoapps.student.models import user_by_anonymous_id
from submissions import api as submissions_api
from submissions.models import StudentItem as SubmissionsStudent
Expand Down
2 changes: 1 addition & 1 deletion edx_sga/tests/test_sga.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ def fake_import(name, *args, **kwargs):
for module in ("common", "courseware", "lms", "xmodule"):
if name.startswith(f"{module}.") or name == module:
return mock.Mock()
if name == "safe_lxml":
if name == "openedx.core.lib.safe_lxml":
return real_import("lxml", *args, **kwargs)
raise

Expand Down