loams 0.1.0a2__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.
Files changed (110) hide show
  1. loams-0.1.0a2/.gitignore +76 -0
  2. loams-0.1.0a2/LICENSE +202 -0
  3. loams-0.1.0a2/PKG-INFO +123 -0
  4. loams-0.1.0a2/README.md +90 -0
  5. loams-0.1.0a2/pyproject.toml +108 -0
  6. loams-0.1.0a2/src/loams/__init__.py +88 -0
  7. loams-0.1.0a2/src/loams/_gen/facade.py +2911 -0
  8. loams-0.1.0a2/src/loams/admin/v1/__init__.py +7 -0
  9. loams-0.1.0a2/src/loams/admin/v1/__init__.pyi +0 -0
  10. loams-0.1.0a2/src/loams/admin/v1/agent_connect.py +1043 -0
  11. loams-0.1.0a2/src/loams/admin/v1/agent_pb2.py +124 -0
  12. loams-0.1.0a2/src/loams/admin/v1/agent_pb2.pyi +324 -0
  13. loams-0.1.0a2/src/loams/admin/v1/audit_connect.py +310 -0
  14. loams-0.1.0a2/src/loams/admin/v1/audit_pb2.py +61 -0
  15. loams-0.1.0a2/src/loams/admin/v1/audit_pb2.pyi +102 -0
  16. loams-0.1.0a2/src/loams/admin/v1/common_pb2.py +47 -0
  17. loams-0.1.0a2/src/loams/admin/v1/common_pb2.pyi +87 -0
  18. loams-0.1.0a2/src/loams/admin/v1/key_connect.py +480 -0
  19. loams-0.1.0a2/src/loams/admin/v1/key_pb2.py +67 -0
  20. loams-0.1.0a2/src/loams/admin/v1/key_pb2.pyi +100 -0
  21. loams-0.1.0a2/src/loams/admin/v1/org_connect.py +954 -0
  22. loams-0.1.0a2/src/loams/admin/v1/org_pb2.py +112 -0
  23. loams-0.1.0a2/src/loams/admin/v1/org_pb2.pyi +227 -0
  24. loams-0.1.0a2/src/loams/admin/v1/project_connect.py +889 -0
  25. loams-0.1.0a2/src/loams/admin/v1/project_pb2.py +105 -0
  26. loams-0.1.0a2/src/loams/admin/v1/project_pb2.pyi +240 -0
  27. loams-0.1.0a2/src/loams/aio.py +260 -0
  28. loams-0.1.0a2/src/loams/approvals/v1/__init__.py +7 -0
  29. loams-0.1.0a2/src/loams/approvals/v1/__init__.pyi +0 -0
  30. loams-0.1.0a2/src/loams/approvals/v1/approvals_connect.py +424 -0
  31. loams-0.1.0a2/src/loams/approvals/v1/approvals_pb2.py +82 -0
  32. loams-0.1.0a2/src/loams/approvals/v1/approvals_pb2.pyi +235 -0
  33. loams-0.1.0a2/src/loams/auth/v1/__init__.py +7 -0
  34. loams-0.1.0a2/src/loams/auth/v1/__init__.pyi +0 -0
  35. loams-0.1.0a2/src/loams/auth/v1/auth_connect.py +638 -0
  36. loams-0.1.0a2/src/loams/auth/v1/auth_pb2.py +86 -0
  37. loams-0.1.0a2/src/loams/auth/v1/auth_pb2.pyi +162 -0
  38. loams-0.1.0a2/src/loams/devices/v1/__init__.py +7 -0
  39. loams-0.1.0a2/src/loams/devices/v1/__init__.pyi +0 -0
  40. loams-0.1.0a2/src/loams/devices/v1/devices_connect.py +801 -0
  41. loams-0.1.0a2/src/loams/devices/v1/devices_pb2.py +95 -0
  42. loams-0.1.0a2/src/loams/devices/v1/devices_pb2.pyi +263 -0
  43. loams-0.1.0a2/src/loams/errors/v1/__init__.py +7 -0
  44. loams-0.1.0a2/src/loams/errors/v1/__init__.pyi +0 -0
  45. loams-0.1.0a2/src/loams/errors/v1/errors_pb2.py +40 -0
  46. loams-0.1.0a2/src/loams/errors/v1/errors_pb2.pyi +24 -0
  47. loams-0.1.0a2/src/loams/instance/v1/__init__.py +7 -0
  48. loams-0.1.0a2/src/loams/instance/v1/__init__.pyi +0 -0
  49. loams-0.1.0a2/src/loams/instance/v1/instance_connect.py +302 -0
  50. loams-0.1.0a2/src/loams/instance/v1/instance_pb2.py +84 -0
  51. loams-0.1.0a2/src/loams/instance/v1/instance_pb2.pyi +204 -0
  52. loams-0.1.0a2/src/loams/live/v1/__init__.py +7 -0
  53. loams-0.1.0a2/src/loams/live/v1/__init__.pyi +0 -0
  54. loams-0.1.0a2/src/loams/live/v1/admin_connect.py +630 -0
  55. loams-0.1.0a2/src/loams/live/v1/admin_pb2.py +96 -0
  56. loams-0.1.0a2/src/loams/live/v1/admin_pb2.pyi +251 -0
  57. loams-0.1.0a2/src/loams/live/v1/catalog_pb2.py +52 -0
  58. loams-0.1.0a2/src/loams/live/v1/catalog_pb2.pyi +125 -0
  59. loams-0.1.0a2/src/loams/live/v1/idempotency_pb2.py +37 -0
  60. loams-0.1.0a2/src/loams/live/v1/idempotency_pb2.pyi +23 -0
  61. loams-0.1.0a2/src/loams/live/v1/journal_pb2.py +44 -0
  62. loams-0.1.0a2/src/loams/live/v1/journal_pb2.pyi +72 -0
  63. loams-0.1.0a2/src/loams/live/v1/live_connect.py +492 -0
  64. loams-0.1.0a2/src/loams/live/v1/live_pb2.py +100 -0
  65. loams-0.1.0a2/src/loams/live/v1/live_pb2.pyi +257 -0
  66. loams-0.1.0a2/src/loams/live/v1/value_pb2.py +52 -0
  67. loams-0.1.0a2/src/loams/live/v1/value_pb2.pyi +67 -0
  68. loams-0.1.0a2/src/loams/loams.py +334 -0
  69. loams-0.1.0a2/src/loams/notifications/v1/__init__.py +7 -0
  70. loams-0.1.0a2/src/loams/notifications/v1/__init__.pyi +0 -0
  71. loams-0.1.0a2/src/loams/notifications/v1/notifications_connect.py +355 -0
  72. loams-0.1.0a2/src/loams/notifications/v1/notifications_pb2.py +58 -0
  73. loams-0.1.0a2/src/loams/notifications/v1/notifications_pb2.pyi +107 -0
  74. loams-0.1.0a2/src/loams/operations/v1/__init__.py +7 -0
  75. loams-0.1.0a2/src/loams/operations/v1/__init__.pyi +0 -0
  76. loams-0.1.0a2/src/loams/operations/v1/operations_connect.py +420 -0
  77. loams-0.1.0a2/src/loams/operations/v1/operations_pb2.py +74 -0
  78. loams-0.1.0a2/src/loams/operations/v1/operations_pb2.pyi +164 -0
  79. loams-0.1.0a2/src/loams/options/v1/__init__.py +7 -0
  80. loams-0.1.0a2/src/loams/options/v1/__init__.pyi +0 -0
  81. loams-0.1.0a2/src/loams/options/v1/options_pb2.py +39 -0
  82. loams-0.1.0a2/src/loams/options/v1/options_pb2.pyi +32 -0
  83. loams-0.1.0a2/src/loams/runtime/call.py +617 -0
  84. loams-0.1.0a2/src/loams/runtime/consistency.py +87 -0
  85. loams-0.1.0a2/src/loams/runtime/errors.py +317 -0
  86. loams-0.1.0a2/src/loams/runtime/options.py +113 -0
  87. loams-0.1.0a2/src/loams/runtime/pagination.py +113 -0
  88. loams-0.1.0a2/src/loams/runtime/retry.py +86 -0
  89. loams-0.1.0a2/src/loams/runtime/streams.py +206 -0
  90. loams-0.1.0a2/src/loams/runtime/token_source.py +394 -0
  91. loams-0.1.0a2/src/loams/runtime/transports.py +159 -0
  92. loams-0.1.0a2/src/loams/runtime/uuidv7.py +102 -0
  93. loams-0.1.0a2/src/loams/system.py +320 -0
  94. loams-0.1.0a2/tests/conftest.py +85 -0
  95. loams-0.1.0a2/tests/test_async.py +259 -0
  96. loams-0.1.0a2/tests/test_backoff.py +245 -0
  97. loams-0.1.0a2/tests/test_call_path.py +273 -0
  98. loams-0.1.0a2/tests/test_client.py +311 -0
  99. loams-0.1.0a2/tests/test_conformance.py +79 -0
  100. loams-0.1.0a2/tests/test_conformance_corpus.py +401 -0
  101. loams-0.1.0a2/tests/test_consistency.py +192 -0
  102. loams-0.1.0a2/tests/test_error_reason.py +234 -0
  103. loams-0.1.0a2/tests/test_oidc.py +340 -0
  104. loams-0.1.0a2/tests/test_pagination.py +237 -0
  105. loams-0.1.0a2/tests/test_retry_idempotency.py +321 -0
  106. loams-0.1.0a2/tests/test_streams.py +882 -0
  107. loams-0.1.0a2/tests/test_system.py +252 -0
  108. loams-0.1.0a2/tests/test_token_source.py +428 -0
  109. loams-0.1.0a2/tests/test_transports.py +164 -0
  110. loams-0.1.0a2/tools/bootstrap_facade.py +759 -0
@@ -0,0 +1,76 @@
1
+ # Rust
2
+ /target/
3
+ **/target/
4
+ *.rs.bk
5
+ *.pdb
6
+
7
+ # Loams local dev data
8
+ /.loams/
9
+ /data/
10
+ *.wal
11
+ *.seg
12
+
13
+ # Local run artifacts (dev/CLI scratch output, never committed)
14
+ /run.history
15
+ /run.ndjson
16
+ *.log
17
+ /cargo-metadata.json
18
+
19
+ # Product/marketing docs live in the private dina-kar/loam-cloud repo
20
+ /docs/product/
21
+
22
+ # Python
23
+ __pycache__/
24
+ *.pyc
25
+ *.pyo
26
+ *.pyd
27
+ .pytest_cache/
28
+
29
+ # Editors / OS / Backups
30
+ .idea/
31
+ .vscode/
32
+ *.swp
33
+ *.swo
34
+ *~
35
+ *.bak
36
+ *.orig
37
+ *.rej
38
+ .DS_Store
39
+ Thumbs.db
40
+ *.swiftdeps~
41
+
42
+ # AI tooling and local assistant state
43
+ .claude/
44
+ .superpowers/
45
+
46
+ # Env
47
+ .env
48
+ .env.*
49
+ !.env.example
50
+
51
+ # Node / Nx
52
+ node_modules/
53
+ .nx/
54
+ .pnpm-store/
55
+ *.tsbuildinfo
56
+
57
+ # Local linked worktrees are never part of the monorepo import
58
+ /.worktrees/
59
+
60
+ # What a conformance suite reports it ran (D640). Generated, never committed:
61
+ # a committed report is a claim about the corpus that a later corpus or a
62
+ # failing suite invalidates without touching the file, and `check-languages.mjs`
63
+ # would then read the previous run's answer and call it coverage. The suite
64
+ # writes one when it runs and CI generate-then-checks.
65
+ sdks/fixtures/results/
66
+
67
+ # Language SDK build outputs
68
+ .dart_tool/
69
+ .build/
70
+ vendor/
71
+ .phpunit.result.cache
72
+
73
+
74
+ # SQ1 Task 1 spike measurements and throwaway files
75
+ /target-spike/
76
+ /scratch/
loams-0.1.0a2/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
loams-0.1.0a2/PKG-INFO ADDED
@@ -0,0 +1,123 @@
1
+ Metadata-Version: 2.5
2
+ Name: loams
3
+ Version: 0.1.0a2
4
+ Summary: The Loams SDK for Python: one Loams object with namespaced modules over the unified Connect API, generated from proto/.
5
+ Project-URL: Homepage, https://loams.dev
6
+ Project-URL: Repository, https://github.com/ostrium-labs/loams
7
+ Project-URL: Issues, https://github.com/ostrium-labs/loams/issues
8
+ Project-URL: SDK plan, https://github.com/ostrium-labs/loams/blob/dev/docs/plans/2026-10-02-sdk2-languages.md
9
+ Author: Ostrium Labs
10
+ License-Expression: Apache-2.0
11
+ License-File: LICENSE
12
+ Keywords: connect,database,grpc,loams,sdk,vector
13
+ Classifier: Development Status :: 3 - Alpha
14
+ Classifier: Intended Audience :: Developers
15
+ Classifier: Programming Language :: Python :: 3
16
+ Classifier: Programming Language :: Python :: 3 :: Only
17
+ Classifier: Programming Language :: Python :: 3.10
18
+ Classifier: Programming Language :: Python :: 3.11
19
+ Classifier: Programming Language :: Python :: 3.12
20
+ Classifier: Programming Language :: Python :: 3.13
21
+ Classifier: Programming Language :: Python :: 3.14
22
+ Classifier: Typing :: Typed
23
+ Requires-Python: >=3.10
24
+ Requires-Dist: connectrpc==0.12.1
25
+ Requires-Dist: protobuf==7.36.2
26
+ Provides-Extra: arrow
27
+ Requires-Dist: pyarrow>=17.0.0; extra == 'arrow'
28
+ Provides-Extra: flight
29
+ Requires-Dist: adbc-driver-flightsql>=1.0.0; extra == 'flight'
30
+ Provides-Extra: polars
31
+ Requires-Dist: polars>=1.0.0; extra == 'polars'
32
+ Description-Content-Type: text/markdown
33
+
34
+ ![Loams — Your data. Your bucket.](https://raw.githubusercontent.com/ostrium-labs/loams/dev/docs/assets/loams-banner.svg)
35
+
36
+ # Loams SDK for Python
37
+
38
+ > **Preview.** `0.1.0a*` releases track the Loams preview server and may change
39
+ > between previews. pip skips prereleases unless asked: `pip install --pre loams`,
40
+ > or pin the exact version (`loams==0.1.0a2`).
41
+
42
+ One `Loams` object over one Loams instance, speaking the unified Connect API.
43
+ The module surface is generated from `proto/` by `scripts/sdk/gen.sh python`;
44
+ the runtime below it is hand-written and obeys the contract in
45
+ [`docs/sdk/runtime-contract.md`](https://github.com/ostrium-labs/loams/blob/dev/docs/sdk/runtime-contract.md).
46
+
47
+ ## Install
48
+
49
+ ```
50
+ pip install loams
51
+ ```
52
+
53
+ Not on PyPI yet. The distribution name is reserved but publishing is blocked
54
+ until registry ownership is confirmed (D400), so for now install from a
55
+ checkout:
56
+
57
+ ```
58
+ uv sync --all-extras --dev # from sdks/python
59
+ ```
60
+
61
+ The runtime dependency is [`connectrpc`](https://pypi.org/project/connectrpc/)
62
+ 0.12.1 (connectrpc/connect-py), pinned in `scripts/sdk/pins.lock`. Up to 0.9.0
63
+ the same project was published as `connect-python`; the import name has always
64
+ been `connectrpc`.
65
+
66
+ ## Use
67
+
68
+ ```python
69
+ from loams import Loams
70
+
71
+ loams = Loams("https://acme.loams.dev", api_key="...")
72
+ print(loams.instance.version())
73
+ ```
74
+
75
+ Four modules hang off the client: `loams.instance` (what this instance is),
76
+ `loams.live` (the live-sync session half, whose package is `unstable`),
77
+ `loams.tables` (the table half of the same service), and `loams.system` (the
78
+ module catalogue, feature detection and the version check).
79
+
80
+ ### Auth
81
+
82
+ Pass `api_key` for a script or CI job that holds one — it does not expire, so
83
+ there is nothing to refresh. Pass `auth` for everything else: `env_token()`,
84
+ `oidc_exchange()`, or your own `TokenSource`. The two are mutually exclusive
85
+ because they answer the same question, and passing both raises.
86
+
87
+ ### Protocol and encoding
88
+
89
+ `protocol` is `"connect"` (default), `"grpc"` or `"grpc-web"` — the one port
90
+ speaks all three; this picks which one this client uses. `proto_json=True`
91
+ sends the proto3 JSON mapping that `curl` sends; the default is protobuf,
92
+ which is smaller.
93
+
94
+ ### Consistency
95
+
96
+ `session_consistency=False` by default: every read is then `STRONG` on its own,
97
+ which is correct but does not give read-your-writes across processes. Turn it
98
+ on (D609) to hold a session consistency token across calls.
99
+
100
+ ## What is not here yet
101
+
102
+ These are refused by name rather than stubbed, so a caller finds out at the
103
+ call instead of at runtime:
104
+
105
+ - **The hybrid query builder.** Blocked on API1 Task 2. There is no
106
+ hand-written builder here; when the proto lands, the generator emits one.
107
+ - **Bulk ingest and bulk results.** Blocked on API1 Tasks 3 and 4. They go over
108
+ Arrow Flight SQL through ADBC, which is why the `flight`, `arrow` and
109
+ `polars` extras already exist — the code that uses them lands with the write
110
+ RPCs.
111
+ - **`listAll` per call.** Blocked on the same API1 tasks; paging is explicit.
112
+
113
+ ## Development
114
+
115
+ ```
116
+ uv sync --all-extras --dev
117
+ uv run pytest -q
118
+ uv run mypy --strict src
119
+ ./scripts/sdk/gen.sh python # regenerate the facade from proto/
120
+ ```
121
+
122
+ Generated code is never hand-edited: CI regenerates and fails on a diff, so a
123
+ proto change shows up as a dependency bump rather than a silent drift.
@@ -0,0 +1,90 @@
1
+ ![Loams — Your data. Your bucket.](https://raw.githubusercontent.com/ostrium-labs/loams/dev/docs/assets/loams-banner.svg)
2
+
3
+ # Loams SDK for Python
4
+
5
+ > **Preview.** `0.1.0a*` releases track the Loams preview server and may change
6
+ > between previews. pip skips prereleases unless asked: `pip install --pre loams`,
7
+ > or pin the exact version (`loams==0.1.0a2`).
8
+
9
+ One `Loams` object over one Loams instance, speaking the unified Connect API.
10
+ The module surface is generated from `proto/` by `scripts/sdk/gen.sh python`;
11
+ the runtime below it is hand-written and obeys the contract in
12
+ [`docs/sdk/runtime-contract.md`](https://github.com/ostrium-labs/loams/blob/dev/docs/sdk/runtime-contract.md).
13
+
14
+ ## Install
15
+
16
+ ```
17
+ pip install loams
18
+ ```
19
+
20
+ Not on PyPI yet. The distribution name is reserved but publishing is blocked
21
+ until registry ownership is confirmed (D400), so for now install from a
22
+ checkout:
23
+
24
+ ```
25
+ uv sync --all-extras --dev # from sdks/python
26
+ ```
27
+
28
+ The runtime dependency is [`connectrpc`](https://pypi.org/project/connectrpc/)
29
+ 0.12.1 (connectrpc/connect-py), pinned in `scripts/sdk/pins.lock`. Up to 0.9.0
30
+ the same project was published as `connect-python`; the import name has always
31
+ been `connectrpc`.
32
+
33
+ ## Use
34
+
35
+ ```python
36
+ from loams import Loams
37
+
38
+ loams = Loams("https://acme.loams.dev", api_key="...")
39
+ print(loams.instance.version())
40
+ ```
41
+
42
+ Four modules hang off the client: `loams.instance` (what this instance is),
43
+ `loams.live` (the live-sync session half, whose package is `unstable`),
44
+ `loams.tables` (the table half of the same service), and `loams.system` (the
45
+ module catalogue, feature detection and the version check).
46
+
47
+ ### Auth
48
+
49
+ Pass `api_key` for a script or CI job that holds one — it does not expire, so
50
+ there is nothing to refresh. Pass `auth` for everything else: `env_token()`,
51
+ `oidc_exchange()`, or your own `TokenSource`. The two are mutually exclusive
52
+ because they answer the same question, and passing both raises.
53
+
54
+ ### Protocol and encoding
55
+
56
+ `protocol` is `"connect"` (default), `"grpc"` or `"grpc-web"` — the one port
57
+ speaks all three; this picks which one this client uses. `proto_json=True`
58
+ sends the proto3 JSON mapping that `curl` sends; the default is protobuf,
59
+ which is smaller.
60
+
61
+ ### Consistency
62
+
63
+ `session_consistency=False` by default: every read is then `STRONG` on its own,
64
+ which is correct but does not give read-your-writes across processes. Turn it
65
+ on (D609) to hold a session consistency token across calls.
66
+
67
+ ## What is not here yet
68
+
69
+ These are refused by name rather than stubbed, so a caller finds out at the
70
+ call instead of at runtime:
71
+
72
+ - **The hybrid query builder.** Blocked on API1 Task 2. There is no
73
+ hand-written builder here; when the proto lands, the generator emits one.
74
+ - **Bulk ingest and bulk results.** Blocked on API1 Tasks 3 and 4. They go over
75
+ Arrow Flight SQL through ADBC, which is why the `flight`, `arrow` and
76
+ `polars` extras already exist — the code that uses them lands with the write
77
+ RPCs.
78
+ - **`listAll` per call.** Blocked on the same API1 tasks; paging is explicit.
79
+
80
+ ## Development
81
+
82
+ ```
83
+ uv sync --all-extras --dev
84
+ uv run pytest -q
85
+ uv run mypy --strict src
86
+ ./scripts/sdk/gen.sh python # regenerate the facade from proto/
87
+ ```
88
+
89
+ Generated code is never hand-edited: CI regenerates and fails on a diff, so a
90
+ proto change shows up as a dependency bump rather than a silent drift.
@@ -0,0 +1,108 @@
1
+ [build-system]
2
+ requires = ["hatchling>=1.27.0"]
3
+ build-backend = "hatchling.build"
4
+
5
+ [project]
6
+ name = "loams"
7
+ version = "0.1.0a2"
8
+ description = "The Loams SDK for Python: one Loams object with namespaced modules over the unified Connect API, generated from proto/."
9
+ readme = "README.md"
10
+ requires-python = ">=3.10"
11
+ license = "Apache-2.0"
12
+ license-files = ["LICENSE"]
13
+ authors = [{ name = "Ostrium Labs" }]
14
+ keywords = ["loams", "connect", "grpc", "sdk", "vector", "database"]
15
+ classifiers = [
16
+ "Development Status :: 3 - Alpha",
17
+ "Intended Audience :: Developers",
18
+ "Programming Language :: Python :: 3",
19
+ "Programming Language :: Python :: 3.10",
20
+ "Programming Language :: Python :: 3.11",
21
+ "Programming Language :: Python :: 3.12",
22
+ "Programming Language :: Python :: 3.13",
23
+ "Programming Language :: Python :: 3.14",
24
+ "Programming Language :: Python :: 3 :: Only",
25
+ "Typing :: Typed",
26
+ ]
27
+ dependencies = [
28
+ "connectrpc==0.12.1",
29
+ "protobuf==7.36.2",
30
+ ]
31
+
32
+ [project.optional-dependencies]
33
+ # Design §44 §7.5: bulk ingest and bulk results go over Arrow Flight SQL through
34
+ # ADBC, so the extra pulls the driver. The extras are declared now and the code
35
+ # that uses them lands with the write RPCs (API1 Tasks 3 and 4); see README.md
36
+ # "What is not here yet".
37
+ flight = ["adbc-driver-flightsql>=1.0.0"]
38
+ arrow = ["pyarrow>=17.0.0"]
39
+ polars = ["polars>=1.0.0"]
40
+
41
+ [project.urls]
42
+ Homepage = "https://loams.dev"
43
+ Repository = "https://github.com/ostrium-labs/loams"
44
+ Issues = "https://github.com/ostrium-labs/loams/issues"
45
+ "SDK plan" = "https://github.com/ostrium-labs/loams/blob/dev/docs/plans/2026-10-02-sdk2-languages.md"
46
+
47
+ [dependency-groups]
48
+ dev = [
49
+ "mypy==1.18.2",
50
+ "pytest==9.0.3",
51
+ # 1.2.0 caps pytest at <9, so it cannot resolve alongside the bump above;
52
+ # 1.4.0 is the first release that accepts pytest 9.
53
+ "pytest-asyncio==1.4.0",
54
+ # The stubs are generated by protoc; grpcio-tools pins the protoc that CI uses
55
+ # so a regeneration is a dependency bump rather than whatever is on PATH.
56
+ "grpcio-tools==1.84.0",
57
+ # The generator behind `buf.build/connectrpc/py:v0.12.1` (scripts/sdk/pins.lock),
58
+ # pinned to the same release so the plugin can also be run locally.
59
+ "protoc-gen-connectrpc==0.12.1",
60
+ # Stubs for the protobuf runtime: mypy --strict rejects google.protobuf without
61
+ # them, and connectrpc returns protobuf messages from every generated stub.
62
+ "types-protobuf",
63
+ ]
64
+
65
+ [tool.hatch.build.targets.wheel]
66
+ packages = ["src/loams"]
67
+
68
+ [tool.hatch.build.targets.sdist]
69
+ include = ["src/loams", "tests", "tools", "README.md", "pyproject.toml"]
70
+
71
+ [tool.pytest.ini_options]
72
+ testpaths = ["tests"]
73
+ asyncio_mode = "strict"
74
+ asyncio_default_fixture_loop_scope = "function"
75
+ filterwarnings = ["error"]
76
+
77
+ [tool.mypy]
78
+ python_version = "3.10"
79
+ strict = true
80
+ files = ["src/loams", "tests", "examples", "tools"]
81
+ mypy_path = "src"
82
+
83
+ # The generated protobuf stubs are protoc's output verbatim. They carry no
84
+ # annotations of their own beyond the `.pyi` protoc ships alongside them, which
85
+ # is where the types come from; `disallow_untyped_defs` cannot apply to them
86
+ # because they have no defs to annotate. Excluding the directory keeps
87
+ # `--strict` honest about the code this SDK owns rather than silencing it.
88
+ [[tool.mypy.overrides]]
89
+ module = [
90
+ "loams.admin.*",
91
+ "loams.approvals.*",
92
+ "loams.auth.*",
93
+ "loams.devices.*",
94
+ "loams.errors.*",
95
+ "loams.instance.*",
96
+ "loams.live.*",
97
+ "loams.notifications.*",
98
+ "loams.operations.*",
99
+ "loams.options.*",
100
+ ]
101
+ ignore_errors = true
102
+
103
+ [tool.ruff]
104
+ line-length = 100
105
+ target-version = "py310"
106
+
107
+ [tool.ruff.lint]
108
+ select = ["E", "F", "I", "UP", "B", "SIM", "ANN", "RUF"]
@@ -0,0 +1,88 @@
1
+ """The Loams SDK for Python.
2
+
3
+ ``from loams import Loams`` is the SDK's front door, so this module re-exports
4
+ the clients and the token-source factories. Without it the package installs but
5
+ the documented imports fail: Python treats a directory with no ``__init__.py`` as
6
+ a namespace package, and a namespace package has none of these attributes.
7
+
8
+ The token sources are re-exported in matched sync and async pairs because every
9
+ one of them has an async twin, and picking the wrong one is a bug that only shows
10
+ up as a blocking call on the event loop -- ``aio.py`` had been importing the
11
+ sync ``api_key`` under the name ``async_api_key_source``.
12
+ """
13
+
14
+ from loams.aio import AsyncLoams
15
+ from loams.loams import Loams
16
+ from loams.runtime.errors import (
17
+ AbortedError,
18
+ AlreadyExistsError,
19
+ DeadlineExceededError,
20
+ FailedPreconditionError,
21
+ FeatureNotInVariantError,
22
+ InternalError,
23
+ InvalidArgumentError,
24
+ LoamsError,
25
+ NotFoundError,
26
+ PermissionDeniedError,
27
+ ResourceExhaustedError,
28
+ TokenExpiredError,
29
+ UnauthenticatedError,
30
+ UnavailableError,
31
+ UnimplementedError,
32
+ is_loams_error,
33
+ )
34
+ from loams.runtime.options import CallOptions, ConsistencyOptions
35
+ from loams.runtime.token_source import (
36
+ OidcExchangeOptions,
37
+ api_key,
38
+ async_api_key,
39
+ async_env_token,
40
+ async_oidc_exchange,
41
+ async_refreshing,
42
+ async_static_token,
43
+ env_token,
44
+ oidc_exchange,
45
+ refreshing,
46
+ static_token,
47
+ )
48
+
49
+ __all__ = [
50
+ # The per-call options, because every generated method takes
51
+ # `options: CallOptions | None` and there is no other way to set a deadline, a
52
+ # caller header or an idempotency key on one call. They were reachable only as
53
+ # `loams.runtime.options`, which reads as internal and carries no stability
54
+ # promise -- so the documented parameter was unusable from the public surface.
55
+ # `OidcExchangeOptions` was already exported, so options types are public here
56
+ # too; these two are the ones a call site actually needs.
57
+ "CallOptions",
58
+ "ConsistencyOptions",
59
+ "AbortedError",
60
+ "AlreadyExistsError",
61
+ "DeadlineExceededError",
62
+ "FailedPreconditionError",
63
+ "FeatureNotInVariantError",
64
+ "InternalError",
65
+ "InvalidArgumentError",
66
+ "LoamsError",
67
+ "NotFoundError",
68
+ "PermissionDeniedError",
69
+ "ResourceExhaustedError",
70
+ "TokenExpiredError",
71
+ "UnauthenticatedError",
72
+ "UnavailableError",
73
+ "UnimplementedError",
74
+ "is_loams_error",
75
+ "AsyncLoams",
76
+ "Loams",
77
+ "OidcExchangeOptions",
78
+ "api_key",
79
+ "async_api_key",
80
+ "async_env_token",
81
+ "async_oidc_exchange",
82
+ "async_refreshing",
83
+ "async_static_token",
84
+ "env_token",
85
+ "oidc_exchange",
86
+ "refreshing",
87
+ "static_token",
88
+ ]