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

langchain[patch]: make hub work with older langchainhub versions #19076

Merged
merged 2 commits into from
Mar 15, 2024

Conversation

eyurtsev
Copy link
Collaborator

Make it work with older clients

Copy link

vercel bot commented Mar 14, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
langchain ⬜️ Ignored (Inspect) Visit Preview Mar 14, 2024 6:01pm

@eyurtsev eyurtsev requested a review from efriis March 14, 2024 15:47
@dosubot dosubot bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Mar 14, 2024
@dosubot dosubot bot added 🔌: anthropic Primarily related to Anthropic integrations 🤖:improvement Medium size change to existing code to handle new use-cases labels Mar 14, 2024
@eyurtsev eyurtsev requested a review from hinthornw March 14, 2024 15:49
@@ -80,6 +80,12 @@ def pull(
:param api_key: The API key to use to authenticate with the LangChain Hub API.
"""
client = _get_client(api_url=api_url, api_key=api_key)

if hasattr(client, "pull"): # <= 0.1.14
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It still has 'pull', the check you want is for pull_repo and if that attr isn't present then do pull las a fallback

@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. and removed size:XS This PR changes 0-9 lines, ignoring generated files. labels Mar 14, 2024
@eyurtsev eyurtsev requested a review from hinthornw March 14, 2024 19:55
@dosubot dosubot bot added the lgtm PR looks good. Use to confirm that a PR is ready for merging. label Mar 15, 2024
@hinthornw hinthornw merged commit 0ddfe7f into master Mar 15, 2024
41 checks passed
@hinthornw hinthornw deleted the eugene/fix_hub branch March 15, 2024 22:37
rahul-trip pushed a commit to daxa-ai/langchain that referenced this pull request Mar 27, 2024
bechbd pushed a commit to bechbd/langchain that referenced this pull request Mar 29, 2024
gkorland pushed a commit to FalkorDB/langchain that referenced this pull request Mar 30, 2024
hinthornw pushed a commit that referenced this pull request Apr 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🔌: anthropic Primarily related to Anthropic integrations 🤖:improvement Medium size change to existing code to handle new use-cases lgtm PR looks good. Use to confirm that a PR is ready for merging. size:S This PR changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants