* MST-682 Add external_user_key to the student profile CSV
This is a request from some Masters school partners. They would like to download the student enrolled list with the Masters external_user_key data referenced. This way, the schools can properly match the students enrolled in the course with the students enrolled through Masters enrollment system
* Generate common/djangoapps import shims for LMS
* Generate common/djangoapps import shims for Studio
* Stop appending project root to sys.path
* Stop appending common/djangoapps to sys.path
* Import from common.djangoapps.course_action_state instead of course_action_state
* Import from common.djangoapps.course_modes instead of course_modes
* Import from common.djangoapps.database_fixups instead of database_fixups
* Import from common.djangoapps.edxmako instead of edxmako
* Import from common.djangoapps.entitlements instead of entitlements
* Import from common.djangoapps.pipline_mako instead of pipeline_mako
* Import from common.djangoapps.static_replace instead of static_replace
* Import from common.djangoapps.student instead of student
* Import from common.djangoapps.terrain instead of terrain
* Import from common.djangoapps.third_party_auth instead of third_party_auth
* Import from common.djangoapps.track instead of track
* Import from common.djangoapps.util instead of util
* Import from common.djangoapps.xblock_django instead of xblock_django
* Add empty common/djangoapps/__init__.py to fix pytest collection
* Fix pylint formatting violations
* Exclude import_shims/ directory tree from linting
In this case,
* unenroll the currently linked learner from the courses associated with related ProgramCourseEnrollments
* for each course the is enrolled in as part of a ProgramCourseEnrollment, if the coures has an audit track, then move the enrollment into the audit track. Otherwise, keep the learner's enrollment in the existing track.
* link the new user to the ProgramEnrollment
* enroll the new user in the Master's track in the courses associated with related ProgramCourseEnrollments
Run isort -rc lms/djangoapps/program_enrollments
Run pylint lms/djangoapps/program_enrollment and fix messages.
Stop pylint from complaining about DictFactoryBase instances
We'd like to add this status to help distinguish between learners
who've graduated from the program and learners who warranted some sort
of removal from the program.
JIRA:EDUCATOR-4702
This reverts commit a67b9f70a16a0f16a842aad84754b245a2480b5f,
reinstating commit cf78660ed35712f9bb7c112f70411179070d7382.
The original commit was reverted because I thought I found
bugs in it while verifying it on Stage, but it turns out that
it was simply misconfigured Stage data that causing errors.
The original commit's message has has been copied below:
This commit completes the program_enrollments LMS app
Python API for the time being. It does the following:
* Add bulk-lookup of users by external key in api/reading.py
* Add bulk-writing of program enrollments in api/writing.py
* Move grade-reading to api/grades.py
* Refactor api/linking.py to use api/writing.py
* Refactor signals.py to use api/linking.py
* Update rest_api/v1/views.py to utilize all these changes
* Update linking management command and support tool to use API
* Remove outdated tests from test_models.py
* Misc. cleanup
EDUCATOR-4321
This reverts commit af4e7a348a.
After merging the above commit, I was seeing 'internal-error's
on Stage in responses to the Registrar API. I am temporarily
reverting it until I can figure out a fix.
This commit completes the program_enrollments LMS app
Python API for the time being. It does the following:
* Add bulk-lookup of users by external key in api/reading.py
* Add bulk-writing of program enrollments in api/writing.py
* Move grade-reading to api/grades.py
* Refactor api/linking.py to use api/writing.py
* Refactor signals.py to use api/linking.py
* Update rest_api/v1/views.py to utilize all these changes
* Update linking management command and support tool to use API
* Remove outdated tests from test_models.py
* Misc. cleanup
EDUCATOR-4321
This is the third in a series of commits to create
a Python API for the LMS program_enrollments app.
It does the following:
* Creates api/ folder.
* Moves link_program_enrollments.py to api/linking.py
* Creates api/reading.py for enrollment-fetching
functions.
* Updates rest of app to use api/reading.py when
it was going directly through the models before.
* Other misc. cleanup (isorting, unicode_literals,
line breaks, etc).
Still to do:
* Create api/writing.py and update app to use it instead
of going directly through models.
* Create api/reset.py and api/expire.py, which the management
commands call out to.
EDUCATOR-4321
This is the first in a series of commits to create
a Python API for the LMS program_enrollments app.
We do some general refactoring, renaming, and clean-up
in order to move toward the creation of that API.
EDUCATOR-4321
Issues were caused in Learner Portal from inconsistency
in whether URLs returned by API calls were absolute
or relative. This commit standardizes them to all be
absolute.
The program course enrollment overview endpoint says
it has a field 'course_status' with a possible value 'in-progress'.
Update it to say it has a field 'course_run_status with a
possible value 'in_progress'.
Adding new course_overview internal api
CourseOverview serializer work
Removing enterprise learner portal djangoapp from this repo
Removing ent learner portal url
Minor cleanups
Updating serializers again
typo
adding some tests and quality fixes
more quality fixes
Fixing test
Adding in an import i removed
This new API endpoint differs from the existing Grades API
in that (i) it only includes grades for users enrolled with a
ProgramCourseEnrollment and (ii) it alters its return code
depending on whether any student's grade failed to load.
EDUCATOR-4529
These were originally fixed individually, but had to be reverted, and
are now combined in one commit. The originals were:
7b9040f6b0 This enum was backwards
8774ff1f9b Use ref_name to disambiguate serializers that drf-yasg would otherwise assume are the same.
8a44397139 Is this field missing because it is None?
4a1154a7ca Give a safer buffer for clearing the rate limiting
64c47856dd DRF 3.7.4 changed how you delegate to another view, so don't
7359ca4fb2 Is this right? It fixes two tests
fdd66e5390 Adjust the expected error message for DRF 3.7.7
9257f68fd8 The default TIME_ZONE should be UTC
In production, we use UTC as the time zone. DRF 3.7.7 now puts all
times in the currently set timezone where it used to use UTC. By
setting TIME_ZONE to UTC, we keep the same results we used to get.
In a few places, we had to change the expected test results to be UTC.
This makes the LMS program_enrollments API compatible with the
Registrar programs API, as specified in the Master's partner
integration guide.
EDUCATOR-4389