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

[6.4.0] Error importing pubnub.pubnub_asyncio #130

Closed
balloob opened this issue Jul 13, 2022 · 1 comment
Closed

[6.4.0] Error importing pubnub.pubnub_asyncio #130

balloob opened this issue Jul 13, 2022 · 1 comment

Comments

@balloob
Copy link

balloob commented Jul 13, 2022

    from pubnub.pubnub_asyncio import PubNubAsyncio
venv/lib/python3.9/site-packages/pubnub/pubnub_asyncio.py:16: in <module>
    from .pubnub_core import PubNubCore
venv/lib/python3.9/site-packages/pubnub/pubnub_core.py:3: in <module>
    from pubnub.endpoints.entities.membership.add_memberships import AddSpaceMembers, AddUserSpaces
E   ModuleNotFoundError: No module named 'pubnub.endpoints.entities'

Started happening after 6.4.0 release. Both Python 3.9 and 3.10.

I wonder if it's because of the lack of __init__.py files in the directories?

Reproduce:

$ pip3 install pubnub==6.4.0
$ python3 -c "import pubnub.pubnub_asyncio"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/Users/paulus/dev/hass/core/venv/lib/python3.9/site-packages/pubnub/pubnub_asyncio.py", line 16, in <module>
    from .pubnub_core import PubNubCore
  File "/Users/paulus/dev/hass/core/venv/lib/python3.9/site-packages/pubnub/pubnub_core.py", line 3, in <module>
    from pubnub.endpoints.entities.membership.add_memberships import AddSpaceMembers, AddUserSpaces
ModuleNotFoundError: No module named 'pubnub.endpoints.entities'

This works and prints no error:

$ pip3 install pubnub==6.3.0
$ python3 -c "import pubnub.pubnub_asyncio"
@seba-aln
Copy link
Contributor

The fix is merged. I've created a ticket to harden our tests for the future.

Thank you for reporting the issue

@balloob balloob closed this as completed Jul 15, 2022
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