vintasoftware / django-celerybeat-status

A library that integrates with django admin and shows in a simple GUI when your periodic are going to run next.
https://pypi.org/project/django-celerybeat-status
MIT License
100 stars 11 forks source link

TypeError at /admin/statuscheck/periodic-tasks/ #13

Closed ismailsunni closed 6 years ago

ismailsunni commented 6 years ago

I followed the README, the link Periodic tasks status shown in the admin page, but when I access it, I got this error:


Request Method: | GET
-- | --
http://docker-inasafe-django:61102/admin/statuscheck/periodic-tasks/
1.8
TypeError
super() takes at least 1 argument (0 given)
/usr/local/lib/python2.7/site-packages/celerybeat_status/views.py in dispatch, line 17
/usr/local/bin/python
2.7.13
['/home/web/django_project',  '/usr/local/lib/python2.7/site-packages/_pdbpp_path_hack',  '/Users/ismailsunni/dev/python/inasafe-django',  '/home/web/django_project',  '/usr/local/lib/python27.zip',  '/usr/local/lib/python2.7',  '/usr/local/lib/python2.7/plat-linux2',  '/usr/local/lib/python2.7/lib-tk',  '/usr/local/lib/python2.7/lib-old',  '/usr/local/lib/python2.7/lib-dynload',  '/usr/local/lib/python2.7/site-packages',  '/home/web/django_project/.pycharm_helpers/pycharm_matplotlib_backend',  '/home/web/django_project',  '/home/web/django_project',  '/home/web/django_project']
Thu, 15 Feb 2018 03:03:53 +0000

Any idea how to fix this?

lucabezerra commented 6 years ago

@ismailsunni This error is usually associated with using an environment with Python 2.x when the lib uses Python 3.x syntax. By the paths shown in the error you've posted, it seems to be the case. Have you tried creating your virtualenv/project with Python 3 to see if it still happens?

ismailsunni commented 6 years ago

Ah I see... I haven't tried with Python 3, our work are still using python 2. I thought it also supports Python 2. Thanks. Just close this if you don't have plan to support Python 2.

lucabezerra commented 6 years ago

No problem, thanks for the interest in it :)

I believe @hugobessa can give a better answer on whether Python 2 support will be available or not, let's see what he has to say. Maybe we should at least add a "Python 3 only" badge somewhere, if Py2 won't be supported.

hugobessa commented 6 years ago

@ismailsunni the master branch already supports python2, but we didn't release yet. We plan to release this after #10 is merged (it's still being reviewed).

hugobessa commented 6 years ago

@ismailsunni I forgot to update you on this, but the fix was already released. Version 0.0.10

ismailsunni commented 6 years ago

Thanks, @hugobessa I will give it a try :) 👍