Commit Graph

1290 Commits

Author SHA1 Message Date
Feanil Patel
e35c7e278b build: Simplify how we build docs.
Instead of trying to use the devstack settings file for building docs,
use the common settings file as the base for all settings.  The
devstack settings file builds on top of the production settings file
which are both oriented around reading settings from a yaml file and
getting them loaded in sanely into the dev and production environment.

For documentation, start with the common settings files which should be
sufficient to get a default version of the system up and running.

Note: We still leave the loop that enables all the feature flags as a way
of finding conditionally included API endpoints.
2022-03-25 10:08:21 -04:00
Awais Qureshi
856731fd48 docs: Removing bokchoy and a11y reference from documentation. (#30105)
* docs: Removing bokchoy and a11y reference from documentation.
2022-03-24 18:26:43 +05:00
Chris Deery
e8462bb667 feat: [AA-1207] remove redundant Tabs fields from courseware API (#30079)
feat: [AA-1207] remove redundant Tabs fields from courseware API

Remove redundant fields from courseware API.

- number
- verified_mode
- original_User_is_staff
- is_staff

This is the backend work for https://github.com/openedx/frontend-app-learning/pull/873
2022-03-18 12:09:52 -04:00
Chris Deery
50f348b395 feat: [AA-1207] remove redundant Tabs fields from courseware API (#30023)
* feat: [AA-1207] remove redundant Tabs fields from courseware API

All the tab information now goes through the course home metadata tab fields. This field is redundant.
2022-03-11 09:36:28 -05:00
Chris Deery
b61b29196b feat: [AA-1206] remove redundant fields from API (#29920)
* feat: [AA-1206] remove redundant fields from API

Part of a larger effort to clean up the MFE BFF endpoints.
Remove the redundant fields username and course_access, both of which are also available in the course home metadata call.
2022-03-04 09:01:02 -05:00
Carlos Muniz
8e8d8404be Carlos muniz/symmath removal unrevert (#29912)
* Revert "Merge pull request #29909 from openedx/revert-29869-Carlos-Muniz/symmath-removal"

This reverts commit 8c0db8ddff, reversing
changes made to 1156c62014.

* fix: Remove misplaced `-e`

`-e` was wrongfully placed in front of `common/lib/sandbox-packages`,
which may have most likely been causing the edxAPP to break.

* fix: Change regex to apply to right dirs

`py38.txt` does not include `common/lib/xmodule` so it doesn't match the
regex. Therefore, it never got its lines in `common/lib/sandbox-packages`
fixed. If we change the regex to match any `common/lib/<packagename>` it
should work correctly.
2022-02-14 10:26:40 -05:00
Phillip Shiu
6ac1dd688a Revert "Remove symmath from edx-platform" 2022-02-11 10:30:08 -05:00
Carlos Muniz
b80d8d6030 refactor: Remove all mentions of symmath 2022-02-10 14:55:22 -05:00
Kyle McCormick
51fccf06d1 docs: add ADR to declare distinction between 'cms' and 'studio' 2022-01-04 15:07:04 -05:00
Michael Terry
ff453d1ad6 chore: delete ancient unused ADRs for system dashboard
This is long deprecated and these ADRs just document why it doesn't
exist. They've explained that long enough that we can just remove
this.
2021-11-23 15:47:27 -05:00
ayub02
9ac8e59c26 [ERTE-22-2] docs: created ADR for course completion events (#28424)
* docs: created ADR for course completion events

Co-authored-by: Aamir Ayub <aamirayub@Arbisofts-MacBook-Pro.local>
2021-10-27 14:56:26 +05:00
Tim McCormack
b0cc253c99 docs: Switch to management commands in Studio OAuth Maple migration (#29057)
This has the side effect of requiring creation of a `studio_worker` service
account, since the `create_dot_application` command requires a user arg,
but this better matches other IDAs.
2021-10-20 21:02:48 +00:00
Felipe Montoya
678c159cf8 docs: adding the first version of documentation for open edx events
Includes:
- general documentation
- links to individual events definitions and location
- adding examples to events docs
- adding annotations at the trigger location
2021-10-13 15:28:24 -05:00
David Ormsbee
da2bae21ae docs: ADR for Limit LMS Modulestore access
Explains why we want to limit Modulestore access, along with some
guidelines about what to use instead.
2021-10-07 11:10:24 -04:00
Tim McCormack
e97070808f doc: Update Studio OAuth migration guide for use in Maple release notes (#28784)
- No longer written with a seamless transition in mind. It's probably
  possible, but untested, and I believe most deployments do a hard cutover
  anyhow. Since this is just Studio, logging everyone out is probably
  acceptable.
- Remove decline-migration section since we don't believe anyone is likely
  to need this (and we're deprecating it anyhow.)
- Remove `/login/` config changes, since those have already been performed
  in the common env and were only required for seamless migration. Remove
  cleanup for same reason.
- Give hint about domain-changing

ref ARCHBOM-1890
2021-09-20 18:14:41 +00:00
Tim McCormack
dbb473f490 refactor: Studio OAuth cleanup, part 1 (#28760)
- Update migration instructions
    - Changes regarding redirect URLs and cookie domain are to permit the
      site to run on multiple domains.
- Set LOGIN_URL in common so that it can be unset in environment overrides

This bypasses the "redirect to LMS" login/signup code, but does not yet
remove it; removal is covered by DEPR-166 so that this remains a
configuration-only change for now.

There should have no user-visible effect.

ref: ARCHBOM-1890
2021-09-16 16:16:45 +00:00
Tim McCormack
0c164ad4c2 fix: Fix Studio logout by pointing to correct logout view (#28714)
This changes the "Sign out" link on Studio to point to Studio's own logout
view, which clears the session and then redirects to LMS's logout page. The
LMS logout page then skips loading the Studio logout because it is seen in
the Referer header.

This change also brings Studio better into line with how other IDAs perform
their logouts.

Background:

After the rollout of Studio OAuth, logouts initiated on Studio failed to
actually log out Studio (but all other IDAs were logged out). This was
because the LMS logout view loads the logout pages of other IDAs but skips
any that is a *prefix* match on the Referer header, and browsers now often
send a truncated version of the Referer for privacy. Therefore, Studio was
always skipped when coming from Studio.

The fix is to make sure that Studio has already performed its logout by the
time the LMS logout page is loaded.

One wrinkle here is that the LMS logout view is activated by `/logout`, but
the correct logout view (provided by auth_backends) is activated by
`/logout/` -- with a trailing slash. This is fragile and unfortunate, but
can be cleaned up when we later remove other leftovers of Studio's previous
ability to handle logistration.

ref: ARCHBOM-1897
2021-09-10 18:45:58 +00:00
Tim McCormack
84441bfd3a doc: Update studio oauth migration runbook for session cookie name change (#28600)
This is probably the least-disruption approach we can reasonably manage.

Also fix formatting in nested list.
2021-09-03 18:24:42 +00:00
Tim McCormack
303d7923eb doc: Add logout-uri step in studio oauth instructions (#28548) 2021-08-25 19:54:36 +00:00
Tim McCormack
f75ae33580 feat: Implement (but don't activate) LMS OAuth2 SSO login for Studio (#28533)
Once LOGIN_URL is changed for an environment, the OAuth flow will be
activated. (See included temporary doc.)

This is for ARCHBOM-1860: Convert Studio to use LMS OAuth login.
2021-08-25 16:16:48 +00:00
Binod Pant
33cdf634b4 refactor: Extract core functionality of enrollment api in a python api to avoid REST calls from edx-enterprise (#28202)
* feat: Refactor out non REST portions of enrollment api from enrollment POST method

For use with edx-enterprise to avoid making REST calls for bulk enrollment and other use cases

ENT-4746

* feat: Remove unused test

Testing is covered by test_views

* refactor: isort

isort fixes

* docs: ADR for why this change

ADR

ENT-4746

* test: Fix test failure by restoring course_id to correct object

* test: Test fix

* refactor: pylint fixes

* refactor: raise from to avoid pylint error

* refactor: Start to work toward a util in enterprise_support instead of refactoring this endpoint

* feat: Add util function in enterprise_support to eventually handle enrollment, only used by bulk enrollment for now

* feat: One more revised idea, this time low risk in edx platform and also helps address enterprise specific flow. testing pending

* feat: syntax and unused constant

* feat: Restore view and add new util function to use in edx-enterprise instead

* feat: breakpoint

* unused import

* feat: don't fail on existing enrollment

* docs: ADR update

* docs: docstring minor update

* test: unit test add_user_to_course_cohort

* refactor: imports

* feat: remove unused error classes

* refactor: lint

* test: Test cases

* test: Two more tests for negative cases

* feat: missing init.py file

* test: Fix tests to use correct user mock

* unused import

* refactor: Review feedback, test fixes, needs rebase now

* feat: rebase changes

* feat: keep audit_log with similar logic as in the view

* refactor: Review feedback, test constant usage
2021-07-21 16:59:45 -04:00
Diana Huang
29548459fa refactor: Remove PyContracts usage. (#27887)
* refactor: Remove PyContracts usage.

We have not used PyContracts in a while and it is overhead we don't
need in edx-platform.

https://openedx.atlassian.net/browse/DEPR-147

* chore: Updating Python Requirements (#28018)

Co-authored-by: edX requirements bot <49161187+edx-requirements-bot@users.noreply.github.com>
2021-06-23 18:24:06 -04:00
Kshitij Sobti
d2c2fcdefe feat: Course Apps API [BD-38] [TNL-8103] [BB-2716] (#27542)
* feat: Course Apps API

This adds a new concept called course apps. These are exposed via a new
"openedx.course_app" entrypoint, which helps the LMS and studio discover such
apps and list them in a new rest api for the same.

These course apps will drive the pages and resources view in the course authoring
MFE. This system will track which apps are enabled and which are disabled. It
also allows third-party apps to be listed here by using the plugin entrypoint.

* Apply feedback from review
2021-06-23 21:51:12 +05:00
Kshitij Sobti
161e3560dd feat: Add REST endpoints for problem response report generation that can be driven by MFEs. (#27313) 2021-05-06 14:05:14 -04:00
Michael Terry
35f78a3241 feat!: remove all email_marketing djangoapp code
This djangoapp was designed for talking to sailthru, in a fairly
edx.org-specific way. Nowadays, edx.org doesn't need this code and
if other installations do, it's better off as a more distinct
plugin anyway, rather than direct support in the platform.

I've moved the one signal that was still useful (calling
segment.identify() whenever user fields change) into user_authn.

And I've left the EmailMarketingConfiguration model alone for now,
but will remove that shortly. Nothing uses it as of this commit.

AA-607
DEPR-139
2021-05-03 16:39:01 -04:00
Jawayria
dbcd8066e5 Merge pull request #26626 from edx/jawayria/bom-2416
BOM-2416: Removed unused imports from docs, scripts, pavelib
2021-04-09 19:31:20 +05:00
Jawayria
96e1bffc97 Refactor: Removed unused imports
Removed unused imports from docs, scripts, pavelib
2021-04-09 16:03:53 +05:00
Piotr Surowiec
bc1e9afe4b feat: allow overriding unit icons (#21433)
This:
1. Introduces a new override using the `pluggable_override` decorator.
It is now possible to specify a custom way of getting XBlock's icon
by defining `GET_UNIT_ICON_IMPL` in settings.
2. Introduces a way to add custom `XBLOCK_MIXINS` by defining
`XBLOCK_EXTRA_MIXINS` in settings. This allows, e.g. to add
new fields to XBlocks.
2021-04-07 09:42:12 -04:00
Kyle McCormick
37650c1009 build: fix+simplify docs config now that sys.paths hacks are gone
The docs configuration files previously had to account
for the fact that lms/djangoapps, cms/djangoapps, and
common/djangoapps were hacked into sys.path. As of ~Lilac,
this is no longer the case.

Unrelated cleanup: devstack_docker and devstack
are now aliases, so we can simplify a conditional import
in docs_settings.py
2021-03-08 12:49:31 -05:00
Kyle McCormick
dfa60a5e92 docs: update sys.path hacks ADR & add upgrade guide
The timeline of the import_shims removal has evolved
over time; notably, we are keeping the import_shims
in Lilac in order to make any lingering old-style
import paths obvious to operators.

Update the ADR to reflect this. Also, add a table
mapping old import paths to new ones.
2021-03-08 12:49:31 -05:00
M. Zulqarnain
e35d3de376 refactor: pyupgrade on docs & pavelib (#26768) 2021-03-05 15:24:59 +05:00
Feanil Patel
8925756f11 doc: Add some docs for how rate-limiting works. (#26475)
* doc: Add a decision around rate-limiting in edx-platform

While looking into whether a change to how we handle RateLimitExceptions
would impact logins, I learned the following about the current state of
how rate limiting works in our login flows.  Based on what I learned, I captured
the current state as well as decisions on how we should rate limit in the future.
2021-02-17 13:16:57 -05:00
Jawayria
69e0dc7d68 Applied pylint-amnesty to {docs, import_shims, pavelib} 2021-02-02 21:17:16 +05:00
David Ormsbee
5353324c80 Merge pull request #26145 from edx/ormsbee/course-outline-publish-tnl-7733
Push Course Outlines to learning_sequences on publish.
2021-01-28 10:21:11 -05:00
David Ormsbee
d531d38ec7 Fix formatting on interapp APIs extension ADR.
The numbered lists were not written correctly.
2021-01-28 09:56:38 -05:00
Feanil Patel
c5913a58d5 Add an ADR about secret key usage. (#26146)
Add an ADR about secret key usage.

Don't use secret keys for use cases which would result in breakage upon
rotation and which might slow down the act of rotation.
2021-01-25 13:35:49 -05:00
Jayram
5a9e12dd96 [ADD] user account registration endpoint for api-docs
Added alias for /user_api endpoints

FIX quality violations

IMPROVED urls_common for readability

Removed redundant URL entry from urls_common file
2021-01-15 03:59:16 +00:00
Nizar
1e872d4e10 Adds support for enabling custom tinymce plugins in Studio's HTML editor (#25695) 2021-01-11 11:28:20 -05:00
Awais Qureshi
1f616f6fcd Fixing make docs
Adding constraint on sphinx.
2021-01-05 22:42:01 +05:00
Muhammad Soban Javed
dd534a90e5 Added celery task documentation (#25926)
* Added celery task documentation
2021-01-05 14:32:52 +05:00
Robert Raposa
fd584b70b6 Merge pull request #25681 from edx/robrap/capitalize-technical-reference-2
capitalize technical reference title
2020-12-01 12:22:57 -05:00
Manjinder Singh
d99070f68d docs: Clarifying pytest testing guide (#25668) 2020-12-01 09:48:30 -05:00
Diana Huang
1049c8c502 Clarify how to debug javascript tests in testing.rst. 2020-11-30 11:38:17 -05:00
Robert Raposa
10ce4af1ea capitalize technical reference title
Capitalize the title of the "edx-platform Technical Reference" documentation.
2020-11-24 16:59:52 -05: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
Robert Raposa
64a162f69c Merge pull request #25494 from regisb/regisb/fix-swaggerdocs
[BD-21] Fix API docs generation and update swagger.yml
2020-11-03 11:40:29 -05:00
sarina
f414fad0cc Change gendered language to gender-neutral 'they/them/their' 2020-11-02 18:23:13 -05:00
Régis Behmo
3599198f19 Fix API docs generation and update swagger.yml
API docs generation was being blocked by missing values in the doc
settings. We wanted to update the swagger.yml to get the toggle state
("/toggles/v0/state/") endpoint in the docs.
2020-11-02 09:27:48 +01:00
Kyle McCormick
090e10683c Rename sys_path_hacks/ to import_shims/
The old folder name is somewhat confusing, because the
folder contains shims to _compensate for the removal
of sys.path hacks_, but does not contain the sys.path
hacks themselves.

Furthermore, this import_shims/ system could also be
used for other import path changes, such as turning
the locally-installed packages in common/lib/
into regular, importable modules
(e.g. `from common.lib.xmodule import abc` instead of
`from xmodule import abc`). So, a name that is not
specific to the sys.path hacks may be better
in the medium-to-long term.

Along the same lines, we also rename SysPathHackWarning
to DeprecatedEdxPlatformImportWarning.
2020-10-30 10:20:48 -04:00
Kyle McCormick
4847a18a66 Remove sys.path modification for Studio; use sys_path_hacks instead
Also, tweak the un_sys_path.sh script.
2020-10-19 09:34:31 -04:00