Commit Graph

230 Commits

Author SHA1 Message Date
Bianca Severino
4fc5713792 fix: validate the media type of uploaded IDV images 2021-04-02 10:49:08 -04:00
alangsto
027704adae Added optional param on submit post request to mark experiment name (#26925) 2021-03-11 10:31:47 -05:00
M. Zulqarnain
ba86198519 pyupgrade on verify_students app (#26648) 2021-03-02 16:45:01 +05:00
Aarif
c828beb5d1 replaced unittest assertions pytest assertions (#26549) 2021-02-23 10:24:42 +05:00
alangsto
f88181c3c8 update context key/value pair being used for approved email (#26635) 2021-02-19 14:15:09 -05:00
M. Zulqarnain
feaf5011c8 BOM-2287 : Pylint amnesty in teams,tests,survey and verify_student (#26305)
* lint amnesty in teams,tests,survey and verify_student
2021-02-03 18:15:03 +05:00
alangsto
e9dc5baf79 added two endpoints for IDV decryption on stage (#25939)
simplified public keys

made migration

fixes for quality

added pylint fixes

fixed for pylint

added endpoint to retrieve user's receipt_ids

added tests for 404 with decryption error

fixed for quality

fixed for quality

updates for feedback

removed unnecessary method

fixed quality issue

updated tests
2021-01-07 09:05:33 -05:00
alangsto
30d4106659 added endpoint to retrieve IDV photo urls (#25909)
fixed quality issues

added comment

updated for comments

fixing test

removed typo

readded files

moved settings override

testing adding other keys

not overriding setting
2020-12-18 08:14:44 -05:00
Kyle McCormick
bb30a27b3e Revert "added endpoint to retrieve IDV photo urls (#25903)"
This reverts commit 356f187559.
2020-12-17 17:08:58 -05:00
alangsto
356f187559 added endpoint to retrieve IDV photo urls (#25903)
fixed quality issues

added comment

updated for comments
2020-12-17 16:13:32 -05:00
Simon Chen
00ad36839d MST-542 Roll out Accounts MFE IDV workflow (#25613)
* MST-542 remove the IDV redirect to Account MFE waffle flag to permanently redirect learners to new IDV workflow. This completes the rollout process on edx-platform
2020-12-01 09:08:12 -05:00
Bianca Severino
56d7ff8017 Set expiration_date field in IDVerificationAttempt model 2020-11-10 15:29:47 -05:00
Bianca Severino
82e8592fbe Revert "Set expiration_date field in IDVerificationAttempt model" 2020-11-10 14:24:07 -05:00
Bianca Severino
3342524699 Update IDVerificationAttempt to use expiration_date field 2020-11-10 11:15:04 -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
Kyle McCormick
d1a775d3cd Use full names for lms.djangoapps imports (#25401)
* Use full LMS imports paths in LMS settings and urls modules
* Use full LMS import paths in Studio settings and urls modules
* Import from lms.djangoapps.badges instead of badges
* Import from lms.djangoapps.branding instead of branding
* Import from lms.djangoapps.bulk_email instead of bulk_email
* Import from lms.djangoapps.bulk_enroll instead of bulk_enroll
* Import from lms.djangoapps.ccx instead of ccx
* Import from lms.djangoapps.course_api instead of course_api
* Import from lms.djangoapps.course_blocks instead of course_blocks
* Import from lms.djangoapps.course_wiki instead of course_wiki
* Import from lms.djangoapps.courseware instead of courseware
* Import from lms.djangoapps.dashboard instead of dashboard
* Import from lms.djangoapps.discussion import discussion
* Import from lms.djangoapps.email_marketing instead of email_marketing
* Import from lms.djangoapps.experiments instead of experiments
* Import from lms.djangoapps.gating instead of gating
* Import from lms.djangoapps.grades instead of grades
* Import from lms.djangoapps.instructor_analytics instead of instructor_analytics
* Import form lms.djangoapps.lms_xblock instead of lms_xblock
* Import from lms.djangoapps.lti_provider instead of lti_provider
* Import from lms.djangoapps.mobile_api instead of mobile_api
* Import from lms.djangoapps.rss_proxy instead of rss_proxy
* Import from lms.djangoapps.static_template_view instead of static_template_view
* Import from lms.djangoapps.survey instead of survey
* Import from lms.djangoapps.verify_student instead of verify_student
* Stop suppressing EdxPlatformDeprecatedImportWarnings
2020-11-04 08:48:33 -05:00
Jeremy Bowman
d19368525b DEPR-43 Remove most of the shoppingcart app (#24692)
Removed most of the deprecated shoppingcart app, leaving just enough to allow us to cleanly remove the related database tables later. Also removed the relevant Django settings that weren't in use elsewhere.
2020-10-14 14:24:52 -04:00
Diana Huang
657da20c6e DEPR-43 - Remove JS that refers to shoppingcart receipt page. (#24890)
https://openedx.atlassian.net/browse/DEPR-43

Co-authored-by: Jeremy Bowman <jbowman@edx.org>
2020-09-29 16:08:42 -04:00
Awais Jibran
adaa701a76 Deprecate old idv code 2020-07-09 11:53:16 +05:00
Daniel Francis
82c0ca0da8 Fixing implicit parser name for Beautiful Soup (lms, openedx) (#24100)
Fixing 56 GuessedAtParserWarnings, in commit edx#24098

Background: BeautifulSoup automatically picks the fastest parser available. By default, it picks the "lxml" parser.

Per the [BeautifulSoup](https://www.crummy.com/software/BeautifulSoup/bs4/doc/#installing-a-parser) documentation:

> Beautiful Soup supports the HTML parser included in Python’s standard library, but it also supports a number of third-party Python parsers. One is the lxml parser. Depending on your setup, you might install lxml with one of these commands.
> Another alternative is the pure-Python html5lib parser, which parses HTML the way a web browser does. 

Context: We changed two statements, one in lms and another in openedx. Both statements fire up BeautifulSoup. Now we explicitly ask for "lxml," following the recommendation on BeautifulSoup's documentation:

> If you can, I recommend you install and use lxml for speed. If you’re using a very old version of Python – earlier than 2.7.3 or 3.2.2 – it’s essential that you install lxml or html5lib. Python’s built-in HTML parser is just not very good in those old versions.

Before:
`soup = BeautifulSoup(content)`

After:
`soup = BeautifulSoup(markup=content, features="lxml")`

The warnings are gone, tests are passing in local.
2020-06-18 15:41:07 -04:00
Diana Huang
c7bd5a8a15 Remove more references to fix tests. 2020-06-09 13:06:44 -04:00
Aarif
98af9ce418 remove useless-supression warnings 2020-05-01 19:42:15 +05:00
Awais Jibran
465d864c77 Adds settings for celery task auto discovery 2020-04-23 12:52:16 +05:00
adeelehsan
0e3bf36ced Verification enabled for the software secure
PROD-1395
2020-04-17 12:26:12 +05:00
Awais Jibran
804fac9358 Adds retry logic for software secure 2020-04-13 14:14:11 +05:00
Ahtisham Shahid
34d126f9e5 changed verification email type to html
changed verification email type to html

changed verification email type to html

changed verification email type to html
2020-04-08 14:50:49 +05:00
Waheed Ahmed
3dc3e10819 Revert "Adds retry logic for software secure." 2020-04-07 20:40:06 +05:00
Awais Jibran
4b22554411 Merge pull request #23514 from edx/aj/ss-retry-logic
Adds retry logic for software secure.
2020-04-07 10:59:57 +05:00
Diana Huang
99863aebff Remove course_id field from CourseMode.
Handle this change appropriately in CourseModeFactory.
2020-04-06 11:21:28 -04:00
Awais Jibran
4ead215665 Adds retry logic for ss.
1. Created a new celery queue with key `SOFTWARE_SECURE_VERIFICATION_ROUTING_KEY`.
2. Added a celery task with retry logic.
3. sorted imports with isort.
4. Changed deprecated `log.warn` => `log.warning`.
2020-04-06 15:16:56 +05:00
Awais Qureshi
9fc3dcb5d6 BOM-1490
None is not a valid value for posting.
2020-04-04 21:07:55 +05:00
Awais Qureshi
220cab965f BOM-1126
Removing the moto from repo.
2020-01-15 22:34:13 +05:00
Feanil Patel
046feb0cf0 Merge pull request #22649 from edx/feanil/fix_pep8
Fix all E303 pep8 errors.
2019-12-30 13:32:26 -05:00
Feanil Patel
6e3fe00fff Fix all E303 pep8 errors. 2019-12-30 12:25:38 -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
aarif
164141def9 replaced json.loads with a util to handle bytes
changes made to fix jenkins/quality errors

changes made as suggested

added the docstring to fix quality issue

made a few changes to fix some tests

replaced json.loads with a util to handle bytes

changes made to fix jenkins/quality errors

changes made as suggested

added the docstring to fix quality issue

made a few changes to fix some tests

made changes as suggested

made changes as suggested

updated the requirements with make upgrade
2019-10-16 12:14:01 +05:00
Awais Qureshi
f679768f9e BOM-925
Fixing TypeError, the JSON object must be str, not 'bytes'.
2019-10-15 12:57:49 +05:00
Nimisha Asthagiri
a6b219a9e9 Python-3: assertIn(..response.content) -> assertContains 2019-09-30 08:50:38 -04:00
Feanil Patel
f259a911c7 BOM-618 Decode content we get from test requests. 2019-09-19 10:32:23 -04:00
Feanil Patel
3427c1abf3 BOM-618 Pass unicode to json.loads 2019-09-18 16:28:11 -04:00
Ayub
2c1fc22af9 Merge pull request #21484 from edx/BOM-264
BOM-264
2019-09-04 12:48:13 +05:00
Ayub
0b29872808 Merge pull request #21479 from edx/BOM-289
BOM-289
2019-09-04 11:11:19 +05:00
Ayub
eb133f61ac Merge pull request #21480 from edx/BOM-335
BOM-335
2019-09-04 11:09:56 +05:00
Ayub khan
eef343d212 BOM-264
py3 unit test fix
2019-08-28 15:49:58 +05:00
aarif
ee264b38e9 python 3 fixes 2019-08-28 15:44:35 +05:00
Ayub khan
f7d528eee4 BOM-289
py3 unittest fix
2019-08-28 15:09:48 +05:00
Ayub khan
70b4004be8 BOM-335
py3 unittest fix
2019-08-28 15:07:29 +05: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