File python-langchain-mcp-adapters.spec of Package python-langchain-mcp-adapters
#
# spec file for package python-langchain-mcp-adapters
#
# Copyright (c) 2025 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: python-langchain-mcp-adapters
Version: 0.1.9
Release: 0
Summary: Make Anthropic Model Context Protocol (MCP) tools compatible with LangChain and LangGraph agents
License: MIT
URL: https://github.com/langchain-ai/langchain
Source: https://files.pythonhosted.org/packages/source/l/langchain-mcp-adapters/langchain_mcp_adapters-%{version}.tar.gz
# PATCH-FIX-UPSTREAM https://github.com/langchain-ai/langchain-mcp-adapters/pull/270 use python3 evocations in tests
Patch: python3.patch
BuildRequires: python-rpm-macros
BuildRequires: %{python_module pdm-backend}
BuildRequires: %{python_module pip}
# SECTION test requirements
BuildRequires: %{python_module langchain-core >= 0.3.36}
BuildRequires: %{python_module mcp >= 1.9.2}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module pytest-asyncio}
BuildRequires: %{python_module pytest-socket}
BuildRequires: %{python_module typing-extensions >= 4.14.0}
# /SECTION
BuildRequires: fdupes
Requires: python-langchain-core >= 0.3.36
Requires: python-mcp >= 1.9.2
Requires: python-typing-extensions >= 4.14.0
BuildArch: noarch
%python_subpackages
%description
This library provides a lightweight wrapper that makes [Anthropic Model Context Protocol (MCP)](https://modelcontextprotocol.io/introduction) tools compatible with [LangChain](https://github.com/langchain-ai/langchain) and [LangGraph](https://github.com/langchain-ai/langgraph).
%prep
%autosetup -p1 -n langchain_mcp_adapters-%{version}
%build
%pyproject_wheel
%install
%pyproject_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
%pytest
%files %{python_files}
%{python_sitelib}/langchain_mcp_adapters
%{python_sitelib}/langchain_mcp_adapters-%{version}.dist-info
%changelog