Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "uipath"
version = "2.4.17"
version = "2.4.18"
description = "Python SDK and CLI for UiPath Platform, enabling programmatic interaction with automation services, process management, and deployment tools."
readme = { file = "README.md", content-type = "text/markdown" }
requires-python = ">=3.11"
Expand Down
9 changes: 5 additions & 4 deletions src/uipath/_cli/_chat/_bridge.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@
from typing import Any
from urllib.parse import urlparse

import socketio # type: ignore[import-untyped]
from socketio import AsyncClient
from uipath.core.chat import (
UiPathConversationEvent,
UiPathConversationExchangeEndEvent,
Expand Down Expand Up @@ -54,7 +52,7 @@ def __init__(
self.exchange_id = exchange_id
self.auth = auth
self.headers = headers
self._client: AsyncClient | None = None
self._client: Any | None = None
self._connected_event = asyncio.Event()

async def connect(self, timeout: float = 10.0) -> None:
Expand All @@ -77,7 +75,10 @@ async def connect(self, timeout: float = 10.0) -> None:
return

# Create new SocketIO client
self._client = socketio.AsyncClient(
# Lazy import to avoid dependency if not used, improve startup time
from socketio import AsyncClient # type: ignore[import-untyped]

self._client = AsyncClient(
logger=logger,
engineio_logger=logger,
)
Expand Down
7 changes: 4 additions & 3 deletions src/uipath/_cli/_debug/_bridge.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,7 @@
from typing import Any, Literal

from pydantic import BaseModel
from pysignalr.client import SignalRClient
from rich.console import Console
from rich.syntax import Syntax
from rich.tree import Tree
from uipath.runtime import (
UiPathBreakpointResult,
Expand Down Expand Up @@ -436,6 +434,7 @@ def add_to_tree(node: Tree, payload: Any, depth: int = 0):
json_str = json.dumps(data, indent=2, default=str)
if len(json_str) > 10000:
json_str = json_str[:10000] + "\n..."
from rich.syntax import Syntax

syntax = Syntax(json_str, "json", theme="monokai", line_numbers=False)
self.console.print(f"\n[dim]{label}:")
Expand Down Expand Up @@ -465,7 +464,6 @@ def __init__(
self.access_token = access_token
self.headers = headers or {}
self.state = DebuggerState()
self._client: SignalRClient | None = None
self._connected_event = asyncio.Event()
self._resume_event: asyncio.Event | None = None
self._terminate_event = asyncio.Event()
Expand All @@ -476,6 +474,9 @@ async def connect(self) -> None:
if self.access_token:
all_headers["Authorization"] = f"Bearer {self.access_token}"

# Lazy import to avoid dependency if not used, improve startup time
from pysignalr.client import SignalRClient

self._client = SignalRClient(self.hub_url, headers=all_headers)

# Register event handlers
Expand Down
2 changes: 1 addition & 1 deletion uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.