Commit Graph

118 Commits

Author SHA1 Message Date
Michael Terry
c697acec2b Merge pull request #26927 from edx/mikix/ace-braze
feat: update to edx-ace 1.0.0
2021-03-12 11:05:30 -05:00
Michael Terry
570a869bd3 feat: update to edx-ace 1.0.0
The new version switches how you specify recipients, to use
lms_user_id instead of usernames.

AA-489
2021-03-12 10:25:54 -05:00
Matjaz Gregoric
6204e5bcec Fix URL in forum notification post.
urljoin('my.domain.com', '/my/path') returns '/my/path'. We have to make
sure to use the full base url (starting with http(s)://) and not just
the site's domain.
2021-03-08 08:32:13 +01:00
usamasadiq
96f0915b0f Fixed new pylint warnings.
use generator in any/all()
disable not-callable warnings
disable no-member warnings
Suppressed smaller pylint warnings
Pin edx-proctoring==3.5.0
2021-02-22 16:36:53 +05:00
edX requirements bot
f33f12bbea BOM-2358 : Pyupgrade in dashboard, debug, discussion apps (#26529)
* Python code cleanup by the cleanup-python-code Jenkins job.

This pull request was generated by the cleanup-python-code Jenkins job, which ran
```
cd lms/djangoapps/dashboard; find . -type f -name '*.py' | while read fname; do sed -i 's/  # lint-amnesty, pylint: disable=super-with-arguments//; s/  # lint-amnesty, pylint: disable=import-error, wrong-import-order//; s/  # lint-amnesty, pylint: disable=wrong-import-order//' "$fname"; done; find . -type f -name '*.py' | while read fname; do pyupgrade --exit-zero-even-if-changed --py3-plus --py36-plus --py38-plus "$fname"; done; isort --recursive .
```

The following packages were installed:
`pyupgrade,isort`

* feedback done

Co-authored-by: Zulqarnain <muhammad.zulqarnain@arbisoft.com>
2021-02-22 15:42:21 +05:00
Aarif
a8b9733654 replaced unittest assertions pytest assertions (#26544) 2021-02-19 11:59:44 +05:00
M. Zulqarnain
65cf0db337 BOM-2278 : Pylint amnesty in discussion, dashboard (#26275)
* pylint amnesty in discussion, dashboard
2021-02-03 18:15:14 +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
Jansen Kantor
2ea6b253d6 allow plus or minus one (#24637) 2020-07-29 16:03:41 -04:00
Jansen Kantor
bf66c177ff EDUCATOR-5167: Fix Flaky Discussions Test (#24532)
* Revert "Delete flaky test according to process (#24441)"

This reverts commit 87edb542b1.

* fix flaky test, give count assert 1-query tolerance
2020-07-20 10:44:44 -04:00
Tim McCormack
87edb542b1 Delete flaky test according to process (#24441)
https://openedx.atlassian.net/browse/CR-2425 for re-evaluating it
2020-07-10 13:39:13 +00:00
Michael Terry
3030efec78 AA-177: Add masquerading for course home MFE
- Looks at masquerading config for dates, outline, metadata, and
  celebration APIs in course_home_api / courseware_api.
- Consolidates and cleans up places we check whether masquerading
  gives us full access to a course.
2020-06-29 12:37:47 -04:00
Aarif
98af9ce418 remove useless-supression warnings 2020-05-01 19:42:15 +05:00
usamasadiq
32a8c33055 Django2.2 Post request update 2020-04-06 16:10:26 +05:00
Troy Sankey
d428f7530d Revert "Revert "Rename values in SiteConfiguration (2/3) attempt #2""
This reverts commit e6f58b6d4c.

This is our third (3rd!) attempt to deploy stage 2 of this column rename.
2020-03-04 14:53:47 -05:00
Troy Sankey
e6f58b6d4c Revert "Rename values in SiteConfiguration (2/3) attempt #2" 2020-02-27 13:24:55 -05:00
Troy Sankey
c422dec083 Revert "Revert "Rename values in SiteConfiguration (2/3)""
This reverts commit b85aa4b3fb.
2020-02-26 12:54:24 -05:00
Troy Sankey
b85aa4b3fb Revert "Rename values in SiteConfiguration (2/3)" 2020-02-26 11:23:56 -05:00
Julia Eskew
3541643dd5 Rename values in SiteConfiguration (2/3)
This stage does the following:

- Includes a data migration to copy the values from old to new field.
- Changes business logic to switch to using new field.
- Deletes all code references of the old field.
2020-02-25 13:54:02 -05:00
Troy Sankey
18deacde54 Revert "Revert "This stage does the following: (#22692)""
This reverts commit 84de6bc6de
which reverts commit cebeab4348
which implements the first stage of the `values` column rename in
SiteConfiguration.  However, I included a small change:

This time, we set a default value on the new `site_values` column so
that the ORM will happily deserialize the JSONField without throwing a
JSONDecodeError.
2020-02-19 12:01:57 -05:00
Jansen Kantor
25baa93af9 EDUCATOR-4877: Implement stubbed API functions using new config values (#22913)
add stubbed api functions, tests
2020-01-24 15:54:32 -05:00
Julia Eskew
84de6bc6de Revert "This stage does the following: (#22692)"
This reverts commit cebeab4348.
2020-01-14 13:01:21 -05:00
Julia Eskew
cebeab4348 This stage does the following: (#22692)
- Adds the new field and migration to create the column.
- Makes all writes go to both old and new field.
2020-01-14 10:40:39 -05:00
David Ormsbee
2cb2265ffe Add request caching to reduce ORM queries
This adds request caching to the following places:
* course expiration wrapper (displayed in Units)
* offer banner generation (displayed in Units)
* get_enrollment
* user_by_anonymous_id
* youtube_disabled_for_course

On a sample course with edx-val enabled, this reduced the queries
for a large sequence from 450 to 155.
2019-12-30 16:19:25 -05:00
Feanil Patel
2df8b8226b Merge pull request #22643 from edx/feanil/2to3_asserts
Run `2to3 -f asserts . -w` on edx-platform.
2019-12-30 12:13:42 -05:00
Feanil Patel
9cf2f9f298 Run 2to3 -f future . -w
This will remove imports from __future__ that are no longer needed.

https://docs.python.org/3.5/library/2to3.html#2to3fixer-future
2019-12-30 10:35:30 -05:00
Feanil Patel
70294b0ad2 Run 2to3 -f asserts . -w on edx-platform.
https://docs.python.org/3.5/library/2to3.html#2to3fixer-asserts
2019-12-30 10:22:19 -05:00
Matthew Piatetsky
bd76a71019 delete old holdback code 2019-11-07 09:51:39 -05:00
Kyle McCormick
7dbee1c3dd Ensure Python 3 compatibility of Teams djangoapp (#22096)
* For all files, from __future__ import unicode_literals.
* Add @python_2_unicode_compatible to both models.
* Test six.string_type(obj) for both models.

Also, fix some new pylint warnings and improve model repr methods.

MST-24
2019-10-22 13:42:27 -04:00
Kyle McCormick
cd3bc236eb Make the team discussion thread private
Develop the capability to allow instructors to designate teams to have private discussions. This way, so non-teammembers cannot view discussion. And the intend is for course teams to manage the team membership as well.
MST-10
2019-10-18 13:06:50 -04:00
Nimisha Asthagiri
4914c42364 Python 3: resp.content regex searches 2019-09-30 08:51:02 -04:00
Ayub khan
06c7e3e4e9 BOM-420
fixed all file tests
2019-09-13 18:39:00 +05:00
Feanil Patel
68933ec089 Fix quality issues. 2019-08-19 11:51:30 -04:00
David Ormsbee
9a1385585f Convert response bytes to str before JSON parsing. (#21375)
Convert response bytes to str before JSON parsing.
2019-08-19 11:01:55 -04:00
Feanil Patel
9d7f0ca46e Get LMS test collection working in python 3.
This should be all the changes needed to get test collection working in
python 3 for the `lms` folder.
2019-08-13 16:32:40 -04:00
Jeremy Bowman
ff7292538e More pylint fixes (#20692) 2019-05-28 09:19:31 -04:00
Stu Young
51948f8895 INCR-306 Run python-modernize on lms/djangoapps/discussion/settings and lms/djangoapps/discussion/tests (#20619)
* run python modernize

* run isort

* Fix quality
2019-05-21 11:44:00 -04:00
Nimisha Asthagiri
dfa3728edf Move django_comment_common from common to openedx 2019-05-03 12:10:18 -04:00
Nimisha Asthagiri
e160b23903 Move django_comment_client to discussion/ 2019-05-03 12:09:46 -04:00
Nimisha Asthagiri
16edae0822 Move comment_client into django_comment_common 2019-05-03 12:07:20 -04:00
Nimisha Asthagiri
ef0e06cc0a Revert "Discussions consolidation" 2019-05-02 14:59:56 -04:00
Nimisha Asthagiri
df962a31b7 Move django_comment_common to openedx/core/djangoapps/discussion_common 2019-05-01 19:15:02 -04:00
Nimisha Asthagiri
db89a64d06 Move django_comment_client to discussion/ 2019-05-01 19:13:10 -04:00
Nimisha Asthagiri
2839851bde Move comment_client into django_comment_common 2019-05-01 19:13:09 -04:00
Calen Pennington
4c8cd60bbc REVMI-96: Add a management command to experiment with Access Expiry reminder emails for FBE 2019-03-06 11:44:29 -05:00
Calen Pennington
300c3a34dd Don't swallow exceptions inside emulate_http_request 2019-03-06 11:44:29 -05:00
Michael Youngstrom
3221c2b91f Remove lms pytest shards 2019-02-12 11:03:46 -05:00
Matthew Piatetsky
6e81c84d8b fix unicode strings in lms/ part 1 2019-02-05 15:15:02 -05:00
Matthew Piatetsky
14a899a65d REVE-104 & REVE-108: Ensure Course Roles' Access 2018-12-07 16:39:09 -05:00
brianhw
acc919ca46 Merge pull request #19353 from edx/brian/DE-1121-email-context
Add page context to edx.bi.email.sent events
2018-12-04 12:10:27 -05:00