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

creating my first repo have a problem #231

Closed
arilishu opened this issue Sep 25, 2024 · 5 comments · Fixed by #239
Closed

creating my first repo have a problem #231

arilishu opened this issue Sep 25, 2024 · 5 comments · Fixed by #239

Comments

@arilishu
Copy link

i am trying to install dbos on my mac, I am following this steps:
https://docs.dbos.dev/quickstart
Everything works great until I hit this command:

dbos init

I get this error:

Traceback (most recent call last):
  File "/Users/ariellipschutz/Projects/prominent/dbos/my-app/.venv/bin/dbos", line 5, in <module>
    from dbos.cli import app
  File "/Users/ariellipschutz/Projects/prominent/dbos/my-app/.venv/lib/python3.12/site-packages/dbos/__init__.py", line 3, in <module>
    from .dbos import DBOS, DBOSConfiguredInstance, WorkflowHandle, WorkflowStatus
  File "/Users/ariellipschutz/Projects/prominent/dbos/my-app/.venv/lib/python3.12/site-packages/dbos/dbos.py", line 27, in <module>
    from dbos.core import (
  File "/Users/ariellipschutz/Projects/prominent/dbos/my-app/.venv/lib/python3.12/site-packages/dbos/core.py", line 61, in <module>
    from dbos.system_database import (
  File "/Users/ariellipschutz/Projects/prominent/dbos/my-app/.venv/lib/python3.12/site-packages/dbos/system_database.py", line 8, in <module>
    import psycopg
  File "/Users/ariellipschutz/Projects/prominent/dbos/my-app/.venv/lib/python3.12/site-packages/psycopg/__init__.py", line 9, in <module>
    from . import pq  # noqa: F401 import early to stabilize side effects
    ^^^^^^^^^^^^^^^^
  File "/Users/ariellipschutz/Projects/prominent/dbos/my-app/.venv/lib/python3.12/site-packages/psycopg/pq/__init__.py", line 117, in <module>
    import_from_libpq()
  File "/Users/ariellipschutz/Projects/prominent/dbos/my-app/.venv/lib/python3.12/site-packages/psycopg/pq/__init__.py", line 109, in import_from_libpq
    raise ImportError(
ImportError: no pq wrapper available.
Attempts made:
- couldn't import psycopg 'c' implementation: No module named 'psycopg_c'
- couldn't import psycopg 'binary' implementation: No module named 'psycopg_binary'
- couldn't import psycopg 'python' implementation: libpq library not found

Any idea what is wrong?

Thanks!

@boltomli
Copy link

boltomli commented Sep 27, 2024

Try pip install "psycopg[binary]" in your virtual env.

@apoliakov
Copy link
Member

Hi there @arilishu sorry about the trouble!

Is there anything special about your environment? What OS are you using?

@arilishu
Copy link
Author

arilishu commented Sep 27, 2024 via email

@apoliakov
Copy link
Member

@arilishu thanks.
Looks like you're missing some Postgres drivers. It's not clear why. have you tried what @boltomli suggested above?

@qianl15
Copy link
Member

qianl15 commented Sep 27, 2024

Hello! Here are two potential steps you can try:

  1. Looks like your machine doesn't have the libpq library. Try to install it through brew install libpq.
  2. Try to install the binary version as @boltomli suggested above. However, the binary version might not be available on certain macOS versions and m1/m2 silicons.

Thank you for reporting this issue! We'll improve the quickstart installation guide.

@qianl15 qianl15 linked a pull request Oct 7, 2024 that will close this issue
qianl15 added a commit that referenced this issue Oct 7, 2024
- Update the AI quickstart
- Add instructions for installing libpq. Solve
#231
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

Successfully merging a pull request may close this issue.

4 participants