Skip to content

Commit 6914881

Browse files
authored
Merge pull request #142 from UiPath/fix/env-vars
fix: pass env vars to coded mcp servers
2 parents e9632a2 + c9acde8 commit 6914881

File tree

4 files changed

+9
-8
lines changed

4 files changed

+9
-8
lines changed

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
[project]
22
name = "uipath-mcp"
3-
version = "0.0.101"
3+
version = "0.0.102"
44
description = "UiPath MCP SDK"
55
readme = { file = "README.md", content-type = "text/markdown" }
66
requires-python = ">=3.11"
77
dependencies = [
88
"mcp==1.11.0",
99
"pysignalr==1.3.0",
10-
"uipath>=2.0.78, <2.1.0",
10+
"uipath>=2.1.0, <2.2.0",
1111
]
1212
classifiers = [
1313
"Development Status :: 3 - Alpha",

src/uipath_mcp/_cli/_runtime/_runtime.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ async def _register(self) -> None:
365365
initialization_successful = False
366366
tools_result: Optional[ListToolsResult] = None
367367
server_stderr_output = ""
368-
env_vars = dict(server.env)
368+
env_vars = server.env
369369

370370
# if server is Coded, include environment variables
371371
if self.server_type is UiPathServerType.Coded:

src/uipath_mcp/_cli/cli_run.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818

1919
def mcp_run_middleware(
20-
entrypoint: Optional[str], input: Optional[str], resume: bool
20+
entrypoint: Optional[str], input: Optional[str], resume: bool, **kwargs
2121
) -> MiddlewareResult:
2222
"""Middleware to handle MCP server execution"""
2323

@@ -37,6 +37,7 @@ async def execute():
3737
context.entrypoint = entrypoint
3838
context.input = input
3939
context.resume = resume
40+
context.debug = kwargs.get("debug", False)
4041
context.logs_min_level = env.get("LOG_LEVEL", "INFO")
4142
context.job_id = env.get("UIPATH_JOB_KEY")
4243
context.folder_key = env.get("UIPATH_FOLDER_KEY")

uv.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)