Skip to content

Commit

Permalink
feat: add rapid response xblock
Browse files Browse the repository at this point in the history
  • Loading branch information
Anas12091101 committed Mar 13, 2024
1 parent 6efd1b3 commit 1adceb0
Show file tree
Hide file tree
Showing 56 changed files with 3,374 additions and 0 deletions.
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ edx-opaque-keys = "^2.5.1"
gitpython = "^3.1.37"
python-json-logger = "^2.0.2"
sentry-sdk = "^1.3.1"
XBlock = "^1.10.0"
opentelemetry-distro = "*"
opentelemetry-instrumentation-django = "*"
opentelemetry-exporter-richconsole = "*"
Expand Down
Binary file added src/rapid_response_xblock/.coverage
Binary file not shown.
46 changes: 46 additions & 0 deletions src/rapid_response_xblock/BUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
python_sources(
name="rapid_response_xblock",
dependencies=[
"src/rapid_response_xblock/migrations:rapidresponse_migrations",
"src/rapid_response_xblock/settings:rapidresponse_settings",
"//:external_dependencies#edx-opaque-keys",
"//:external_dependencies#XBlock",
"//:external_dependencies#Django",

],
)

python_distribution(
name="rapid_response_xblock_package",
dependencies=[
":rapid_response_xblock",
"src/rapid_response_xblock/static/js:rapidresponse_js",
"src/rapid_response_xblock/static/css:rapidresponse_css",
"src/rapid_response_xblock/static/html:rapidresponse_html",
],
provides=setup_py(
name="rapid-response-xblock",
version="0.9.1",
description="An xblock aside for problem xblocks",
license="BSD-3-Clause",
author="MIT Office of Digital Learning",
include_package_data=True,
zip_safe=False,
keywords="Python edx",
entry_points={
'xblock_asides.v1': [
'rapid_response_xblock = rapid_response_xblock.block:RapidResponseAside',
],
"lms.djangoapp": [
"rapid_response_xblock = rapid_response_xblock.apps:RapidResponseAppConfig"
],
"cms.djangoapp": [
"rapid_response_xblock = rapid_response_xblock.apps:RapidResponseAppConfig"
],
},
),
)

python_tests(
name="tests",
)
5 changes: 5 additions & 0 deletions src/rapid_response_xblock/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# lint-amnesty, pylint: disable=django-not-configured
"""rapid_response_xblock Django app"""
__version__ = "0.9.1"

default_app_config = "rapid_response_xblock.apps.RapidResponseAppConfig"
33 changes: 33 additions & 0 deletions src/rapid_response_xblock/apps.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
"""AppConfig for rapid response"""
from django.apps import AppConfig
from openedx.core.djangoapps.plugins.constants import ProjectType, SettingsType
from edx_django_utils.plugins import PluginSettings, PluginURLs


class RapidResponseAppConfig(AppConfig):
"""
AppConfig for rapid response
"""
name = "rapid_response_xblock"

plugin_app = {
PluginSettings.CONFIG: {
ProjectType.LMS: {
SettingsType.COMMON: {
PluginSettings.RELATIVE_PATH: 'settings.settings'
},
},
ProjectType.CMS: {
SettingsType.COMMON: {
PluginSettings.RELATIVE_PATH: 'settings.cms_settings'
},
}
},
PluginURLs.CONFIG: {
ProjectType.CMS: {
PluginURLs.NAMESPACE: "",
PluginURLs.REGEX: "^toggle-rapid-response/",
PluginURLs.RELATIVE_PATH: "urls",
}
},
}
Loading

0 comments on commit 1adceb0

Please sign in to comment.