AttributeError: 'Consumer' object has no attribute 'database'
The Consumer class holds an instance variable db
, but at least the query method for type rows
requires that it has an instance variable called database
. It leads to e.g.,
...
out = consumer.query('condor_failures', 'rows', start, end)
File "/usr/lib/python3.6/site-packages/ligo/scald/io/influx.py", line 656, in query
return self.retrieve_rows_by_tag(s['measurement'], start, end, s['tag_key'], aggregate=s['aggregate'], **kwargs)
File "/usr/lib/python3.6/site-packages/ligo/scald/io/influx.py", line 704, in retrieve_rows_by_tag
return _retrieve_rows_by_tag(self.client, self.database, measurement, self.schema[measurement], start, end, tag, aggregate=aggregate, dt=dt, datetime=datetime)
AttributeError: 'Consumer' object has no attribute 'database'