Skip to content

Commit

Permalink
Support Python 3.10
Browse files Browse the repository at this point in the history
Fixes #17
  • Loading branch information
NicolasLM committed Jun 17, 2022
1 parent a647224 commit 2d44004
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.6, 3.7, 3.8, 3.9, pypy3]
python-version: ["3.6", "3.7", "3.8", "3.9", "3.10", "pypy3"]

services:
redis:
Expand Down Expand Up @@ -51,4 +51,4 @@ jobs:
- name: Coveralls Finished
uses: AndreMiras/coveralls-python-action@develop
with:
parallel-finished: true
parallel-finished: true
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
],
keywords='task queue jobs redis',

Expand Down
5 changes: 4 additions & 1 deletion spinach/brokers/memory.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,10 @@ def inspect_periodic_tasks(self) -> List[Tuple[int, str]]:
Used only for debugging and during tests.
"""
return [(int(e[0]), e[3][0].name) for e in self._scheduler.queue]
return [
(int(e.time), e.argument[0].name)
for e in self._scheduler.queue
]

def _get_next_future_job(self) -> Optional[Job]:
with self._lock:
Expand Down

0 comments on commit 2d44004

Please sign in to comment.