You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 20, 2018. It is now read-only.
I tried using a mixin with some common fields, but it doesn't work:
class CeleryTaskMixin:
celery_status = models.CharField() # last known status, call update_status
celery_id = models.CharField() # celery uuid
f_name = models.CharField(indexed=True)
class RunningTask(CeleryTaskMixin, models.Model):
def __init__(self, t=None, *args, **kwargs):
CeleryTaskMixin.__init__(self)
models.Model.__init__(self)
task_type = models.CharField()
start_time = models.DateTimeField(auto_now=True)
end_time = models.DateTimeField()
Then when I try and do
models.RunningTask.objects.filter(f_name="blah")
It says
File "/home/stu/.virtualenvs/ng/src/redisco/redisco/models/modelset.py", line 52, in __iter__
for id in self._set:
File "/home/stu/.virtualenvs/ng/src/redisco/redisco/models/modelset.py", line 294, in _set
s = self._add_set_filter(s)
File "/home/stu/.virtualenvs/ng/src/redisco/redisco/models/modelset.py", line 317, in _add_set_filter
(k, self.model_class.__name__))
redisco.models.exceptions.AttributeNotIndexed: Attribute f_name is not indexed in RunningTask class.
This seems like something that should work... (?)
The text was updated successfully, but these errors were encountered:
I tried using a mixin with some common fields, but it doesn't work:
Then when I try and do
It says
This seems like something that should work... (?)
The text was updated successfully, but these errors were encountered: