Compare commits

..
Author SHA1 Message Date
ataller-lc eb066bd31a release(cli): 0.4.38 (#9411)
Bumps the CLI to 0.4.38 to cut a release including #9393 (the `priority`
section in `langgraph.json`), the only CLI change merged since 0.4.37.
The section takes effect with `langgraph-api` 0.18.0 or later; older
servers ignore it, and configs without it build the same images as
before.

Merging doesn't publish by itself: after it merges, run the `release`
workflow with `working-directory: libs/cli`.
2026-10-23 14:18:08 +00:00
ataller-lc 6b83b9b019 release(sdk-py): 0.4.9 (#9398)
Bumps the Python SDK version from 0.4.8 to 0.4.9. Adds `Priority`
(beta), which lets a deployment set each thread's priority settings in
its own code (#9392); it needs `langgraph-api` 0.18.0 or later and a
`langgraph-cli` that supports the `priority` section. Also picks up the
`certifi` bump (#9370).
2026-10-23 09:32:43 -04:00
4 changed files with 5 additions and 44 deletions

No files matched your search

+1 -1
View File
@@ -1 +1 @@
__version__ = "0.4.37"
__version__ = "0.4.38"
+3 -9
View File
@@ -34,7 +34,6 @@ from langgraph._internal._constants import (
CONFIG_KEY_THREAD_ID,
CONFIG_KEY_TIMED_ATTEMPT_OBSERVER,
NS_SEP,
RETURN,
)
from langgraph._internal._runnable import create_task_in_config_context
from langgraph._internal._timeout import sync_timeout_unsupported
@@ -734,14 +733,15 @@ async def arun_with_retry(
if stream:
async for _ in task.proc.astream(task.input, config):
pass
return _return_value(task)
break
return await task.proc.ainvoke(task.input, config)
result = await _arun_with_timeout(
task, config, resolved_timeout, attempt_ctx, stream=stream
)
_finish_timed_attempt(config, attempt_ctx)
if stream:
return _return_value(task)
# if successful, end
break
return result
except ParentCommand as exc:
ns: str = config[CONF][CONFIG_KEY_CHECKPOINT_NS]
@@ -831,12 +831,6 @@ async def arun_with_retry(
config = patch_configurable(config, {CONFIG_KEY_RESUMING: True})
def _return_value(task: PregelExecutableTask) -> Any:
# Streaming drains the task instead of returning its result, so a caller
# awaiting a `@task` needs the value the task wrote.
return next((value for channel, value in task.writes if channel == RETURN), None)
def _should_retry_on(retry_policy: RetryPolicy, exc: Exception) -> bool:
"""Check if the given exception should be retried based on the retry policy."""
if isinstance(retry_policy.retry_on, Sequence):
-33
View File
@@ -7495,39 +7495,6 @@ async def test_entrypoint_from_async_generator() -> None:
yield "b"
@NEEDS_CONTEXTVARS
@pytest.mark.parametrize("version", ["v1", "v2"])
async def test_awaited_task_returns_its_value_under_astream_events(
version: Literal["v1", "v2"],
) -> None:
class State(TypedDict):
doubled: int
zeroed: int
@task
async def double(x: int) -> int:
return x * 2
@task
async def zero() -> int:
return 0
async def node(state: State) -> State:
return {"doubled": await double(21), "zeroed": await zero()}
graph = StateGraph(State).add_node("node", node).add_edge(START, "node").compile()
outputs = [
event["data"]["output"]
async for event in graph.astream_events(
{"doubled": 0, "zeroed": 1}, version=version
)
if event["event"] == "on_chain_end" and event["name"] == "node"
]
assert outputs == [{"doubled": 42, "zeroed": 0}]
@NEEDS_CONTEXTVARS
async def test_named_tasks_functional() -> None:
class Foo:
+1 -1
View File
@@ -5,7 +5,7 @@ from langgraph_sdk.encryption.types import DecryptResult, EncryptionContext
from langgraph_sdk.priority import Priority
from langgraph_sdk.priority.types import PriorityContext, PrioritySettings
__version__ = "0.4.8"
__version__ = "0.4.9"
__all__ = [
"Auth",