Skip to content

Commit 61d524c

Browse files
dongweimingsamuelcolvin
authored andcommitted
Compatible with Python 3.6 (#122)
1 parent 3145d08 commit 61d524c

File tree

4 files changed

+14
-10
lines changed

4 files changed

+14
-10
lines changed

.travis.yml

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,16 @@ cache: pip
55
services:
66
- redis-server
77

8-
matrix:
9-
include:
10-
- python: '3.7'
11-
dist: xenial
12-
sudo: required
13-
- python: 3.8-dev
14-
dist: xenial
15-
sudo: required
8+
dist: xenial
9+
10+
python:
11+
- '3.6'
12+
- '3.7'
13+
- '3.8-dev'
1614

15+
sudo: required
16+
17+
matrix:
1718
allow_failures:
1819
- python: 3.8-dev
1920

HISTORY.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ v0.16.0a5 (2019-04-22)
77
......................
88
* use ``pipeline`` in ``enqueue_job``
99
* catch any error when pickling job result
10+
* add support for python 3.6
1011

1112
v0.16.0a4 (2019-03-15)
1213
......................

arq/worker.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ async def run_jobs(self, job_ids):
277277
# job already started elsewhere since we got 'existing'
278278
self.sem.release()
279279
else:
280-
self.tasks.append(asyncio.create_task(self.run_job(job_id, score)))
280+
self.tasks.append(self.loop.create_task(self.run_job(job_id, score)))
281281

282282
async def run_job(self, job_id, score): # noqa: C901
283283
v, job_try, _ = await asyncio.gather(

setup.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
'Programming Language :: Python',
3131
'Programming Language :: Python :: 3',
3232
'Programming Language :: Python :: 3 :: Only',
33+
'Programming Language :: Python :: 3.6',
3334
'Programming Language :: Python :: 3.7',
3435
'Topic :: Internet',
3536
'Topic :: Software Development :: Libraries :: Python Modules',
@@ -38,7 +39,7 @@
3839
'Topic :: System :: Monitoring',
3940
'Topic :: System :: Systems Administration',
4041
],
41-
python_requires='>=3.7',
42+
python_requires='>=3.6',
4243
author='Samuel Colvin',
4344
author_email='[email protected]',
4445
url='https://github.com/samuelcolvin/arq',
@@ -54,6 +55,7 @@
5455
'aioredis>=1.1.0',
5556
'click>=6.7',
5657
'pydantic>=0.20',
58+
'dataclasses>=0.6;python_version == "3.6"'
5759
],
5860
extras_require={
5961
'watch': ['watchgod>=0.4'],

0 commit comments

Comments
 (0)