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

Python: Bug: QdrantMemoryStore.does_collection_exist throws error #6949

Closed
0xMihir opened this issue Jun 25, 2024 · 0 comments · Fixed by #6950
Closed

Python: Bug: QdrantMemoryStore.does_collection_exist throws error #6949

0xMihir opened this issue Jun 25, 2024 · 0 comments · Fixed by #6950
Labels
bug Something isn't working python Pull requests for the Python Semantic Kernel triage

Comments

@0xMihir
Copy link
Contributor

0xMihir commented Jun 25, 2024

Describe the bug
When trying to run QdrantMemoryStore.does_collection_exist on a collection that does not exist, it throws an error. This is because it tries to catch a ValueError and not the actual UnexpectedResponse`.

To Reproduce
Steps to reproduce the behavior:
Run qdrant.does_collection_exist("nonexistent")
Throws error.

Expected behavior
Returns False when the collection doesn't exist

Platform

  • Language: Python
  • Source: semantic-kernel 1.0.5
@0xMihir 0xMihir added the bug Something isn't working label Jun 25, 2024
@markwallace-microsoft markwallace-microsoft added python Pull requests for the Python Semantic Kernel triage labels Jun 25, 2024
@github-actions github-actions bot changed the title Bug: QdrantMemoryStore.does_collection_exist throws error Python: Bug: QdrantMemoryStore.does_collection_exist throws error Jun 25, 2024
github-merge-queue bot pushed a commit that referenced this issue Jun 28, 2024
### Motivation and Context

Fixes #6949. 

### Description

Catches the correct error for does_collection_exist. 

### Contribution Checklist

- [x] The code builds clean without any errors or warnings
- [x] The PR follows the [SK Contribution
Guidelines](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md)
and the [pre-submission formatting
script](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md#development-scripts)
raises no violations
- [x] All unit tests pass, and I have added new tests where possible
- [x] I didn't break anyone 😄

---------

Co-authored-by: Evan Mattson <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working python Pull requests for the Python Semantic Kernel triage
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants