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
When starting fedmsg-hub I get this in my console:
[ fedmsg INFO] * disabled by config - fmn.consumer.consumer:FMNConsumer
[moksha.hub ERROR] Failed to init <class 'fmn.consumer.consumer.FMNConsumer'> consumer.
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/moksha/hub/hub.py", line 407, in __init_consumers
c = c_class(self)
File "/usr/lib/python2.7/site-packages/fmn/consumer/consumer.py", line 65, in __init__
self.uri = self.hub.config.get('fmn.sqlalchemy.uri', None)
AttributeError: 'FMNConsumer' object has no attribute 'hub'
I found the reason: on line 105 of the consumers/__init__.py file a check is made to enable the instance or not. If not, the init method is aborted before calling the superclass' constructor method. But it's this superclass' constructor that sets self.hub to the hub provided as argument.
As a result, if the subclass tries to use self.hub later in its constructor, it will crash.
The text was updated successfully, but these errors were encountered:
When starting fedmsg-hub I get this in my console:
I found the reason: on line 105 of the
consumers/__init__.py
file a check is made to enable the instance or not. If not, the init method is aborted before calling the superclass' constructor method. But it's this superclass' constructor that setsself.hub
to thehub
provided as argument.As a result, if the subclass tries to use self.hub later in its constructor, it will crash.
The text was updated successfully, but these errors were encountered: