Commit Graph

4470 Commits

Author SHA1 Message Date
Michael Terry
7697b7dd46 When masquerading in courseware API, reset the request user
It's important that request.user be set as the effective user,
because waffle flags and bits of code around the place look at it.

This should make masquerading more accurate to what the learner
sees.
2020-11-13 12:58:18 -05:00
Gábor Boros
2a35410fe4 Expose banner image URL in course API
Banner image URL is exposed on the course list and course details API
endpoints. The new `banner_image_url` API field has both the relative
and absolute URLs for the image it represents, if it is set.
2020-11-13 15:35:13 +01:00
Zainab Amir
2cf023bf27 VAN-92: Update TPA Context with platform name (#25580) 2020-11-13 17:15:53 +05:00
Albert (AJ) St. Aubin
9551b23d08 [MICROBA-721] Updates the notify_credentials job to run over new window 2020-11-12 08:27:03 -05:00
Saleem Latif
785b04888d Updated edx-enterprise version and only set user language preference on signup if it does not already exist. 2020-11-11 14:24:47 +05:00
Dillon Dumesnil
8824a137dc Merge pull request #25562 from edx/ddumesnil/no-updates-after-end-aa-422
AA-422: Ensure learners are not receiving updates after course end
2020-11-10 11:41:21 -08:00
Awais Qureshi
7201edb11d Revert "Update routing config" (#25536)" (#25549)" (#25553)" (#25561)
This reverts commit db4c3b1210.
2020-11-11 00:13:47 +05:00
Dillon Dumesnil
11f1347669 AA-422: Ensure learners are not receiving updates after course end 2020-11-10 14:07:31 -05:00
Awais Qureshi
db4c3b1210 Revert "Revert ""Update routing config" (#25536)" (#25549)" (#25553)
This reverts commit c1fe3c3a93.
2020-11-10 23:23:09 +05:00
Kyle McCormick
151bd13666 Use full names for common.djangoapps imports; warn when using old style (#25477)
* 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
2020-11-10 07:02:01 -05:00
Muhammad Soban Javed
c1fe3c3a93 Revert ""Update routing config" (#25536)" (#25549)
This reverts commit 39a22734c1.
2020-11-09 23:43:47 +05:00
Awais Qureshi
39a22734c1 "Update routing config" (#25536)
* Revert "Revert "Update routing config"

* Removed settings from lms/celery.py and cms/celery.py

* Moved settings import from top-level to function's scopes

Co-authored-by: Soban Javed <iamsobanjaved@gmail.com>
2020-11-09 19:06:55 +05:00
adeel khan
eec8200761 Merge pull request #25507 from edx/adeel/van_105_adding_error_handling_for_login_page
Adds error message for logistration MFE.
2020-11-09 16:18:01 +05:00
Adeel Khan
51610e195e Adds error message for logistration MFE.
This adds new user facing locked out messaging
for logistration MFE.

VAN-105
2020-11-08 22:05:05 +05:00
Nizar Mahmoud
e4c8897014 Catches BlockStructureNotFound raised when clearing course from cache 2020-11-07 14:17:25 +03:00
Manjinder Singh
c74b623948 Fixing code-annotations (#25539)
* Fixing code-annotations
2020-11-06 12:52:08 -05:00
Michael Terry
b2ba363f1e Merge pull request #25503 from edx/mikix/parent-access
AA-408: Treat group_access as inheritable in gating transformer
2020-11-06 11:40:58 -05:00
Robert Raposa
fe9395bd7a Merge pull request #25538 from regisb/regisb/improve-waffle-tests
[BD-21] Improve waffle_utils tests to not rely on internal API
2020-11-06 08:58:18 -05:00
Adeel Ehsan
0d9236524d Merge pull request #25398 from edx/aehsan/van-6/added_params_in_register_api
Added next and cours_id params in register endpoint
2020-11-06 18:15:09 +05:00
adeelehsan
8be2283aef Added next and cours_id params in register endpoint
VAN-6
2020-11-06 17:41:11 +05:00
Régis Behmo
19ff82a3da Improve waffle_utils tests to not rely on internal API
This is required for a smooth upgrade of edx-toggles.
2020-11-06 12:11:52 +01:00
Muhammad Soban Javed
5a2ea1f954 Revert "Update routing config" 2020-11-06 02:05:48 +05:00
Michael Terry
f2d4e0ccec AA-408: Treat group_access as inheritable in gating transformer
ContentTypeGateTransformer was not considering parent values of
'group_access' when providing its own default value for it.

Also fix a few minor bugs around the place.
2020-11-05 15:27:46 -05:00
Robert Raposa
061d5d8fc5 Merge pull request #25529 from regisb/regisb/better-waffle-deprecation-monitoring
[BD-21] Improve monitoring of waffle deprecation with custom attributes
2020-11-05 15:09:54 -05:00
Muhammad Soban Javed
bfa8f71f33 Update routing config #25419 2020-11-06 01:00:29 +05:00
Zainab Amir
97e9fee92e Add third party auth context api (#25497) 2020-11-05 19:26:29 +05:00
Régis Behmo
b32fc50947 Improve monitoring of waffle deprecation with custom attributes
We observe a lot of deprecation warnings using the
"deprecated_waffle_utils" custom attribute. To make it easier to track
these items, we add the waffle flag/namespace name to the custom
attribute.
2020-11-05 08:36:03 +01:00
Nizar Mahmoud
3a46e7c5f5 Squashes waffle_utils.WaffleFlag deprecation warning 2020-11-05 02:00:33 +03:00
Régis Behmo
da0623107c Expose SettingToggle and SettingDictToggle objects in the API
Note that settings for which a corresponding SettingToggle or
SettingDictToggle exists are no longer exposed in the "django_settings"
list of the API.
2020-11-04 15:53:48 +01:00
Sarina Canelake
18059c20e7 Merge pull request #25505 from edx/sarina/gender-neutral-language
Change gendered language to gender-neutral 'they/them/their'
2020-11-03 16:16:59 -05:00
Régis Behmo
c9c1136459 Re-introduce waffle classes (with deprecation warnings)
This is for backward compatibility.
2020-11-03 19:25:37 +01:00
Régis Behmo
b70042435a Deprecate waffle_utils.testutils.override* functions
These functions should from now on be imported from
edx_toggles.toggles.testutils.
2020-11-03 19:25:37 +01:00
Régis Behmo
4586002956 Import waffle classes from edx_toggles instead of waffle_utils
Those classes were ported to edx_toggles. The imports remain in
waffle_utils.__init__ for backward compatibility.
2020-11-03 19:25:37 +01:00
Régis Behmo
3b127f8c92 Deprecate WaffleSwitch.override* methods
This allows us to get rid of the custom WaffleSwitch and
WaffleSwitchNamespace classes from waffle_utils in favour of
edx_toggles.toggles classes.
2020-11-03 19:25:37 +01:00
Régis Behmo
2307dff4c9 Deprecate WaffleFlag.override method
This allows us to get rid of waffle_utils' custom WaffleFlag method.
2020-11-03 19:25:37 +01:00
adeel khan
7cd9c6652a Merge pull request #25476 from edx/adeel/van_98_update_confirm_password_url_domain
Adds Logistration MFE url for forgot password email.
2020-11-03 13:40:03 +05:00
Mike OConnell
dbf6ef22df Using logging filters from edx-django-utils (#25492)
The UserIdFilter and RemoteIpFilter logging filter classes
were moved from edx-platform to edx-django-utils for more
distributed use. This updated removes those classes from
edx-platform, and references their counterparts in
edx-django-utils.

ENT-3494
2020-11-02 21:40:59 -05:00
sarina
f414fad0cc Change gendered language to gender-neutral 'they/them/their' 2020-11-02 18:23:13 -05:00
Robert Raposa
acd84598c9 Merge pull request #25504 from edx/robrap/ARCHBOM-1584-fix-monitoring-references
ARCHBOM-1584: remove internal references to edx_django_utils from tests
2020-11-02 18:12:12 -05:00
Robert Raposa
39a7c6498c remove internal references to edx_django_utils
Tests were referring to internal implementation
details of edx-django-utils. This comment removes
those references to free the library up to be
refactored.

ARCHBOM-1584
2020-11-02 16:46:11 -05:00
Soban Javed
3206d9cb9a Update celery routing
- Used routing function istead of class
- Move task queues to Djano settings
- Removed routing_key parameter
2020-11-02 15:03:53 +05:00
Dillon Dumesnil
6b16fcd9b3 AA-393: Update Next Section Logic
Inside content_highlights.py, we had code to calculate due dates
for when there isn't graded content, but we could only reach that
code path if the user had an assignment with a due date at the
target date. Now we will check for all learners who could be in
range of having an update and let the code in content_highlights.py
decide if a highlight should be sent
2020-10-30 15:02:03 -04:00
Robert Raposa
0cc46ca5b0 Merge pull request #25332 from regisb/regisb/use-settingdict
[BD-21] Use edx-toggle's SettingDictToggle to document setting-based feature toggles
2020-10-30 08:59:38 -04:00
Régis Behmo
312f0cd749 Fix error in toggle state endpoint in the absence of module_name
When module_name is None, the call to edx-django-utils'
get_code_owner_from_module crashes. So we avoid making that call when
the module_name is None, which sometimes happens (for good reasons or
not, but it's valid behaviour).
2020-10-29 22:59:53 +01:00
Régis Behmo
a27499830c Add deprecation warning comments to waffle_utils code 2020-10-29 22:59:53 +01:00
Régis Behmo
98ffa347d5 Fix waffle_utils unit tests 2020-10-29 22:59:53 +01:00
Régis Behmo
e5500b34a0 Backport override features from edx-toggles to waffle_utils
Note that those features are destined to be deprecated, eventually.
2020-10-29 22:59:52 +01:00
Régis Behmo
db5feec4cf Move waffle_utils/testutils.py to edx-toggles 2020-10-29 22:59:52 +01:00
Régis Behmo
58043727d5 [BD-21] Migrate waffle flag classes to edx-toggles
The same API is preserved, internally, to avoid many changes across the
edx-platform codebase (for now).
2020-10-29 22:59:52 +01:00
Régis Behmo
474da0c5a5 Refactor WaffleFlag and WaffleFlagNamespace internal API
This simplifies the internals of the waffle flag classes in order to
better move them to edx-toggles later.
2020-10-29 22:59:52 +01:00