Skip to content

Support QDRANT_URL for Python Qdrant configuration#5381

Open
haojingcn wants to merge 1 commit into
mem0ai:mainfrom
haojingcn:fix/qdrant-url-self-hosted-http
Open

Support QDRANT_URL for Python Qdrant configuration#5381
haojingcn wants to merge 1 commit into
mem0ai:mainfrom
haojingcn:fix/qdrant-url-self-hosted-http

Conversation

@haojingcn
Copy link
Copy Markdown

Fixes #5378

This PR adds conservative QDRANT_URL / QDRANT_API_KEY environment fallback support for the Python Qdrant vector store configuration.

The fallback is only used when no explicit connection method is provided (client, url, host + port, or path), so existing users who configure host + port keep the same behavior.

Docs now recommend using url: "http://..." or QDRANT_URL for self-hosted HTTP Qdrant with API key authentication, because Python qdrant-client treats host + port + api_key as HTTPS by default.

Tests:

  • env MEM0_DIR=/private/tmp/mem0-oss-pr-test-home python3 -m pytest tests/configs/test_qdrant_config.py
  • python3 -m py_compile mem0/configs/vector_stores/qdrant.py mem0/vector_stores/qdrant.py

@CLAassistant
Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

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 this pull request may close these issues.

Qdrant vector store uses HTTPS unexpectedly with host/port/api_key for self-hosted HTTP Qdrant

2 participants