Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
77 changes: 38 additions & 39 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ on:
branches: [main]
pull_request:
branches:
- '**'

- "**"

jobs:
run_tests:
Expand All @@ -15,8 +14,8 @@ jobs:
strategy:
matrix:
os: [ubuntu-24.04]
python-version: ['3.12']
toxenv: [quality, docs, pii_check, django42, django52]
python-version: ["3.12"]
toxenv: [quality, docs, pii_check, django52]
permissions:
# Gives the action the necessary permissions for publishing new
# comments in pull requests.
Expand All @@ -27,38 +26,38 @@ jobs:
contents: write

steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: setup python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: ${{ matrix.python-version }}

- name: Install pip
run: pip install -r requirements/pip.txt

- name: Install Dependencies
run: pip install -r requirements/ci.txt

- name: Run Tests
env:
TOXENV: ${{ matrix.toxenv }}
run: tox

- name: Run coverage
if: matrix.python-version == '3.12' && matrix.toxenv == 'django42'
uses: py-cov-action/python-coverage-comment-action@5d8df5979747514c914e1c5a12335a7cf9a2745f # v3
with:
GITHUB_TOKEN: ${{ github.token }}
MINIMUM_GREEN: 90
MINIMUM_ORANGE: 85
ANNOTATE_MISSING_LINES: true
ANNOTATION_TYPE: error

- name: Store Pull Request comment to be posted
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
if: steps.coverage_comment.outputs.COMMENT_FILE_WRITTEN == 'true'
with:
# If you use a different name, update COMMENT_ARTIFACT_NAME accordingly
name: python-coverage-comment-action
# If you use a different name, update COMMENT_FILENAME accordingly
path: python-coverage-comment-action.txt
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: setup python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: ${{ matrix.python-version }}

- name: Install pip
run: pip install -r requirements/pip.txt

- name: Install Dependencies
run: pip install -r requirements/ci.txt

- name: Run Tests
env:
TOXENV: ${{ matrix.toxenv }}
run: tox

- name: Run coverage
if: matrix.python-version == '3.12' && matrix.toxenv == 'django42'
uses: py-cov-action/python-coverage-comment-action@5d8df5979747514c914e1c5a12335a7cf9a2745f # v3
with:
GITHUB_TOKEN: ${{ github.token }}
MINIMUM_GREEN: 90
MINIMUM_ORANGE: 85
ANNOTATE_MISSING_LINES: true
ANNOTATION_TYPE: error

- name: Store Pull Request comment to be posted
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
if: steps.coverage_comment.outputs.COMMENT_FILE_WRITTEN == 'true'
with:
# If you use a different name, update COMMENT_ARTIFACT_NAME accordingly
name: python-coverage-comment-action
# If you use a different name, update COMMENT_FILENAME accordingly
path: python-coverage-comment-action.txt
9 changes: 5 additions & 4 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -213,10 +213,11 @@ Event Sink Configuration
- ``module`` - The module path of the model.
- ``model`` - The model class name.

Event Sinks are disabled by default. To enable them, you need to enable the following
waffle flag: ``event_sink_clickhouse.{{model_name}}.enabled``, where model_name is the name
of the model that you want to enable. Or, you can enable them via settings by setting
``EVENT_SINK_CLICKHOUSE_{{model_name}}_ENABLED`` to ``True``.
Event Sinks are disabled by default from this repository, but enabled in the Aspects Tutor
plugin (tutor-contrib-aspects). If not using the Tutor plugin you will need to enable the
following waffle flags: ``event_sink_clickhouse.{{model_name}}.enabled``, where model_name
is the name of the model that you want to enable. Or, you can enable them via settings by
setting ``EVENT_SINK_CLICKHOUSE_{{model_name}}_ENABLED`` to ``True``.


Getting Help
Expand Down
2 changes: 1 addition & 1 deletion platform_plugin_aspects/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
import os
from pathlib import Path

__version__ = "1.3.0"
__version__ = "2.0.0"

ROOT_DIRECTORY = Path(os.path.dirname(os.path.abspath(__file__)))
6 changes: 3 additions & 3 deletions platform_plugin_aspects/settings/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,13 +94,13 @@ def plugin_settings(settings):
"module": "openedx.core.djangoapps.user_api.models",
"model": "UserPreference",
},
"tag": {"module": "openedx_tagging.core.tagging.models", "model": "Tag"},
"tag": {"module": "openedx_tagging.models.base", "model": "Tag"},
"taxonomy": {
"module": "openedx_tagging.core.tagging.models",
"module": "openedx_tagging.models.base",
"model": "Taxonomy",
},
"object_tag": {
"module": "openedx_tagging.core.tagging.models",
"module": "openedx_tagging.models.base",
"model": "ObjectTag",
},
}
Expand Down
3 changes: 1 addition & 2 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = py312-django{42,52}
envlist = py312-django{52}

[doc8]
; D001 = Line too long
Expand Down Expand Up @@ -38,7 +38,6 @@ norecursedirs = .* docs requirements site-packages
setenv:
DJANGO_SETTINGS_MODULE = test_settings
deps =
django42: Django>=4.2,<4.3
django52: Django>=5.2,<5.3
-r{toxinidir}/requirements/test.txt
commands =
Expand Down