matelab-python-sdk 0.1.0a19__tar.gz → 0.1.0a22__tar.gz
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.
- matelab_python_sdk-0.1.0a22/AGENTS.md +52 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/CHANGELOG.md +35 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/PKG-INFO +27 -19
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/README.md +26 -18
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/contracts/matelab-integration-v1.lock.json +3 -3
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/contracts/matelab-integration-v1.openapi.yaml +100 -83
- matelab_python_sdk-0.1.0a22/docs/agent-architecture.md +28 -0
- matelab_python_sdk-0.1.0a22/docs/agent-workflows.md +76 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/docs/operation-coverage.yaml +5 -5
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/pyproject.toml +1 -1
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/_generated/models.py +152 -48
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/domains/records.py +1 -7
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_generation.py +168 -4
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_operation_coverage.py +1 -1
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_record_mutations.py +16 -8
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_records.py +103 -12
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/uv.lock +1 -1
- matelab_python_sdk-0.1.0a19/AGENTS.md +0 -94
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/.env.example +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/.github/workflows/release.yml +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/.gitignore +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/CONTEXT.md +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/LICENSE +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/NOTICE +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/scripts/check_installed_package.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/scripts/check_release.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/scripts/generate_models.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/__init__.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/_generated/__init__.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/_hashes.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/_transport.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/_wire_validation.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/client.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/domains/__init__.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/domains/_attachment_content.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/domains/cloud_drive.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/domains/groups.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/domains/literature.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/domains/notebooks.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/domains/templates.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/domains/uploads.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/domains/users.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/errors.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/py.typed +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/session.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/src/matelab/streaming.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/conftest.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/provider/test_provider_smoke.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_async_attachment_upload.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_client.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_cloud_drive.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_comments_and_downloads.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_consumer_smoke.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_errors.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_extended_records.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_groups.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_notebook_lifecycle.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_notebooks.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_record_lifecycle.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_release.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_streaming.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_template_lifecycle.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_templates.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_transport.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_uploads_and_literature.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/test_users.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/typing/consumer.py +0 -0
- {matelab_python_sdk-0.1.0a19 → matelab_python_sdk-0.1.0a22}/tests/typing/pyproject.toml +0 -0
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# AGENTS.md
|
|
2
|
+
|
|
3
|
+
本文件只承载每次维护都必须在上下文中的步骤、权威和授权边界。分支规则通过下列指针按需加载。
|
|
4
|
+
|
|
5
|
+
## 维护顺序
|
|
6
|
+
|
|
7
|
+
1. **定界**:先读 `git status` 和适用权威;完成标准是任务范围、用户现有改动和所需外部权限均已识别。
|
|
8
|
+
2. **查证**:沿 public intent → wire operation → Provider evidence 核对;完成标准是每个受影响 operation 的
|
|
9
|
+
request、response、security、examples、成功码及 PVD/PCG 均有结论,Contract 缺口已明确报告。
|
|
10
|
+
3. **收敛**:只修改任务必需的层;完成标准是 public、adapter、generated、tests、coverage 和 docs 的影响均已
|
|
11
|
+
记账,未加入 Provider 推测、Consumer 私有概念或无真实第二实现的 seam。
|
|
12
|
+
4. **验证**:先跑聚焦测试,再跑适用的完整门槛;完成标准是必需命令全部退出为零,skip 单独说明。
|
|
13
|
+
5. **交付**:复核最终 diff、状态和验证证据;完成标准是结果、限制和未执行项都可由用户独立核对。
|
|
14
|
+
|
|
15
|
+
## 分支指针
|
|
16
|
+
|
|
17
|
+
- **SDK architecture**:修改 public 类型、命名、身份空间或模块边界时读
|
|
18
|
+
[`docs/agent-architecture.md#public-interface`](docs/agent-architecture.md#public-interface);修改 transport、认证、
|
|
19
|
+
Session、stream 或错误时读
|
|
20
|
+
[`docs/agent-architecture.md#transport-session-and-errors`](docs/agent-architecture.md#transport-session-and-errors)。
|
|
21
|
+
- **Contract adoption**:同步 spec tag、snapshot、lock 或生成模型时执行
|
|
22
|
+
[`docs/agent-workflows.md#contract-adoption`](docs/agent-workflows.md#contract-adoption)。
|
|
23
|
+
- **Delivery gate**:代码、Contract、依赖或构建元数据变化后执行
|
|
24
|
+
[`docs/agent-workflows.md#delivery-gate`](docs/agent-workflows.md#delivery-gate)。
|
|
25
|
+
- **Provider validation**:任何实时 Provider smoke、读取或 mutation 前执行
|
|
26
|
+
[`docs/agent-workflows.md#provider-validation`](docs/agent-workflows.md#provider-validation)。
|
|
27
|
+
- **Release**:版本、制品、commit、tag、push 或 publish 任务执行
|
|
28
|
+
[`docs/agent-workflows.md#release`](docs/agent-workflows.md#release)。
|
|
29
|
+
|
|
30
|
+
## 权威
|
|
31
|
+
|
|
32
|
+
| 权威 | 负责内容 |
|
|
33
|
+
| --- | --- |
|
|
34
|
+
| `README.md` | 当前 public interface、集成语义、示例及人类流程 |
|
|
35
|
+
| `CONTEXT.md` | public 类型和命名采用的领域词汇 |
|
|
36
|
+
| `CHANGELOG.md` | SDK 版本变化与迁移影响;不定义当前接口 |
|
|
37
|
+
| `docs/operation-coverage.yaml` | operation 状态、公开入口、稳定性和已知问题 |
|
|
38
|
+
| `pyproject.toml` | SDK 版本、依赖范围、构建与工具配置;`uv.lock` 只锁定本仓库环境 |
|
|
39
|
+
| Contract lock 与 snapshot | Contract pin 与 wire schema |
|
|
40
|
+
| `src/matelab/__init__.py::__all__` | 公开导入边界 |
|
|
41
|
+
|
|
42
|
+
机器权威变化时,同一变更同步受影响的当前态文档;历史只追加到 `CHANGELOG.md`。测试提供行为证据,不替代
|
|
43
|
+
接口、coverage 或 Contract 权威。
|
|
44
|
+
|
|
45
|
+
## 范围与授权
|
|
46
|
+
|
|
47
|
+
- 现有工作区改动属于用户;在其上做最小、可归因的修改。默认只写本仓库,邻接的 spec、Provider 和 Consumer
|
|
48
|
+
仓库只作只读证据来源。
|
|
49
|
+
- `/home/tnzhu/projects/matelab-spec` 定义 Wire Contract、兼容策略及 Provider 问题;`matelab-server` 是 Provider
|
|
50
|
+
实现,`matelab-mcp` 只提供 Consumer evidence,均不能反向定义 SDK interface。
|
|
51
|
+
- commit、push、tag、publish、生产访问和真实 Provider mutation 需要本轮明确授权;授权只覆盖用户指定的目标与
|
|
52
|
+
副作用。
|
|
@@ -3,6 +3,41 @@
|
|
|
3
3
|
This file records release-to-release changes and migration impact. It is not the authority for the current interface;
|
|
4
4
|
see [README.md](README.md) for current behavior and [AGENTS.md](AGENTS.md) for maintenance policy.
|
|
5
5
|
|
|
6
|
+
## 0.1.0a22 - 2026-09-03
|
|
7
|
+
|
|
8
|
+
- Adopts immutable `matelab-spec v0.4.5` at commit `6afac7ff151680130e6e4bc6d95782589b97f4e7` and OpenAPI
|
|
9
|
+
SHA-256 `31a8d03b4366e2345dfccdbbaaaccf6754b2711428afa4295d778d121988460d`, aligned with Provider source evidence
|
|
10
|
+
`59eb05b233e5ddd023a60ccb5e5c5f2ae22a70f0` and its verified production-core equivalent.
|
|
11
|
+
- Tightens the private `readRecord` wire model so required `datetime_locked` is a non-negative integer; the Provider
|
|
12
|
+
normalizes an unavailable lock timestamp to `0`. The public `Record` interface remains unchanged.
|
|
13
|
+
- Retains the root-only `RecordFilesAttachmentAppend` boundary because `UpdateRecordRequest.add[]` still excludes the
|
|
14
|
+
folder `path` declared by the dedicated staged-name append schema; PVD-044 remains contract-contained.
|
|
15
|
+
|
|
16
|
+
## 0.1.0a21 - 2026-08-28
|
|
17
|
+
|
|
18
|
+
- Adopts immutable `matelab-spec v0.4.4` at commit `be070c5f931b2063327a3beaccc53a360204b64e` and OpenAPI
|
|
19
|
+
SHA-256 `2de38e46d3814b8b049af8afd18e85fb20be6ca29cc409390d25df663abc43f9`, aligned with Provider evidence
|
|
20
|
+
`7bd9704286057653632424fa82f413d99cd69ab6`.
|
|
21
|
+
- Accepts the required nullable `readRecord.datetime_locked` wire field for current unlocked records and follows the
|
|
22
|
+
unexposed `/actions/app` rename to `readApplicationBootstrap`; SDK Session identity remains sourced from token issuance.
|
|
23
|
+
- Keeps `RecordFilesAttachmentAppend` root-only. The release describes a safe optional folder path in its dedicated
|
|
24
|
+
staged-name append schema, but `UpdateRecordRequest.add[]` still references `AddValueOperation`, which forbids that
|
|
25
|
+
`path`;
|
|
26
|
+
exposing it would require bypassing whole-request Contract validation. PVD-044 also records that malformed path
|
|
27
|
+
containers can silently append at root.
|
|
28
|
+
|
|
29
|
+
## 0.1.0a20 - 2026-08-24
|
|
30
|
+
|
|
31
|
+
- Adopts immutable `matelab-spec v0.4.3` at commit `7965ac9803505ae35dc5ce36f52afc3c2c133c45` and OpenAPI
|
|
32
|
+
SHA-256 `6576812dd13f92ad58131f4edb8dc919d1b1fe0f19a695c2d25fbe6d13a8445b`, aligned with Provider evidence
|
|
33
|
+
`a3e6b961800f6b1ab666f0d3f6cd4c64c2a3ce27`.
|
|
34
|
+
- Breaking: tightens record readback to one canonical attachment object or `null` per table file cell, removing the
|
|
35
|
+
obsolete attachment-array compatibility path. Template decoding now accepts nullable JSON-code data and preserves
|
|
36
|
+
empty-string number/boolean cells alongside their scalar and null forms.
|
|
37
|
+
- Records PVD-046 while keeping `templates.save_content()` deliberately narrower than the Provider: the request remains
|
|
38
|
+
a canonical module list, and every table file cell remains one canonical attachment object or `null`, never an
|
|
39
|
+
arbitrary or multi-attachment array.
|
|
40
|
+
|
|
6
41
|
## 0.1.0a19 - 2026-08-23
|
|
7
42
|
|
|
8
43
|
- Re-adopts the force-rewritten `matelab-spec v0.4.2` at commit
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: matelab-python-sdk
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.0a22
|
|
4
4
|
Summary: Reusable async Python client for the Matelab Integration Contract
|
|
5
5
|
Author-email: 朱天念 <zhutiannian@gmail.com>
|
|
6
6
|
License-Expression: Apache-2.0
|
|
@@ -35,10 +35,10 @@ This README describes the current SDK interface, integration semantics, examples
|
|
|
35
35
|
[AGENTS.md](AGENTS.md) for durable maintenance rules, and `docs/operation-coverage.yaml` for the machine-readable
|
|
36
36
|
operation inventory.
|
|
37
37
|
|
|
38
|
-
The current alpha is `0.1.
|
|
38
|
+
The current alpha is `0.1.0a22`. `[project].version` in `pyproject.toml` is the sole SDK version source;
|
|
39
39
|
`uv.lock` only mirrors that source.
|
|
40
40
|
|
|
41
|
-
The SDK is pinned to the
|
|
41
|
+
The SDK is pinned to the immutable `matelab-spec v0.4.5` Contract Release. The sole release pin is
|
|
42
42
|
`contracts/matelab-integration-v1.lock.json`, which records
|
|
43
43
|
the source tag, commit, OpenAPI path, local snapshot path, and SHA-256.
|
|
44
44
|
|
|
@@ -64,14 +64,14 @@ To test the same artifact a downstream Consumer will install, build and install
|
|
|
64
64
|
|
|
65
65
|
```bash
|
|
66
66
|
uv build --no-build-isolation --out-dir dist/release
|
|
67
|
-
python -m pip install dist/release/matelab_python_sdk-0.1.
|
|
67
|
+
python -m pip install dist/release/matelab_python_sdk-0.1.0a22-py3-none-any.whl
|
|
68
68
|
```
|
|
69
69
|
|
|
70
70
|
Do not infer Provider compatibility from the SDK version alone. A release is also bound to the Contract
|
|
71
71
|
tag, commit, and checksum recorded below.
|
|
72
72
|
|
|
73
73
|
The Contract and public SDK interface track the current reviewed Provider at
|
|
74
|
-
`
|
|
74
|
+
`59eb05b233e5ddd023a60ccb5e5c5f2ae22a70f0`. Provider limitations that remain relevant to integrations are documented
|
|
75
75
|
alongside the affected interfaces below.
|
|
76
76
|
|
|
77
77
|
## Design
|
|
@@ -121,7 +121,7 @@ success code it does not allow raises `MatelabProtocolError` rather than assigni
|
|
|
121
121
|
`MatelabTransportError.status_code` remains available for HTTP failures. Provider response bodies, top-level `msg`,
|
|
122
122
|
legacy `errmsg`, opaque `errs`, uncontracted debug fields, and request payloads are not attached to exceptions because
|
|
123
123
|
Provider-authored diagnostics may contain stack traces, credentials, or submitted values.
|
|
124
|
-
The pinned v0.4.
|
|
124
|
+
The pinned v0.4.5 Contract also declares optional code-4 `errs`, but PVD-041 and PCG-015 record opaque array/object
|
|
125
125
|
containers and insufficient evidence for requiredness, cardinality, or exclusion from other codes. The SDK
|
|
126
126
|
therefore keeps those diagnostics wire-only and does not expose `errs` as stable public metadata. A typed detail
|
|
127
127
|
interface remains blocked until a future Contract release can define one from stronger Provider evidence. `retryable`
|
|
@@ -316,8 +316,10 @@ supports one file column. A locally rejected target does not spend the handle; o
|
|
|
316
316
|
result cannot be retried through the same client.
|
|
317
317
|
|
|
318
318
|
Files-module append and table/files replacement use the general record attachment intents and may be combined with
|
|
319
|
-
other non-conflicting record changes. `RecordFilesAttachmentAppend` targets the module root
|
|
320
|
-
|
|
319
|
+
other non-conflicting record changes. `RecordFilesAttachmentAppend` currently targets the module root. Although
|
|
320
|
+
v0.4.5 records Provider evidence for safe folder paths, its top-level `UpdateRecordRequest.add[]` schema still excludes
|
|
321
|
+
the `path` property declared by the dedicated staged-name append shape; the SDK therefore does not expose folder paths
|
|
322
|
+
until that wire-schema conflict is resolved (PVD-044):
|
|
321
323
|
|
|
322
324
|
```python
|
|
323
325
|
from matelab import RecordAttachmentReplacement, RecordFilesAttachmentAppend, RecordValueUpdate
|
|
@@ -348,7 +350,9 @@ await client.records.update(
|
|
|
348
350
|
|
|
349
351
|
For a files occurrence, `caption=None` preserves the observed string caption (an observed null caption normalizes to
|
|
350
352
|
the required empty string). Table replacement requires exactly one current attachment in the selected cell and does
|
|
351
|
-
not accept a caption.
|
|
353
|
+
not accept a caption. Record reads likewise accept only one canonical attachment object or `null` in a table file cell;
|
|
354
|
+
an attachment array violates the pinned response contract. Both replacement forms require the replacement hash to
|
|
355
|
+
differ from the current occurrence.
|
|
352
356
|
|
|
353
357
|
All record attachment intents reject handles from another notebook or authenticated uploader, duplicate use within one
|
|
354
358
|
finalization request, and raw Provider attachment references. Row/index-based operations use an immediate SDK read and
|
|
@@ -425,8 +429,8 @@ and `deletePersonalLiteratureItem`.
|
|
|
425
429
|
|
|
426
430
|
Every other implemented operation is explicitly `experimental`; the exact per-operation list and its
|
|
427
431
|
PVD/PCG references live in
|
|
428
|
-
`docs/operation-coverage.yaml`. `
|
|
429
|
-
|
|
432
|
+
`docs/operation-coverage.yaml`. `readApplicationBootstrap` is intentionally unexposed because it returns the Provider
|
|
433
|
+
application environment and menu model, while SDK identity is sourced from token issuance. `readLiteratureCreateTemplate`
|
|
430
434
|
is intentionally unexposed because it returns a frontend form definition and an optional deployment flag rather than
|
|
431
435
|
a resource needed by the SDK interface. There are no `planned` operations. Experimental support means the SDK
|
|
432
436
|
validates and exposes the pinned Contract while preserving limitations such as unstable ordering/pagination,
|
|
@@ -500,9 +504,12 @@ await client.templates.save_content(template, modules)
|
|
|
500
504
|
`TemplateModule.data_present` distinguishes a missing `data` property from an explicit null value, while
|
|
501
505
|
`attributes` prevents additive canonical properties from being dropped during a read/save cycle. The SDK does not
|
|
502
506
|
synthesize frontend editor UIDs, layout widths, rows, folders, option encoding, or a fixed set of display module
|
|
503
|
-
types.
|
|
504
|
-
|
|
505
|
-
|
|
507
|
+
types. A JSON-language code module with style metadata may return its JSON string or explicit `null`; number and boolean
|
|
508
|
+
table cells preserve the Provider's empty string as distinct from scalar and `null` values. The Provider accepts some
|
|
509
|
+
non-canonical module roots and arbitrary table file arrays, but the SDK does not expose that behavior: saved content
|
|
510
|
+
must remain a canonical module list, and a table file cell must be one canonical attachment object or `null` (PVD-046).
|
|
511
|
+
The Provider supports only whole-content replacement and has no atomic patch or compare-and-swap operation (PCG-007),
|
|
512
|
+
so a read-modify-save sequence can overwrite a concurrent change.
|
|
506
513
|
|
|
507
514
|
The market result retains the Provider's `total_count` and derives `has_more` without echoing the caller's page
|
|
508
515
|
arguments; it does not claim a stable order or continuation token. Template reads remain experimental
|
|
@@ -613,8 +620,9 @@ returns the acknowledgement classification
|
|
|
613
620
|
issue a post-write read. Database, active-browser, and unclassified acknowledgements remain distinct, and mutation
|
|
614
621
|
retries stay disabled. Encrypted record content is outside the SDK's public read/update interface: the list-level
|
|
615
622
|
`RecordSummary.encrypted` flag lets callers identify and skip it, while the Provider password field and frontend-only
|
|
616
|
-
password lifecycle remain unexposed. Files-module attachment append
|
|
617
|
-
|
|
623
|
+
password lifecycle remain unexposed. Files-module attachment append remains root-only because the pinned top-level
|
|
624
|
+
update request schema does not admit the dedicated staged-name append shape's folder `path`; malformed path containers
|
|
625
|
+
may also silently append at root according to PVD-044. A staged attachment is indeterminate once the write has started.
|
|
618
626
|
|
|
619
627
|
Relation addition reads both endpoints and checks their resolved data server before writing; this reduces PVD-019
|
|
620
628
|
risk but is not an atomic Provider authorization guarantee. It does not list relations merely to inspect the
|
|
@@ -912,6 +920,6 @@ uv run python scripts/check_release.py dist/release/*.whl dist/release/*.tar.gz
|
|
|
912
920
|
```
|
|
913
921
|
|
|
914
922
|
Rebuilding the same commit with the same locked environment and `SOURCE_DATE_EPOCH` must produce
|
|
915
|
-
byte-identical wheel and source distribution hashes. The release is bound to
|
|
916
|
-
|
|
917
|
-
`
|
|
923
|
+
byte-identical wheel and source distribution hashes. The release is bound to immutable `matelab-spec v0.4.5`, commit
|
|
924
|
+
`6afac7ff151680130e6e4bc6d95782589b97f4e7`, and OpenAPI SHA-256
|
|
925
|
+
`31a8d03b4366e2345dfccdbbaaaccf6754b2711428afa4295d778d121988460d`.
|
|
@@ -7,10 +7,10 @@ This README describes the current SDK interface, integration semantics, examples
|
|
|
7
7
|
[AGENTS.md](AGENTS.md) for durable maintenance rules, and `docs/operation-coverage.yaml` for the machine-readable
|
|
8
8
|
operation inventory.
|
|
9
9
|
|
|
10
|
-
The current alpha is `0.1.
|
|
10
|
+
The current alpha is `0.1.0a22`. `[project].version` in `pyproject.toml` is the sole SDK version source;
|
|
11
11
|
`uv.lock` only mirrors that source.
|
|
12
12
|
|
|
13
|
-
The SDK is pinned to the
|
|
13
|
+
The SDK is pinned to the immutable `matelab-spec v0.4.5` Contract Release. The sole release pin is
|
|
14
14
|
`contracts/matelab-integration-v1.lock.json`, which records
|
|
15
15
|
the source tag, commit, OpenAPI path, local snapshot path, and SHA-256.
|
|
16
16
|
|
|
@@ -36,14 +36,14 @@ To test the same artifact a downstream Consumer will install, build and install
|
|
|
36
36
|
|
|
37
37
|
```bash
|
|
38
38
|
uv build --no-build-isolation --out-dir dist/release
|
|
39
|
-
python -m pip install dist/release/matelab_python_sdk-0.1.
|
|
39
|
+
python -m pip install dist/release/matelab_python_sdk-0.1.0a22-py3-none-any.whl
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
Do not infer Provider compatibility from the SDK version alone. A release is also bound to the Contract
|
|
43
43
|
tag, commit, and checksum recorded below.
|
|
44
44
|
|
|
45
45
|
The Contract and public SDK interface track the current reviewed Provider at
|
|
46
|
-
`
|
|
46
|
+
`59eb05b233e5ddd023a60ccb5e5c5f2ae22a70f0`. Provider limitations that remain relevant to integrations are documented
|
|
47
47
|
alongside the affected interfaces below.
|
|
48
48
|
|
|
49
49
|
## Design
|
|
@@ -93,7 +93,7 @@ success code it does not allow raises `MatelabProtocolError` rather than assigni
|
|
|
93
93
|
`MatelabTransportError.status_code` remains available for HTTP failures. Provider response bodies, top-level `msg`,
|
|
94
94
|
legacy `errmsg`, opaque `errs`, uncontracted debug fields, and request payloads are not attached to exceptions because
|
|
95
95
|
Provider-authored diagnostics may contain stack traces, credentials, or submitted values.
|
|
96
|
-
The pinned v0.4.
|
|
96
|
+
The pinned v0.4.5 Contract also declares optional code-4 `errs`, but PVD-041 and PCG-015 record opaque array/object
|
|
97
97
|
containers and insufficient evidence for requiredness, cardinality, or exclusion from other codes. The SDK
|
|
98
98
|
therefore keeps those diagnostics wire-only and does not expose `errs` as stable public metadata. A typed detail
|
|
99
99
|
interface remains blocked until a future Contract release can define one from stronger Provider evidence. `retryable`
|
|
@@ -288,8 +288,10 @@ supports one file column. A locally rejected target does not spend the handle; o
|
|
|
288
288
|
result cannot be retried through the same client.
|
|
289
289
|
|
|
290
290
|
Files-module append and table/files replacement use the general record attachment intents and may be combined with
|
|
291
|
-
other non-conflicting record changes. `RecordFilesAttachmentAppend` targets the module root
|
|
292
|
-
|
|
291
|
+
other non-conflicting record changes. `RecordFilesAttachmentAppend` currently targets the module root. Although
|
|
292
|
+
v0.4.5 records Provider evidence for safe folder paths, its top-level `UpdateRecordRequest.add[]` schema still excludes
|
|
293
|
+
the `path` property declared by the dedicated staged-name append shape; the SDK therefore does not expose folder paths
|
|
294
|
+
until that wire-schema conflict is resolved (PVD-044):
|
|
293
295
|
|
|
294
296
|
```python
|
|
295
297
|
from matelab import RecordAttachmentReplacement, RecordFilesAttachmentAppend, RecordValueUpdate
|
|
@@ -320,7 +322,9 @@ await client.records.update(
|
|
|
320
322
|
|
|
321
323
|
For a files occurrence, `caption=None` preserves the observed string caption (an observed null caption normalizes to
|
|
322
324
|
the required empty string). Table replacement requires exactly one current attachment in the selected cell and does
|
|
323
|
-
not accept a caption.
|
|
325
|
+
not accept a caption. Record reads likewise accept only one canonical attachment object or `null` in a table file cell;
|
|
326
|
+
an attachment array violates the pinned response contract. Both replacement forms require the replacement hash to
|
|
327
|
+
differ from the current occurrence.
|
|
324
328
|
|
|
325
329
|
All record attachment intents reject handles from another notebook or authenticated uploader, duplicate use within one
|
|
326
330
|
finalization request, and raw Provider attachment references. Row/index-based operations use an immediate SDK read and
|
|
@@ -397,8 +401,8 @@ and `deletePersonalLiteratureItem`.
|
|
|
397
401
|
|
|
398
402
|
Every other implemented operation is explicitly `experimental`; the exact per-operation list and its
|
|
399
403
|
PVD/PCG references live in
|
|
400
|
-
`docs/operation-coverage.yaml`. `
|
|
401
|
-
|
|
404
|
+
`docs/operation-coverage.yaml`. `readApplicationBootstrap` is intentionally unexposed because it returns the Provider
|
|
405
|
+
application environment and menu model, while SDK identity is sourced from token issuance. `readLiteratureCreateTemplate`
|
|
402
406
|
is intentionally unexposed because it returns a frontend form definition and an optional deployment flag rather than
|
|
403
407
|
a resource needed by the SDK interface. There are no `planned` operations. Experimental support means the SDK
|
|
404
408
|
validates and exposes the pinned Contract while preserving limitations such as unstable ordering/pagination,
|
|
@@ -472,9 +476,12 @@ await client.templates.save_content(template, modules)
|
|
|
472
476
|
`TemplateModule.data_present` distinguishes a missing `data` property from an explicit null value, while
|
|
473
477
|
`attributes` prevents additive canonical properties from being dropped during a read/save cycle. The SDK does not
|
|
474
478
|
synthesize frontend editor UIDs, layout widths, rows, folders, option encoding, or a fixed set of display module
|
|
475
|
-
types.
|
|
476
|
-
|
|
477
|
-
|
|
479
|
+
types. A JSON-language code module with style metadata may return its JSON string or explicit `null`; number and boolean
|
|
480
|
+
table cells preserve the Provider's empty string as distinct from scalar and `null` values. The Provider accepts some
|
|
481
|
+
non-canonical module roots and arbitrary table file arrays, but the SDK does not expose that behavior: saved content
|
|
482
|
+
must remain a canonical module list, and a table file cell must be one canonical attachment object or `null` (PVD-046).
|
|
483
|
+
The Provider supports only whole-content replacement and has no atomic patch or compare-and-swap operation (PCG-007),
|
|
484
|
+
so a read-modify-save sequence can overwrite a concurrent change.
|
|
478
485
|
|
|
479
486
|
The market result retains the Provider's `total_count` and derives `has_more` without echoing the caller's page
|
|
480
487
|
arguments; it does not claim a stable order or continuation token. Template reads remain experimental
|
|
@@ -585,8 +592,9 @@ returns the acknowledgement classification
|
|
|
585
592
|
issue a post-write read. Database, active-browser, and unclassified acknowledgements remain distinct, and mutation
|
|
586
593
|
retries stay disabled. Encrypted record content is outside the SDK's public read/update interface: the list-level
|
|
587
594
|
`RecordSummary.encrypted` flag lets callers identify and skip it, while the Provider password field and frontend-only
|
|
588
|
-
password lifecycle remain unexposed. Files-module attachment append
|
|
589
|
-
|
|
595
|
+
password lifecycle remain unexposed. Files-module attachment append remains root-only because the pinned top-level
|
|
596
|
+
update request schema does not admit the dedicated staged-name append shape's folder `path`; malformed path containers
|
|
597
|
+
may also silently append at root according to PVD-044. A staged attachment is indeterminate once the write has started.
|
|
590
598
|
|
|
591
599
|
Relation addition reads both endpoints and checks their resolved data server before writing; this reduces PVD-019
|
|
592
600
|
risk but is not an atomic Provider authorization guarantee. It does not list relations merely to inspect the
|
|
@@ -884,6 +892,6 @@ uv run python scripts/check_release.py dist/release/*.whl dist/release/*.tar.gz
|
|
|
884
892
|
```
|
|
885
893
|
|
|
886
894
|
Rebuilding the same commit with the same locked environment and `SOURCE_DATE_EPOCH` must produce
|
|
887
|
-
byte-identical wheel and source distribution hashes. The release is bound to
|
|
888
|
-
|
|
889
|
-
`
|
|
895
|
+
byte-identical wheel and source distribution hashes. The release is bound to immutable `matelab-spec v0.4.5`, commit
|
|
896
|
+
`6afac7ff151680130e6e4bc6d95782589b97f4e7`, and OpenAPI SHA-256
|
|
897
|
+
`31a8d03b4366e2345dfccdbbaaaccf6754b2711428afa4295d778d121988460d`.
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
"schema_version": 1,
|
|
3
3
|
"contract_line": "integration-v1",
|
|
4
4
|
"release": {
|
|
5
|
-
"tag": "v0.4.
|
|
6
|
-
"commit": "
|
|
5
|
+
"tag": "v0.4.5",
|
|
6
|
+
"commit": "6afac7ff151680130e6e4bc6d95782589b97f4e7"
|
|
7
7
|
},
|
|
8
8
|
"openapi": {
|
|
9
9
|
"source_path": "openapi/matelab-integration-v1.openapi.yaml",
|
|
10
10
|
"snapshot": "matelab-integration-v1.openapi.yaml",
|
|
11
|
-
"sha256": "
|
|
11
|
+
"sha256": "31a8d03b4366e2345dfccdbbaaaccf6754b2711428afa4295d778d121988460d"
|
|
12
12
|
}
|
|
13
13
|
}
|