Comments (1)
Not sure what to tell you. The django example in the examples/
directory is working just fine.
Modified tasks.py to add the following:
# django_ex/test_app/tasks.py
@task()
def huey_task():
print('this is a huey task')
Then in one terminal I ran:
# ./manage.py shell
from django_ex.test_app.tasks import *
huey_task()
And observed the output:
# Terminal 1
./manage.py run_huey
# Output
08:05:52 Huey consumer started with 4 thread, PID 4879 at 2023-08-16 13:05:52.908917
08:05:52 Scheduler runs every 1 second(s).
08:05:52 Periodic tasks are enabled.
08:05:52 The following commands are available:
+ djangoex.test_app.tasks.add
+ djangoex.test_app.tasks.mul
+ djangoex.test_app.tasks.slow
+ djangoex.test_app.tasks.flaky_task
+ djangoex.test_app.tasks.every_other_minute
+ djangoex.test_app.tasks.every_five_mins
+ djangoex.test_app.tasks.after_commit
+ djangoex.test_app.tasks.huey_task
08:06:34 Executing djangoex.test_app.tasks.huey_task: 735b745b-2bfa-4a33-bc4e-ecdce3ff9382
this is a huey task
08:06:34 djangoex.test_app.tasks.huey_task: 735b745b-2bfa-4a33-bc4e-ecdce3ff9382 executed in 0.000s
from huey.
Related Issues (20)
- Add more verbosity to task lock exception? HOT 2
- Possibility of switching to 'spawn' instead of 'fork'? HOT 1
- NoneType error when starting consumer with greenlet HOT 1
- Externally create scheduled tasks HOT 3
- Better documentation for dynamic periodic tasks HOT 1
- Lock Task ambiguous HOT 1
- django.db.utils.OperationalError: server closed the connection unexpectedly HOT 1
- Task not found in TaskRegistry HOT 5
- Docker healthcheck HOT 2
- RetryTask() takes no keyword arguments HOT 2
- Avoid running read_schedule when self.periodic is False HOT 1
- Feature Request - Django model method task decorator HOT 1
- poetry run open file instead of running huey consumer HOT 1
- Store metadata in the task HOT 1
- TypeError: __init__() got an unexpected keyword argument 'ssl' HOT 5
- `result` and `revoke_by_id` differ in their auto-conversion of task_id to str HOT 3
- Question: get last execution by task name HOT 1
- Relation between origin task call and retry call?!? HOT 1
- TaskLockedException('unable to set lock: ...') HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from huey.