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]: github.py should not be named github, circular import issue #5168

Open
1 task done
diwu-sf opened this issue Nov 21, 2024 · 2 comments
Open
1 task done

[Bug]: github.py should not be named github, circular import issue #5168

diwu-sf opened this issue Nov 21, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@diwu-sf
Copy link
Contributor

diwu-sf commented Nov 21, 2024

Is there an existing issue for the same bug?

  • I have checked the existing issues.

Describe the bug and reproduction steps

Try running: python openhands/server/listen.py and you will get this error

ERROR:root:  File "/home/ubuntu/openhands/openhands/server/listen.py", line 23, in <module>
    from openhands.server.github import (
  File "/home/ubuntu/openhands/openhands/server/github.py", line 3, in <module>
    from github import Github
  File "/home/ubuntu/openhands/openhands/server/github.py", line 3, in <module>
    from github import Github

ERROR:root:<class 'ImportError'>: cannot import name 'Github' from partially initialized module 'github' (most likely due to a circular import) (/home/ubuntu/openhands/openhands/server/github.py)

I fixed this by renaming github.py to github_utils.py

OpenHands Installation

Docker command in README

OpenHands Version

No response

Operating System

None

Logs, Errors, Screenshots, and Additional Context

No response

@diwu-sf diwu-sf added the bug Something isn't working label Nov 21, 2024
SmartManoj added a commit to SmartManoj/Kevin that referenced this issue Nov 21, 2024
@mamoodi
Copy link
Collaborator

mamoodi commented Nov 21, 2024

Hi there! Are you able to open a PR with your change and get some 👀 on it please? If you ran into it, it's likely others will too..

@diwu-sf
Copy link
Contributor Author

diwu-sf commented Nov 21, 2024 via email

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
Development

No branches or pull requests

2 participants