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
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ jobs:
matrix:
os: [ubuntu-latest]
python-version:
- '3.11'
toxenv: [celery54-django42, celery54-django52]
- '3.12'
toxenv: [celery54-django52]

steps:
- uses: actions/checkout@v6
Expand Down
2 changes: 1 addition & 1 deletion eventtracking/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
"""A simple event tracking library"""

__version__ = '3.3.0'
__version__ = '4.0.0'
25 changes: 12 additions & 13 deletions eventtracking/backends/tests/test_event_bus.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,19 +43,18 @@ def test_successful_send_event(self, mock_send_event):
backend.send(self.sample_event)

mock_send_event.assert_called()
self.assertDictContainsSubset(
{
"tracking_log": TrackingLogData(
name=self.sample_event["name"],
timestamp=datetime.strptime(
self.sample_event["timestamp"], "%Y-%m-%dT%H:%M:%S.%f%z"
),
data=json.dumps(self.sample_event["data"]),
context=json.dumps(self.sample_event["context"]),
)
},
mock_send_event.call_args.kwargs,
)
expected = {
"tracking_log": TrackingLogData(
name=self.sample_event["name"],
timestamp=datetime.strptime(
self.sample_event["timestamp"], "%Y-%m-%dT%H:%M:%S.%f%z"
),
data=json.dumps(self.sample_event["data"]),
context=json.dumps(self.sample_event["context"]),
)
}
actual = mock_send_event.call_args.kwargs
self.assertEqual(expected, {k: actual[k] for k in expected})

@patch(
"eventtracking.backends.event_bus.SEND_TRACKING_EVENT_EMITTED_SIGNAL.is_enabled"
Expand Down
6 changes: 3 additions & 3 deletions requirements/base.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# This file is autogenerated by pip-compile with Python 3.11
# This file is autogenerated by pip-compile with Python 3.12
# by the following command:
#
# make upgrade
Expand All @@ -8,7 +8,7 @@ amqp==5.3.1
# via kombu
asgiref==3.11.1
# via django
attrs==25.4.0
attrs==26.1.0
# via openedx-events
billiard==4.2.4
# via celery
Expand All @@ -32,7 +32,7 @@ click-plugins==1.1.1.2
# via celery
click-repl==0.3.0
# via celery
code-annotations==2.3.2
code-annotations==3.0.0
# via edx-toggles
django==5.2.12
# via
Expand Down
10 changes: 5 additions & 5 deletions requirements/ci.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# This file is autogenerated by pip-compile with Python 3.11
# This file is autogenerated by pip-compile with Python 3.12
# by the following command:
#
# make upgrade
Expand All @@ -8,11 +8,11 @@ cachetools==7.0.5
# via tox
colorama==0.4.6
# via tox
coverage==7.13.4
coverage==7.13.5
# via -r requirements/ci.in
distlib==0.4.0
# via virtualenv
filelock==3.25.1
filelock==3.25.2
# via
# python-discovery
# tox
Expand All @@ -30,11 +30,11 @@ pluggy==1.6.0
# via tox
pyproject-api==1.10.0
# via tox
python-discovery==1.1.2
python-discovery==1.2.0
# via virtualenv
tomli-w==1.2.0
# via tox
tox==4.49.1
tox==4.50.3
# via -r requirements/ci.in
virtualenv==21.2.0
# via tox
22 changes: 11 additions & 11 deletions requirements/dev.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# This file is autogenerated by pip-compile with Python 3.11
# This file is autogenerated by pip-compile with Python 3.12
# by the following command:
#
# make upgrade
Expand All @@ -19,7 +19,7 @@ astroid==4.0.4
# -r requirements/test.txt
# pylint
# pylint-celery
attrs==25.4.0
attrs==26.1.0
# via
# -r requirements/test.txt
# openedx-events
Expand Down Expand Up @@ -47,7 +47,7 @@ cffi==2.0.0
# via
# -r requirements/test.txt
# pynacl
charset-normalizer==3.4.5
charset-normalizer==3.4.6
# via requests
click==8.3.1
# via
Expand Down Expand Up @@ -78,7 +78,7 @@ click-repl==0.3.0
# via
# -r requirements/test.txt
# celery
code-annotations==2.3.2
code-annotations==3.0.0
# via
# -r requirements/test.txt
# edx-lint
Expand All @@ -87,7 +87,7 @@ colorama==0.4.6
# via
# -r requirements/ci.txt
# tox
coverage[toml]==7.13.4
coverage[toml]==7.13.5
# via
# -r requirements/ci.txt
# -r requirements/test.txt
Expand Down Expand Up @@ -136,7 +136,7 @@ edx-django-utils==8.0.1
# -r requirements/test.txt
# edx-toggles
# openedx-events
edx-lint==5.6.0
edx-lint==6.0.0
# via
# -r requirements/dev.in
# -r requirements/test.txt
Expand All @@ -151,7 +151,7 @@ fastavro==1.12.1
# via
# -r requirements/test.txt
# openedx-events
filelock==3.25.1
filelock==3.25.2
# via
# -r requirements/ci.txt
# python-discovery
Expand Down Expand Up @@ -283,13 +283,13 @@ pytest==9.0.2
# via
# -r requirements/test.txt
# pytest-cov
pytest-cov==7.0.0
pytest-cov==7.1.0
# via -r requirements/test.txt
python-dateutil==2.9.0.post0
# via
# -r requirements/test.txt
# celery
python-discovery==1.1.2
python-discovery==1.2.0
# via
# -r requirements/ci.txt
# virtualenv
Expand All @@ -315,7 +315,7 @@ six==1.17.0
# python-dateutil
snowballstemmer==3.0.1
# via sphinx
sphinx==9.0.4
sphinx==9.1.0
# via -r requirements/dev.in
sphinxcontrib-applehelp==2.0.0
# via sphinx
Expand Down Expand Up @@ -351,7 +351,7 @@ tomlkit==0.14.0
# via
# -r requirements/test.txt
# pylint
tox==4.49.1
tox==4.50.3
# via
# -r requirements/ci.txt
# -r requirements/dev.in
Expand Down
2 changes: 1 addition & 1 deletion requirements/pip-tools.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# This file is autogenerated by pip-compile with Python 3.11
# This file is autogenerated by pip-compile with Python 3.12
# by the following command:
#
# make upgrade
Expand Down
12 changes: 6 additions & 6 deletions requirements/test.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# This file is autogenerated by pip-compile with Python 3.11
# This file is autogenerated by pip-compile with Python 3.12
# by the following command:
#
# make upgrade
Expand All @@ -15,7 +15,7 @@ astroid==4.0.4
# via
# pylint
# pylint-celery
attrs==25.4.0
attrs==26.1.0
# via
# -r requirements/base.txt
# openedx-events
Expand Down Expand Up @@ -51,12 +51,12 @@ click-plugins==1.1.1.2
# via
# -r requirements/base.txt
# celery
code-annotations==2.3.2
code-annotations==3.0.0
# via
# -r requirements/base.txt
# edx-lint
# edx-toggles
coverage[toml]==7.13.4
coverage[toml]==7.13.5
# via pytest-cov
ddt==1.7.2
# via -r requirements/test.in
Expand Down Expand Up @@ -93,7 +93,7 @@ edx-django-utils==8.0.1
# -r requirements/base.txt
# edx-toggles
# openedx-events
edx-lint==5.6.0
edx-lint==6.0.0
# via -r requirements/test.in
edx-opaque-keys[django]==3.1.0
# via
Expand Down Expand Up @@ -177,7 +177,7 @@ pynacl==1.6.2
# edx-django-utils
pytest==9.0.2
# via pytest-cov
pytest-cov==7.0.0
pytest-cov==7.1.0
# via -r requirements/test.in
python-dateutil==2.9.0.post0
# via
Expand Down
2 changes: 0 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,13 +142,11 @@ def get_version(*file_paths):
'Development Status :: 2 - Pre-Alpha',
'Environment :: Web Environment',
'Framework :: Django',
'Framework :: Django :: 4.2',
'Framework :: Django :: 5.2',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
Expand Down
3 changes: 1 addition & 2 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
[tox]
envlist = py{311, 312}-celery{54}-django{42,52}
envlist = py{312}-celery{54}-django{52}

[testenv]
setenv =
DJANGO_SETTINGS_MODULE = eventtracking.django.tests.settings
PYTHONPATH = {toxinidir}
deps =
celery54: -r{toxinidir}/requirements/celery54.txt
django42: Django>=4.2,<4.3
django52: Django>=5.2,<5.3
-r{toxinidir}/requirements/test.txt
commands =
Expand Down