langgraph-api 0.2.64__py3-none-any.whl → 0.2.67__py3-none-any.whl

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.

Potentially problematic release.


This version of langgraph-api might be problematic. Click here for more details.

langgraph_api/__init__.py CHANGED
@@ -1 +1 @@
1
- __version__ = "0.2.64"
1
+ __version__ = "0.2.67"
@@ -436,6 +436,9 @@ class DotDict:
436
436
  def items(self):
437
437
  return self._dict.items()
438
438
 
439
+ def get(self, key, /, default=None):
440
+ return self._dict.get(key, default)
441
+
439
442
  def values(self):
440
443
  return self._dict.values()
441
444
 
langgraph_api/cli.py CHANGED
@@ -114,6 +114,46 @@ class AuthConfig(TypedDict, total=False):
114
114
  """
115
115
 
116
116
 
117
+ def _check_newer_version(pkg: str, timeout: float = 0.2) -> None:
118
+ """Log a notice if PyPI reports a newer version."""
119
+ import importlib.metadata as md
120
+ import json
121
+ import urllib.request
122
+
123
+ from packaging.version import Version
124
+
125
+ thread_logger = logging.getLogger("check_version")
126
+ if not thread_logger.handlers:
127
+ handler = logging.StreamHandler()
128
+ handler.setFormatter(logging.Formatter("%(message)s"))
129
+ thread_logger.addHandler(handler)
130
+
131
+ try:
132
+ current = Version(md.version(pkg))
133
+ with urllib.request.urlopen(
134
+ f"https://pypi.org/pypi/{pkg}/json", timeout=timeout
135
+ ) as resp:
136
+ latest_str = json.load(resp)["info"]["version"]
137
+ latest = Version(latest_str)
138
+ if latest > current:
139
+ thread_logger.info(
140
+ "🔔 A newer version of %s is available: %s → %s (pip install -U %s)",
141
+ pkg,
142
+ current,
143
+ latest,
144
+ pkg,
145
+ )
146
+
147
+ except Exception:
148
+ pass
149
+
150
+ except RuntimeError:
151
+ thread_logger.info(
152
+ f"Failed to check for newer version of {pkg}."
153
+ " To disable version checks, set LANGGRAPH_NO_VERSION_CHECK=true"
154
+ )
155
+
156
+
117
157
  def run_server(
118
158
  host: str = "127.0.0.1",
119
159
  port: int = 2024,
@@ -312,6 +352,12 @@ For production use, please use LangGraph Cloud.
312
352
  logger.info(welcome)
313
353
  if open_browser:
314
354
  threading.Thread(target=_open_browser, daemon=True).start()
355
+ nvc = os.getenv("LANGGRAPH_NO_VERSION_CHECK")
356
+ if nvc is None or nvc.lower() not in ("true", "1"):
357
+ print("Checking for newer version...")
358
+ threading.Thread(
359
+ target=_check_newer_version, args=("langgraph-api",), daemon=True
360
+ ).start()
315
361
  supported_kwargs = {
316
362
  k: v
317
363
  for k, v in kwargs.items()
@@ -79,6 +79,8 @@ def _snapshot_defaults():
79
79
  def default_command(obj):
80
80
  if isinstance(obj, Send):
81
81
  return {"node": obj.node, "args": obj.arg}
82
+ if isinstance(obj, ProxyUser):
83
+ return obj.dict()
82
84
  raise TypeError
83
85
 
84
86
 
langgraph_api/worker.py CHANGED
@@ -51,6 +51,8 @@ async def set_auth_ctx_for_run(
51
51
  user = run_kwargs["config"]["configurable"]["langgraph_auth_user"]
52
52
  permissions = run_kwargs["config"]["configurable"]["langgraph_auth_permissions"]
53
53
  user = normalize_user(user)
54
+ # Reapply normalization to the kwargs
55
+ run_kwargs["config"]["configurable"]["langgraph_auth_user"] = user
54
56
  except Exception:
55
57
  user = SimpleUser(user_id) if user_id is not None else None
56
58
  permissions = None
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: langgraph-api
3
- Version: 0.2.64
3
+ Version: 0.2.67
4
4
  Author-email: Nuno Campos <nuno@langchain.dev>, Will Fu-Hinthorn <will@langchain.dev>
5
5
  License: Elastic-2.0
6
6
  License-File: LICENSE
@@ -1,7 +1,7 @@
1
- langgraph_api/__init__.py,sha256=Cky6MfpVU9OMd3wdSmDN2DS84_OB2b-D-ehYk3Ukol0,23
1
+ langgraph_api/__init__.py,sha256=rEMkQMd1xEY6WmwoTUQ4Q_9L1tdN4h_gKqmCA7tRVnU,23
2
2
  langgraph_api/asgi_transport.py,sha256=eqifhHxNnxvI7jJqrY1_8RjL4Fp9NdN4prEub2FWBt8,5091
3
3
  langgraph_api/asyncio.py,sha256=Odnc6mAJIGF3eFWT8Xcrg2Zam7FwzXkfCWEHaXfrzQQ,9371
4
- langgraph_api/cli.py,sha256=9Ou3tGDDY_VVLt5DFle8UviJdpI4ZigC5hElYvq2-To,14519
4
+ langgraph_api/cli.py,sha256=OBW3oKbK8wM0_JrKdWI0mMjCb047OwT_S6OTSp7vBf4,16066
5
5
  langgraph_api/command.py,sha256=3O9v3i0OPa96ARyJ_oJbLXkfO8rPgDhLCswgO9koTFA,768
6
6
  langgraph_api/config.py,sha256=jmtO5LXubet2Hl7S2tF2BRyB_q2yqCzFqCwN7n6za4Y,11727
7
7
  langgraph_api/cron_scheduler.py,sha256=i87j4pJrcsmsqMKeKUs69gaAjrGaSM3pM3jnXdN5JDQ,2630
@@ -24,7 +24,7 @@ langgraph_api/thread_ttl.py,sha256=-Ox8NFHqUH3wGNdEKMIfAXUubY5WGifIgCaJ7npqLgw,1
24
24
  langgraph_api/utils.py,sha256=92mSti9GfGdMRRWyESKQW5yV-75Z9icGHnIrBYvdypU,3619
25
25
  langgraph_api/validation.py,sha256=zMuKmwUEBjBgFMwAaeLZmatwGVijKv2sOYtYg7gfRtc,4950
26
26
  langgraph_api/webhook.py,sha256=1ncwO0rIZcj-Df9sxSnFEzd1gP1bfS4okeZQS8NSRoE,1382
27
- langgraph_api/worker.py,sha256=uQg_YEmr0zDTX3BR3bcI2L6SWu4YRWbgELk0gvlnymc,15900
27
+ langgraph_api/worker.py,sha256=2LZUzcZGyK8_-ajmGHdoKhU7HT0SdBPLDLEJlBDyz2w,16021
28
28
  langgraph_api/api/__init__.py,sha256=YVzpbn5IQotvuuLG9fhS9QMrxXfP4s4EpEMG0n4q3Nw,5625
29
29
  langgraph_api/api/assistants.py,sha256=6IPVKQBlI95-Z4nYdqBY9st9oynGJAocL67cwnDaZCk,15744
30
30
  langgraph_api/api/mcp.py,sha256=RvRYgANqRzNQzSmgjNkq4RlKTtoEJYil04ot9lsmEtE,14352
@@ -35,7 +35,7 @@ langgraph_api/api/store.py,sha256=TSeMiuMfrifmEnEbL0aObC2DPeseLlmZvAMaMzPgG3Y,55
35
35
  langgraph_api/api/threads.py,sha256=ogMKmEoiycuaV3fa5kpupDohJ7fwUOfVczt6-WSK4FE,9322
36
36
  langgraph_api/api/ui.py,sha256=2nlipYV2nUGR4T9pceaAbgN1lS3-T2zPBh7Nv3j9eZQ,2479
37
37
  langgraph_api/auth/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
38
- langgraph_api/auth/custom.py,sha256=f_gKqtz1BlPQcwDBlG91k78nxAWKLcxU3wF1tvbZByg,22120
38
+ langgraph_api/auth/custom.py,sha256=ZtNSQ4hIldbd2HvRsilwKzN_hjCWIiIOHClmYyPi8FM,22206
39
39
  langgraph_api/auth/middleware.py,sha256=jDA4t41DUoAArEY_PNoXesIUBJ0nGhh85QzRdn5EPD0,1916
40
40
  langgraph_api/auth/noop.py,sha256=Bk6Nf3p8D_iMVy_OyfPlyiJp_aEwzL-sHrbxoXpCbac,586
41
41
  langgraph_api/auth/studio_user.py,sha256=fojJpexdIZYI1w3awiqOLSwMUiK_M_3p4mlfQI0o-BE,454
@@ -52,7 +52,7 @@ langgraph_api/js/client.mts,sha256=N9CTH7mbXGSD-gpv-XyruYsHI-rgrObL8cQoAp5s3_U,3
52
52
  langgraph_api/js/errors.py,sha256=Cm1TKWlUCwZReDC5AQ6SgNIVGD27Qov2xcgHyf8-GXo,361
53
53
  langgraph_api/js/global.d.ts,sha256=j4GhgtQSZ5_cHzjSPcHgMJ8tfBThxrH-pUOrrJGteOU,196
54
54
  langgraph_api/js/package.json,sha256=BpNAO88mbE-Gv4WzQfj1TLktCWGqm6XBqI892ObuOUw,1333
55
- langgraph_api/js/remote.py,sha256=WlfVJbxsk-T8EzzGGnzpZbZmMfh_NfVYTNvU663j1oA,36103
55
+ langgraph_api/js/remote.py,sha256=7WVO6k2JdYSFiHe-O77bn5GoVxIV4BvQXuILTvEYvmc,36164
56
56
  langgraph_api/js/schema.py,sha256=7idnv7URlYUdSNMBXQcw7E4SxaPxCq_Oxwnlml8q5ik,408
57
57
  langgraph_api/js/sse.py,sha256=lsfp4nyJyA1COmlKG9e2gJnTttf_HGCB5wyH8OZBER8,4105
58
58
  langgraph_api/js/tsconfig.json,sha256=imCYqVnqFpaBoZPx8k1nO4slHIWBFsSlmCYhO73cpBs,341
@@ -85,9 +85,9 @@ langgraph_runtime/retry.py,sha256=V0duD01fO7GUQ_btQkp1aoXcEOFhXooGVP6q4yMfuyY,11
85
85
  langgraph_runtime/store.py,sha256=7mowndlsIroGHv3NpTSOZDJR0lCuaYMBoTnTrewjslw,114
86
86
  LICENSE,sha256=ZPwVR73Biwm3sK6vR54djCrhaRiM4cAD2zvOQZV8Xis,3859
87
87
  logging.json,sha256=3RNjSADZmDq38eHePMm1CbP6qZ71AmpBtLwCmKU9Zgo,379
88
- openapi.json,sha256=wrJup7sCRlZXTRagjzGZ7474U1wma4ZzYTkkninrT6M,141875
89
- langgraph_api-0.2.64.dist-info/METADATA,sha256=GlHEV7EoXRfoqyUNqxnxmIIp1nfEjW20OJeIcxtMVAs,3891
90
- langgraph_api-0.2.64.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
91
- langgraph_api-0.2.64.dist-info/entry_points.txt,sha256=hGedv8n7cgi41PypMfinwS_HfCwA7xJIfS0jAp8htV8,78
92
- langgraph_api-0.2.64.dist-info/licenses/LICENSE,sha256=ZPwVR73Biwm3sK6vR54djCrhaRiM4cAD2zvOQZV8Xis,3859
93
- langgraph_api-0.2.64.dist-info/RECORD,,
88
+ openapi.json,sha256=J4ICw3-W3LdxQOfsTuzcZVYt3e9UFeLb6oPr_a-5iHU,141823
89
+ langgraph_api-0.2.67.dist-info/METADATA,sha256=1hZkOLWJ9LVcgf2vwpW_BYo6wNZNdCSUypsirjGyliM,3891
90
+ langgraph_api-0.2.67.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
91
+ langgraph_api-0.2.67.dist-info/entry_points.txt,sha256=hGedv8n7cgi41PypMfinwS_HfCwA7xJIfS0jAp8htV8,78
92
+ langgraph_api-0.2.67.dist-info/licenses/LICENSE,sha256=ZPwVR73Biwm3sK6vR54djCrhaRiM4cAD2zvOQZV8Xis,3859
93
+ langgraph_api-0.2.67.dist-info/RECORD,,
openapi.json CHANGED
@@ -4513,9 +4513,7 @@
4513
4513
  "values": {
4514
4514
  "anyOf": [
4515
4515
  {
4516
- "items": {
4517
- "type": "object"
4518
- },
4516
+ "items": {},
4519
4517
  "type": "array"
4520
4518
  },
4521
4519
  {