Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when getting Eventhub from app client #35

Open
zabzal opened this issue Apr 27, 2018 · 1 comment
Open

Error when getting Eventhub from app client #35

zabzal opened this issue Apr 27, 2018 · 1 comment

Comments

@zabzal
Copy link

zabzal commented Apr 27, 2018

I am running the following in Jupyter notebook - Python 3.5. Based on the example here: https://predixpy.run.aws-usw02-pr.ice.predix.io/services/index.html#id13

import predix.app

app = predix.app.Manifest()
eh = app.get_eventhub()

Here is the Traceback I get:

WARNING:root:Writing manifest manifest.yml unencrypted.
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-2-0716f09abb5f> in <module>()
      2 
      3 app = predix.app.Manifest()
----> 4 eh = app.get_eventhub()

/usr/local/lib/python3.5/dist-packages/predix/app.py in get_eventhub(self, publish_config, subscribe_config)
    250 
    251     def get_eventhub(self, publish_config=None, subscribe_config=None):
--> 252         import predix.data.eventhub.client
    253         eventhub = predix.data.eventhub.client.Eventhub(subscribe_config=subscribe_config,
    254                                                         publish_config=publish_config)

/usr/local/lib/python3.5/dist-packages/predix/data/eventhub/client.py in <module>()
      9 import predix.config
     10 import predix.service
---> 11 from predix.data.eventhub import Health_pb2_grpc
     12 from predix.data.eventhub import Health_pb2
     13 from predix.data.eventhub.publisher import PublisherConfig, Publisher

/usr/local/lib/python3.5/dist-packages/predix/data/eventhub/Health_pb2_grpc.py in <module>()
      2 import grpc
      3 
----> 4 import Health_pb2 as Health__pb2
      5 
      6 

ImportError: No module named 'Health_pb2'

Seems like an import issue in the Health_pb2_grpc.py file. I confirmed that both these files exist in the module I downloaded.

@ThisWillGoWell
Copy link

I think this is another issue that was fixed in #33
Not sure on when those will get merged into here but you should be able to try my fork

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants