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

Fix async client update_project method #2155

Merged
merged 4 commits into from
Jan 19, 2025
Merged

Conversation

deshraj
Copy link
Collaborator

@deshraj deshraj commented Jan 17, 2025

Description

Fixes the issue:

---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
Cell In[24], [line 10](vscode-notebook-cell:?execution_count=24&line=10)
      [5](vscode-notebook-cell:?execution_count=24&line=5) print(mem0.__version__)
      [8](vscode-notebook-cell:?execution_count=24&line=8) client = AsyncMemoryClient(api_key=API_KEY, org_id=ORG_ID, project_id=PROJECT_ID)
---> [10](vscode-notebook-cell:?execution_count=24&line=10) response = await client.update_project(custom_instructions="Test prompt")
     [11](vscode-notebook-cell:?execution_count=24&line=11) print(response)

File ~/.pyenv/versions/3.12.8/lib/python3.12/site-packages/mem0/client/main.py:30, in api_error_handler.<locals>.wrapper(*args, **kwargs)
     [27](https://file+.vscode-resource.vscode-cdn.net/Users/deshraj/Projects/mem0-org/platform/notebooks/friday/~/.pyenv/versions/3.12.8/lib/python3.12/site-packages/mem0/client/main.py:27) @wraps(func)
     [28](https://file+.vscode-resource.vscode-cdn.net/Users/deshraj/Projects/mem0-org/platform/notebooks/friday/~/.pyenv/versions/3.12.8/lib/python3.12/site-packages/mem0/client/main.py:28) def wrapper(*args, **kwargs):
     [29](https://file+.vscode-resource.vscode-cdn.net/Users/deshraj/Projects/mem0-org/platform/notebooks/friday/~/.pyenv/versions/3.12.8/lib/python3.12/site-packages/mem0/client/main.py:29)     try:
---> [30](https://file+.vscode-resource.vscode-cdn.net/Users/deshraj/Projects/mem0-org/platform/notebooks/friday/~/.pyenv/versions/3.12.8/lib/python3.12/site-packages/mem0/client/main.py:30)         return func(*args, **kwargs)
     [31](https://file+.vscode-resource.vscode-cdn.net/Users/deshraj/Projects/mem0-org/platform/notebooks/friday/~/.pyenv/versions/3.12.8/lib/python3.12/site-packages/mem0/client/main.py:31)     except httpx.HTTPStatusError as e:
     [32](https://file+.vscode-resource.vscode-cdn.net/Users/deshraj/Projects/mem0-org/platform/notebooks/friday/~/.pyenv/versions/3.12.8/lib/python3.12/site-packages/mem0/client/main.py:32)         logger.error(f"HTTP error occurred: {e}")

TypeError: AsyncMemoryClient.update_project() missing 1 required positional argument: 'custom_categories'
  • Bug fix (non-breaking change which fixes an issue)

@Dev-Khant Dev-Khant merged commit 56351d1 into main Jan 19, 2025
6 checks passed
@Dev-Khant Dev-Khant deleted the user/dyadav/fix-async-client branch January 21, 2025 04:35
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.

2 participants