Commit Graph

11 Commits

Author SHA1 Message Date
Terence Honles 58bfccf66d
test type annotations with mypy (#2123)
* test type annotations with mypy

* update timing test
2024-09-14 05:38:58 +07:00
Selwin Ong 4c28ec617a
Delete legacy.py (#2083)
* Delete legacy.py

* Deleted Sentry's built in integration.

* Fixed ruff warnings.
2024-05-02 08:20:41 +07:00
Selwin Ong 00adbc08c6 Use sentry-sdk<2 for tests 2024-04-28 20:50:26 +07:00
Selwin Ong 089ecc17c1 Bump version to 1.16.1 2024-03-09 09:38:09 +07:00
Selwin Ong 3ad86083c3 Merge tag 'v1.16' 2024-02-25 08:10:01 +07:00
Selwin Ong 6ce1cc63b9 Bump version to 1.16.0 2024-02-24 10:10:21 +07:00
Rob Hudson 0935f47213 Store project metadata in pyproject.toml (PEP 621) (#1952) 2024-02-24 10:07:56 +07:00
Selwin Ong 3c89f9dada
Job with multiple executions (#1964)
* Initial work on Execution class

* Executions are now created and deleted when jobs are performed

* Added execution.heartbeat()

* Added a way to get execution IDs from execution registry

* Job.fetch should also support execution composite key

* Added ExecutionRegistry.get_executions()

* execution.heartbeat() now also updates StartedJobRegistry

* Added job.get_executions()

* Added worker.prepare_execution()

* Simplified start_worker function in fixtures.py

* Minor test fixes

* Black

* Fixed a failing shutdown test

* Removed Execution.create from worker.prepare_job_execution

* Fix Sentry test

* Minor fixes

* Better test coverage

* Readded back worker.set_current_job_working_time()

* Reverse the order of handle_exception and handle_job_failure

* Fix SSL test

* job.delete() also deletes executions.

* Set job._status to FAILED as soon as job raises an exception

* Exclusively use execution.composite_key in StartedJobRegistry

* Use codecov v3

* Format with black

* Remove print statement

* Remove Redis server 3 from tests

* Remove support for Redis server < 4

* Fixed ruff warnings

* Added tests and remove unused code

* Linting fixes
2023-11-03 17:05:59 +07:00
Rob Hudson 9933128dd2
Store project metadata in pyproject.toml (PEP 621) (#1952) 2023-07-09 17:34:25 +07:00
Rob Hudson ea063edf0a
Update linting configuration (#1915)
* Update linting configuration

This removes flake8 in favor of ruff, which also provides isort support, and
updates all files to be black, isort, and ruff compliant. This also adds black
and ruff checks to the tox and Github linting workflow.

* Tweak the code coverage config and calls
2023-05-17 23:19:14 +07:00
Selwin Ong 46b5cf64c3
Added black config (#1815) 2023-02-14 07:47:52 +07:00