suse-documentation-mcp-server 0.14.0__tar.gz → 0.16.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,11 +1,11 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: suse-documentation-mcp-server
3
- Version: 0.14.0
3
+ Version: 0.16.0
4
4
  Summary: Add your description here
5
5
  Requires-Python: >=3.12
6
6
  Description-Content-Type: text/markdown
7
7
  Requires-Dist: httpx>=0.28.1
8
- Requires-Dist: mcp[cli]>=1.9.1
9
- Requires-Dist: pydantic>=2.11.5
8
+ Requires-Dist: mcp[cli]~=1.6.0
9
+ Requires-Dist: pydantic>=2.10.3
10
10
  Requires-Dist: python-dotenv>=1.1.0
11
11
  Requires-Dist: requests>=2.32.3
@@ -1,13 +1,13 @@
1
1
  [project]
2
2
  name = "suse-documentation-mcp-server"
3
- version = "0.14.0"
3
+ version = "0.16.0"
4
4
  description = "Add your description here"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.12"
7
7
  dependencies = [
8
8
  "httpx>=0.28.1",
9
- "mcp[cli]>=1.9.1",
10
- "pydantic>=2.11.5",
9
+ "mcp[cli]~=1.6.0",
10
+ "pydantic>=2.10.3",
11
11
  "python-dotenv>=1.1.0",
12
12
  "requests>=2.32.3",
13
13
  ]
@@ -4,6 +4,8 @@ import os
4
4
  from dotenv import load_dotenv
5
5
  from typing import Any
6
6
  from mcp.server.fastmcp import FastMCP
7
+ from pydantic import Field
8
+ from concurrent.futures import ThreadPoolExecutor
7
9
 
8
10
  load_dotenv()
9
11
 
@@ -74,14 +76,16 @@ def get_web_search_results_from_oi(query):
74
76
  return combined_response
75
77
 
76
78
  @mcp.tool()
77
- async def get_web_search_results(query: str) -> str:
79
+ async def get_web_search_results(
80
+ queries: list[str] = Field(
81
+ description="One or more concise, keyword-focused search queries. Use keywords relevant to SUSE documentation.",
82
+ ),
83
+ ) -> str:
78
84
  """
79
85
  Search SUSE documentation using web search and return results.
80
86
 
81
87
  This function is designed to perform a web search on the SUSE documentation
82
- for a given query and return the results. The function takes a search query as
83
- a string, JSON object, or dictionary, normalizes it, performs the web search,
84
- and returns a formatted string containing the content from the search results.
88
+ for a given query and return the results.
85
89
 
86
90
  Parameters:
87
91
  - query (str): The search query string to be used for the web search.
@@ -89,15 +93,18 @@ async def get_web_search_results(query: str) -> str:
89
93
  Returns:
90
94
  str: Combined content from the search results, cleaned and formatted
91
95
  """
92
- print("Entered get_web_search_results:", query)
96
+ print("Entered get_web_search_results:", queries)
97
+
93
98
  try:
94
- # Ensure query is a string
95
- if not isinstance(query, str):
96
- raise ValueError("The extracted query must be a string.")
97
- print("Before web search:", query)
98
- return get_web_search_results_from_oi(query)
99
+ if not queries:
100
+ raise ValueError("Search called with no queries.")
101
+
102
+ with ThreadPoolExecutor() as executor:
103
+ results = list(executor.map(get_web_search_results_from_oi, queries, timeout=10))
104
+
105
+ return results
99
106
  except Exception as e:
100
- return f"Error performing web search: {str(e)}\n\n{query}"
107
+ return f"Error performing web search: {str(e)}\n\n{queries}"
101
108
 
102
109
 
103
110
  def main():
@@ -1,11 +1,11 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: suse-documentation-mcp-server
3
- Version: 0.14.0
3
+ Version: 0.16.0
4
4
  Summary: Add your description here
5
5
  Requires-Python: >=3.12
6
6
  Description-Content-Type: text/markdown
7
7
  Requires-Dist: httpx>=0.28.1
8
- Requires-Dist: mcp[cli]>=1.9.1
9
- Requires-Dist: pydantic>=2.11.5
8
+ Requires-Dist: mcp[cli]~=1.6.0
9
+ Requires-Dist: pydantic>=2.10.3
10
10
  Requires-Dist: python-dotenv>=1.1.0
11
11
  Requires-Dist: requests>=2.32.3
@@ -1,5 +1,5 @@
1
1
  httpx>=0.28.1
2
- mcp[cli]>=1.9.1
3
- pydantic>=2.11.5
2
+ mcp[cli]~=1.6.0
3
+ pydantic>=2.10.3
4
4
  python-dotenv>=1.1.0
5
5
  requests>=2.32.3