DEV Community

Discussion on: Implement real-time updates with Django REST Framework | Building Cryptocurrency API

 
christiangeng profile image
ChristianGeng

Thanks a lot, that was it!

not Cryptocurrency.objects

is always false, so crawl_currency() was never called.
I have set a celery breakpoint there for the first time, then called crawl_currency() at the breakpoint by hand, and now it works like a charm!

Thanks so much!

P.S.:
Would it make sense to test for an empty queryset instead? Sth. like this:

not Cryptocurrency.objects.all()
Thread Thread
 
thedevtimeline profile image
Rashid

Great! Ah, I see. Yeah I will fix that line. Thank you for your attention👍