Commit Graph

18841 Commits

Author SHA1 Message Date
Binod Pant
96ddcdc288 ENT-3007 : Add auth/saml/v0/providerconfig|data CRUD endpoints for use in admin portal (#24298)
* Add auth/samlproviderconfig CRUD endpoints for use in admin portal

Fixes: ENT-3007

* Move code to subfolder for samlproviderconfig

* extra comma

* undo accidental remove of import

* GET works for a single config now

* Use ModelViewSet to get all CRUD method. Test still fails

* Add auth/saml/v0/providerdata endpoints

* fixup reverse and test issue, remove leading caret

* just triggering run, why is it failing in CI?

* pycodelint fixes

* Skip auth tests unless feature is on

* Tests for post/put for samlproviderdata

* move urls to their own folders

* api tests for post samlprovierconfig

* create 1 providerconfig test case

* lint fixes

* lint

* lint

* cleanup code local urls /samlproviderconfig works

* note needed right now

* Fix import errors

* lint

* unused import

* wip: first attempt at rbac auth and jwt cookie in test

* round 2 with enterprise uuid as url param for samlproviderconfig

* improve tests, still dont pass

* fix test by using system role, wip other test

* fix create test

* add get/post tests for providerdata

* isort fixes

* string lint fix

* Cleanup based on feedback round1

* move utils to tests package

* Move util fn to openedx.feature area

* lint

* lint fix

* remove unused import
2020-07-10 11:23:13 -04:00
Feanil Patel
4ac2c5e92b Correct logic on building marketing links.
The logic used to has a special case for edge in the hostname which
didn't really make sense. So instead we just check to see if the given
url starts with http and if it does we return it directly.  If it doesn't,
then we try to convert it to a valid url and return that.  If that fails
we return .

Add a new custom metric `unresolved_marketing_link` to track when we
run into this scenario.
2020-07-09 15:09:38 -04:00
Feanil Patel
39dcd80211 Merge pull request #24428 from edx/feanil/404-on-not-found
If this reverse failed, it was throwing a 500.
2020-07-09 09:57:21 -04:00
edX Transifex Bot
542b33e1e0 geoip2: update maxmind geolite country database 2020-07-09 14:27:06 +05:00
Usman Khalid
4cc0f30db7 Convert WordCloudDescriptor and WordCloudModule into WordCloudBlock. 2020-07-09 09:46:54 +05:00
Feanil Patel
b6fdad2ea4 If this reverse failed, it was throwing a 500.
Catch the 500 in this case and throw a 404 instead.
2020-07-08 15:56:53 -04:00
Awais Qureshi
57f628a847 Merge pull request #24415 from edx/testeng/bokchoy_auto_cache_update_bac4b8ed6fb3d1273f95cf244f6242b76f73731e
Bokchoy Testing DB Cache update
2020-07-08 19:51:25 +05:00
Feanil Patel
e8a7529243 Merge pull request #24414 from edx/feanil/shoppingcart-remove-student-transfer-command-refs
DEPR-43 Remove shoppingcart certs refs.
2020-07-08 09:30:50 -04:00
Waheed Ahmed
4f80fd6540 Improve password reset rate limit.
Used django-ratelimit instead of django-ratelimit-backend
to configure two different rate limit configurations for same
endpoint.

PROD-1708
2020-07-08 16:19:07 +05:00
edX cache uploader bot
50a81db551 Updating Bokchoy testing database cache 2020-07-07 17:01:52 -04:00
Feanil Patel
20687f9548 DEPR-43 Remove shoppingcart certs refs.
There's a chance that the whole management command should be removed since we
don't do change modes with the command anymore but that's a different problem
for a different day I think.
2020-07-07 16:54:21 -04:00
Ali-D-Akbar
b2755a35a0 optimize course enrollment count query 2020-07-06 12:47:46 +05:00
Samuel Walladge
34516b9660 Consolidate get_transcript methods
There were two get_transcript methods. The broken one that was being
used (VideoTranscriptsMixin.get_transcript) is stripped out here - it
has been superseded by transcripts_utils.get_transcript. The latter
includes support for blockstore and VAL, while the former did not.

This fixes the `AttributeError: 'LibraryLocatorV2' object has no
attribute 'make_asset_key'` error seen when attempting to load a
transcript from a video through the xblock api when the video had the
transcript stored in blockstore.

Note that if you were previously using video.get_transcript, you should
now use `transcripts_utils.get_transcript(video, ...)`, and note that
the returned 'filename' will be prefixed with the language code, as
other `get_transcript*` functions already do.
2020-07-03 08:20:55 +09:30
Michael Terry
c9c548a550 Merge pull request #24365 from edx/ddumesnil/AA-220
AA-220: Making Library Content an Aggregator CompletionMode
2020-07-02 10:57:01 -04:00
edX cache uploader bot
691649362e Updating Bokchoy testing database cache (#24374) 2020-07-02 09:51:28 -04:00
Dillon Dumesnil
35549f56ba AA-220: Making Library Content an Aggregator CompletionMode
This change will prevent Library Content from being marked as
complete on view and the corresponding version bump to
edx-completion contains code that will start looking at the
children of the library content for completeness.
2020-07-01 17:33:54 -04:00
edX Transifex Bot
cb0973317e geoip2: update maxmind geolite country database 2020-07-01 17:16:01 -04: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
edX cache uploader bot
7bfbd3104e Updating Bokchoy testing database cache (#24334) 2020-06-29 13:58:42 +00:00
Aarif
9e34cb3df9 Removed deprecated future imports (#24295) 2020-06-28 23:40:03 +05:00
Danial Malik
c962423bbc Replace track calls with eventtracking in task_track and server_track (#24282)
* Replace track calls with eventtracking in task_track and server_track

* Making  events compatible with events emitted via track app

* Fixed broken tests and quality violation

* Removed useless changes in shim. using  in  to have  and  keys in event context

Co-authored-by: zia.fazal@arbisoft.com <zia.fazal@arbisoft.com>
2020-06-26 13:49:16 -04:00
Matt Tuchfarber
4f1cd91113 Re-Add demographics prompt to edx.org theme (#24231)
- Add bootstrap utility function to lms-base-v1 CSS
- Moved coaching sass to edx.org theme
- Banner feature flag and MB program gated
- Fixes previous issue of changes specificity in button selector by
  resetting the style inside the component's class
2020-06-25 14:47:08 -04:00
Diana Huang
8a1fad8c12 Merge pull request #24181 from edx/diana/dashboard-courses-blocked
DEPR-43: Remove usage of CourseRegistrationCode and blocked courses from
2020-06-25 13:59:26 -04:00
Awais Qureshi
05b98cbba2 Merge pull request #24297 from eduNEXT/lmm/try_to_fix_migration_problem
[BD-6] Attempt to fix db sync problem for python3.8
2020-06-25 20:29:29 +05:00
Zachary Hancock
bcc1ddd375 add proctoring escalation contact setting (#24243) 2020-06-24 16:02:17 -04:00
Awais Qureshi
af3691ed52 Merge pull request #24311 from eduNEXT/eric/bom-1748
[BD-6] Order VideoBlock html metadata alphabeticallly to fix test.
2020-06-24 22:31:36 +05:00
Dillon Dumesnil
a7dff8c21e Merge pull request #24303 from edx/ddumesnil/due-dates-in-courseware-AA-44
AA-44: Adding due dates into courseware
2020-06-24 09:22:01 -07:00
Luis Moreno
ba297ab16c Solve quality issues 2020-06-24 12:10:09 -04:00
Eric Herrera
c40aa67fd0 Order VideoBlock html metadata alphabeticallly to fix test. 2020-06-24 12:07:55 -04:00
Luis Moreno
5fe377cc77 Attempt to fix db sync problem for python3.8 2020-06-24 11:58:23 -04:00
morenol
8c53fa4a47 async is a keyword in python>=3.7 (#24265)
the new keyword async is causing errors when we run this with python 3.8.
https://docs.python.org/3/whatsnew/3.7.html

I tried in the first place, to change the definition of that value in the place where the context is defined, but it seems that it is taken from https://github.com/jazzband/django-pipeline,

This solves many problems for lms and cms tests that were making the jenkins workers get timeout.

That template have not seen changed since 2012, so I had to do additional changes in the templates in order to pass the xsslint checks:

mako-missing-default
mako-invalid-html-filter

I am not sure about the remove of the safe filter.

But I didn't found information about the 'safe' filter. It is probably that the now default 'h' filter is enough.
2020-06-24 11:55:03 -04:00
Dillon Dumesnil
7f6a2518cb AA-44: Adding due dates into courseware
Due dates will only display for graded subsections.
If the assignment has already been completed, there will be a pill
to indicate that. If the assignment is past due, there will be a
pill. If it is upcoming, there are no pills
2020-06-24 08:26:52 -07:00
Diana Huang
6aa300711b Remove usage of CourseRegistrationCode and blocked courses from
dashboard.
2020-06-24 09:38:20 -04:00
M. Zulqarnain
39b109a9ad Fixed bad escape character (#24316)
As of Python 3.7, a backslash-character pair that is not a valid escape sequence now generates an error, earlier it was a deprecation warning.
2020-06-24 18:23:11 +05:00
Waheed Ahmed
ab72a9d87d Fix embargo message issues.
PROD-1753
2020-06-24 14:45:47 +05:00
Awais Qureshi
b7500cd2a0 Merge pull request #24268 from eduNEXT/lmm/safe_exec
[BD-6] Fix test for python3.8
2020-06-24 13:39:35 +05:00
Awais Qureshi
9445a7b2e0 Merge pull request #24306 from edx/awais786/BOM-1750
BOM-1750
2020-06-24 11:45:58 +05:00
Awais Qureshi
b4035bc71e BOM-1750
DeprecationWarning `callable is None` raised  since 3.5 throwing TypeError.
Fixed the assertion.
2020-06-24 01:43:09 +05:00
edX cache uploader bot
5bd0d317ac Updating Bokchoy testing database cache (#24304) 2020-06-23 20:15:57 +00:00
Nick
e8fc653c86 Merge pull request #24285 from edx/ndalfonso/AA-142-calendar-sync-ses
AA-142 calendar sync ses
2020-06-23 13:52:42 -04:00
Nicholas D'Alfonso
5b1d181491 AA-142 calendar sync ses
- set up util function to use Amazon SES for sending calendar
  sync emails.
- remove old sailthru code which we originally implemented for
  this functionality
- include ADR on our decision to use SES instead of Sailthru.
2020-06-23 12:14:03 -04:00
Matthew Piatetsky
b3c2d37dcc Merge pull request #24214 from edx/REV-774
[REV-774] Show content type gating upsell when a limited access learner tries to access a timed exam
2020-06-23 11:48:31 -04:00
Luis Moreno
1d557616b1 Fix test for python3.8 2020-06-23 10:16:37 -04:00
Aarif
27480cdd2f Removed deprecated future imports 2020-06-23 18:51:43 +05:00
Matthew Piatetsky
78317ca115 Show content type gating upsell when a limited access learner tries to access a timed exam
Otherwise, these learners could start the timer and then be unable to take the exam once they have access to the content
REV-774
2020-06-22 16:18:58 -04:00
leomartinez2019
943bd6f15b Fixing cgi.escape DeprecationWarning
- Change cgi.escape to html.escape

- Add quote=False to html.escape

- Use function HTML() to address python-wrap-html warning
2020-06-22 14:41:27 -04:00
Awais Qureshi
576ad48dbd Merge pull request #24274 from eduNEXT/eric/py38_dict_insertion_order
[BD-6] Update dicts order to fix tests
2020-06-22 20:10:49 +05:00
edX cache uploader bot
98ebb2df44 Updating Bokchoy testing database cache (#24269) 2020-06-22 09:02:48 -04:00
Eric Herrera
3cdd5c4d27 Change some tests dict order to fix assertion after python 3.7 change of preserving insertion order in dicts. 2020-06-21 09:32:34 -05:00
Michael Roytman
361a2c92b3 Merge pull request #24266 from edx/mroytman/course-fields-exclude-list
rename blacklist/whitelist to exclude list/include list in Course Met…
2020-06-19 16:42:10 -04:00