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

[BUG]: Broken import breaks package #263

Closed
kabooboo opened this issue Aug 30, 2024 · 1 comment · Fixed by #264 or #265
Closed

[BUG]: Broken import breaks package #263

kabooboo opened this issue Aug 30, 2024 · 1 comment · Fixed by #264 or #265
Labels
bug Something isn't working

Comments

@kabooboo
Copy link

As of 1.9.0, the whole package is broken on import, as client.py tries to import PaymentRequestClient from .payment_requests.clients, which isn't being recognized.

To Reproduce

Here is a one-liner to reproduce the error:

docker run -it --entrypoint bash python:latest -c "python3 -m pip install lago_python_client==1.9.0 && python3 -c 'import lago_python_client'"

This installs the client version 1.9.0 on a clean python install, and imports the package.

Output:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.12/site-packages/lago_python_client/__init__.py", line 1, in <module>
    from lago_python_client.client import Client
  File "/usr/local/lib/python3.12/site-packages/lago_python_client/client.py", line 17, in <module>
    from .payment_requests.clients import PaymentRequestClient
ModuleNotFoundError: No module named 'lago_python_client.payment_requests'

Expected behavior
It should not fail on import. For example on version 1.7.0, if you run:

docker run -it --entrypoint bash python:latest -c "python3 -m pip install lago_python_client==1.9.0 && python3 -c 'import lago_python_client'"

There is no error.

Support

  • OS: Tested on Ubuntu 22
@nudded
Copy link
Contributor

nudded commented Aug 30, 2024

@kabooboo We've released 1.9.1 which should fix this error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants