memwal 0.2.3.dev1__py3-none-any.whl → 0.2.3.dev2__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.
memwal/__init__.py CHANGED
@@ -134,4 +134,4 @@ __all__ = [
134
134
  "RecallManualResult",
135
135
  ]
136
136
 
137
- __version__ = "0.2.3.dev1"
137
+ __version__ = "0.2.3.dev2"
memwal/client.py CHANGED
@@ -1495,14 +1495,20 @@ class MemWal:
1495
1495
  negative-cache hits plus any new permanent failures this call.
1496
1496
  Transient download/decrypt/embed errors are not counted here; when
1497
1497
  a page yields only those, ``truncated`` is true so the caller
1498
- retries. Defaults to ``0`` when talking to a relayer older than
1499
- COMG-719 that omits the field.
1498
+ retries. A mixed or all-permanent page leaves ``truncated`` as the
1499
+ limit/cap rules set it. Defaults to ``0`` when talking to a
1500
+ relayer older than COMG-719 that omits the field.
1500
1501
  * ``total`` — count of on-chain blobs the relayer saw for
1501
- ``(owner, namespace)`` before the limit was applied.
1502
+ ``(owner, namespace)`` before the limit was applied (only blobs
1503
+ inside the sidecar fetch).
1502
1504
  * ``truncated`` — True when this restore is known-incomplete (limit
1503
1505
  truncation or an upstream on-chain candidate-fetch cap; see
1504
1506
  :class:`~memwal.types.RestoreResult`). Defaults to ``False`` when
1505
1507
  talking to a relayer older than WALM-319 that omits the field.
1508
+ * ``source_capped`` — the sidecar's owner-wide candidate fetch hit
1509
+ its cap (``min(limit * 5, 100)``). Independent of ``truncated``.
1510
+ Defaults to ``False`` when talking to a relayer older than
1511
+ WALM-451 that omits the field.
1506
1512
 
1507
1513
  Args:
1508
1514
  namespace: Namespace to restore. Exact match — no prefix or
@@ -1517,12 +1523,12 @@ class MemWal:
1517
1523
  :class:`RestoreResult`.
1518
1524
 
1519
1525
  Notes:
1520
- * **No pagination cursor** — restore is single-shot. A larger
1521
- ``limit`` may help when ``truncated`` is caused by the request
1522
- limit, but candidate discovery also has a per-owner source cap
1523
- shared across namespaces. Hitting that cap requires cursor/
1524
- pagination support for guaranteed full recovery; increasing
1525
- ``limit`` or retrying cannot guarantee it.
1526
+ * **No pagination cursor** — restore is single-shot. Raising
1527
+ ``limit`` only lets restore see more blobs when
1528
+ ``source_capped`` is true and ``limit < 20`` (that expands the
1529
+ candidate fetch up to 100). When ``source_capped`` is true and
1530
+ ``truncated`` is false, blobs past the owner-wide cap stay out
1531
+ of reach; retrying cannot surface them.
1526
1532
  * **Performance** scales linearly in ``limit``: up to 10 Walrus
1527
1533
  downloads in parallel, then 3 SEAL decrypts in parallel, then
1528
1534
  embeddings. Expect seconds-per-blob on cold caches.
@@ -1545,6 +1551,8 @@ class MemWal:
1545
1551
  truncated=data.get("truncated", False),
1546
1552
  # Relayers older than COMG-719 omit `failed`; default to 0.
1547
1553
  failed=data.get("failed", 0),
1554
+ # Relayers older than WALM-451 omit `source_capped`; default to False.
1555
+ source_capped=data.get("source_capped", False),
1548
1556
  )
1549
1557
 
1550
1558
  async def list_namespaces(
memwal/mock.py CHANGED
@@ -405,6 +405,7 @@ class MemWalMock:
405
405
  owner=self._owner,
406
406
  truncated=False,
407
407
  failed=0,
408
+ source_capped=False,
408
409
  )
409
410
 
410
411
  async def list_namespaces(
memwal/types.py CHANGED
@@ -236,9 +236,8 @@ class RestoreResult:
236
236
  #: (WALM-431 / GH #762). Also true when an inspected page produced only
237
237
  #: transients (download/decrypt/embed) so the caller retries (WALM-480).
238
238
  #:
239
- #: ``truncated=False`` is not proof the sidecar saw every on-chain blob.
240
- #: Blobs beyond the owner-wide sidecar candidate cap can still be
241
- #: missing. Follow-up field: WALM-451 (``sourceCapped``).
239
+ #: Independent of ``source_capped``: a saturated cap with a non-full
240
+ #: missing page yields ``truncated=False`` while ``source_capped=True``.
242
241
  #:
243
242
  #: Relayers older than WALM-319 don't send this field at all; the SDK
244
243
  #: defaults it to ``False`` in that case rather than requiring it.
@@ -247,6 +246,12 @@ class RestoreResult:
247
246
  #: hits plus any new permanent failures this call. Relayers older than
248
247
  #: COMG-719 omit this field; the SDK defaults it to ``0``.
249
248
  failed: int = 0
249
+ #: True when the sidecar's owner-wide candidate fetch hit its cap
250
+ #: (``min(limit * 5, 100)``). Independent of ``truncated``. When true,
251
+ #: ``total`` counts only blobs inside that fetch; blobs past the cap are
252
+ #: not visible to this restore call. Relayers that omit the field
253
+ #: default to ``False``.
254
+ source_capped: bool = False
250
255
 
251
256
 
252
257
  @dataclass
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: memwal
3
- Version: 0.2.3.dev1
3
+ Version: 0.2.3.dev2
4
4
  Summary: Python SDK for Walrus Memory — Privacy-first AI memory with Ed25519 signing
5
5
  Project-URL: Homepage, https://memory.walrus.xyz
6
6
  Project-URL: Documentation, https://memory.walrus.xyz
@@ -0,0 +1,10 @@
1
+ memwal/__init__.py,sha256=lU1nF8V8YVZGvz9foDV_5kmIxvA8t0JMiFedIGcXXpY,3290
2
+ memwal/client.py,sha256=lUL06pSZkEiXijp_QbanFZToT6DgvAfYhiw4zedl3qk,105118
3
+ memwal/compatibility.py,sha256=R3Gt1gVRjYSLNa78leNrTpGMZI1UATYo7N8Ie_44CGI,3054
4
+ memwal/middleware.py,sha256=n_kbXDO4kLqtR8ctPInAzdsorl7jTGg9rnOwhRA4aH4,38603
5
+ memwal/mock.py,sha256=Pf-WhsIHOD4yTUvm19wcxteMGDxwuHkWh-33n6gqB4Y,25315
6
+ memwal/types.py,sha256=KT48WoE9LNWahUsME1Z4nGM9lJ3wW0SvdFUIo5HDdD0,14781
7
+ memwal/utils.py,sha256=RYlELBpKUHN9RuvWQu0cSGMoyXpAdTWlNKawfDpDbQ0,13361
8
+ memwal-0.2.3.dev2.dist-info/METADATA,sha256=Wdk6rPQAx_rz5Rmd_C2Rqyw_lSpY6RFpbip9l6fWyrs,12151
9
+ memwal-0.2.3.dev2.dist-info/WHEEL,sha256=2iZrJkDIkeDh0k9SikKMqFuRP-ua6mb4Ir1AsER4BEw,87
10
+ memwal-0.2.3.dev2.dist-info/RECORD,,
@@ -1,10 +0,0 @@
1
- memwal/__init__.py,sha256=aMju-BRlVwN2p8eNSchQTfTaax5h6th7ADLZxn4w9Is,3290
2
- memwal/client.py,sha256=R6Btr_iUaChkoTHo0zJaqQiPM-Anz__5MRBfRS_ABpQ,104586
3
- memwal/compatibility.py,sha256=R3Gt1gVRjYSLNa78leNrTpGMZI1UATYo7N8Ie_44CGI,3054
4
- memwal/middleware.py,sha256=n_kbXDO4kLqtR8ctPInAzdsorl7jTGg9rnOwhRA4aH4,38603
5
- memwal/mock.py,sha256=0YBmxeixQ6lTjtiYRRTev3ZEw-x5-2lyWCeI6LYK6dM,25282
6
- memwal/types.py,sha256=sGDQ82lE5SgdoQE6fLmqD889CjUWivt8HuMjnKHjFjI,14487
7
- memwal/utils.py,sha256=RYlELBpKUHN9RuvWQu0cSGMoyXpAdTWlNKawfDpDbQ0,13361
8
- memwal-0.2.3.dev1.dist-info/METADATA,sha256=3_2s7WBmRfhx_DTianv826MEv-EFJEuWYCBoccNzaOA,12151
9
- memwal-0.2.3.dev1.dist-info/WHEEL,sha256=2iZrJkDIkeDh0k9SikKMqFuRP-ua6mb4Ir1AsER4BEw,87
10
- memwal-0.2.3.dev1.dist-info/RECORD,,