kraph 1.0.0__tar.gz → 3.0.0__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 (32) hide show
  1. {kraph-1.0.0 → kraph-3.0.0}/PKG-INFO +3 -2
  2. kraph-3.0.0/kraph/__init__.py +18 -0
  3. {kraph-1.0.0 → kraph-3.0.0}/kraph/api/project.json +14 -38
  4. {kraph-1.0.0 → kraph-3.0.0}/kraph/api/schema.graphql +1858 -386
  5. kraph-3.0.0/kraph/api/schema.py +14255 -0
  6. kraph-3.0.0/kraph/arkitekt.py +237 -0
  7. kraph-3.0.0/kraph/client.py +41 -0
  8. {kraph-1.0.0 → kraph-3.0.0}/kraph/datalayer.py +19 -3
  9. {kraph-1.0.0 → kraph-3.0.0}/kraph/errors.py +1 -1
  10. {kraph-1.0.0 → kraph-3.0.0}/kraph/io.py +9 -8
  11. kraph-3.0.0/kraph/kraph.py +123 -0
  12. {kraph-1.0.0 → kraph-3.0.0}/kraph/rath.py +5 -8
  13. {kraph-1.0.0 → kraph-3.0.0}/kraph/refs.py +16 -7
  14. {kraph-1.0.0 → kraph-3.0.0}/kraph/traits.py +27 -15
  15. {kraph-1.0.0 → kraph-3.0.0}/pyproject.toml +3 -2
  16. kraph-1.0.0/kraph/__init__.py +0 -23
  17. kraph-1.0.0/kraph/api/schema.py +0 -13848
  18. kraph-1.0.0/kraph/arkitekt.py +0 -96
  19. kraph-1.0.0/kraph/contrib/fakts/datalayer.py +0 -40
  20. kraph-1.0.0/kraph/funcs.py +0 -75
  21. kraph-1.0.0/kraph/kraph.py +0 -9
  22. kraph-1.0.0/kraph/rekuest.py +0 -98
  23. kraph-1.0.0/kraph/vars.py +0 -17
  24. {kraph-1.0.0 → kraph-3.0.0}/.gitignore +0 -0
  25. {kraph-1.0.0 → kraph-3.0.0}/README.md +0 -0
  26. {kraph-1.0.0 → kraph-3.0.0}/kraph/api/__init__.py +0 -0
  27. {kraph-1.0.0 → kraph-3.0.0}/kraph/contrib/fakts/__init__.py +0 -0
  28. {kraph-1.0.0 → kraph-3.0.0}/kraph/links/__init__.py +0 -0
  29. {kraph-1.0.0 → kraph-3.0.0}/kraph/links/errors.py +0 -0
  30. {kraph-1.0.0 → kraph-3.0.0}/kraph/links/upload.py +0 -0
  31. {kraph-1.0.0 → kraph-3.0.0}/kraph/py.typed +0 -0
  32. {kraph-1.0.0 → kraph-3.0.0}/kraph/scalars.py +0 -0
@@ -1,12 +1,13 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: kraph
3
- Version: 1.0.0
3
+ Version: 3.0.0
4
4
  Summary: the arkitekt knowledge graph
5
5
  Author-email: jhnnsrs <jhnnsrs@gmail.com>
6
6
  License-Expression: GPL-3.0-or-later
7
7
  Requires-Python: <4.0,>=3.11
8
8
  Requires-Dist: dokker>=2.3
9
- Requires-Dist: rath>=3.5
9
+ Requires-Dist: rath>=4
10
+ Requires-Dist: rekuest>=4
10
11
  Requires-Dist: websockets>=15.0.1
11
12
  Description-Content-Type: text/markdown
12
13
 
@@ -0,0 +1,18 @@
1
+ from .kraph import Kraph
2
+
3
+
4
+ try:
5
+ from .arkitekt import kraph as kraph_service
6
+ except ImportError as e:
7
+ # Only "rekuest is not installed" may pass silently. Anything else that fails
8
+ # to import here (a renamed query, a rekuest too old for what the module
9
+ # needs) is a bug, and hiding it makes this package's service vanish
10
+ # without a word. Whether it is installed is asked the plain way.
11
+ try:
12
+ import rekuest # noqa: F401 -- presence is the question
13
+ except ImportError:
14
+ pass
15
+ else:
16
+ raise e
17
+
18
+ __all__ = ["Kraph", "kraph_service"]
@@ -66,6 +66,7 @@
66
66
  "skip_forwards": false,
67
67
  "min_python_version": "3.10",
68
68
  "type_annotation_style": "auto",
69
+ "external_modules": [],
69
70
  "additional_bases": {
70
71
  "Graph": [
71
72
  "kraph.traits.GraphTrait"
@@ -198,7 +199,18 @@
198
199
  "type": "turms.plugins.operations.OperationsPlugin"
199
200
  },
200
201
  {
201
- "type": "turms.plugins.funcs.FuncsPlugin",
202
+ "type": "turms.plugins.client.ClientPlugin",
203
+ "client_class": "KraphApi",
204
+ "global_kwargs": [
205
+ {
206
+ "key": "task",
207
+ "type": "rath.task.TaskLike",
208
+ "description": "The task this call is made for; the ambient one by default."
209
+ }
210
+ ],
211
+ "reserved_from": [
212
+ "kraph.kraph.Kraph"
213
+ ],
202
214
  "coercible_scalars": {
203
215
  "ID": "rath.scalars.IDCoercible",
204
216
  "CypherLiteral": "kraph.scalars.CypherLiteralCoercible",
@@ -207,42 +219,6 @@
207
219
  },
208
220
  "expand_input_types": [
209
221
  "input"
210
- ],
211
- "global_kwargs": [
212
- {
213
- "type": "kraph.rath.KraphRath",
214
- "key": "rath",
215
- "description": "The mikro rath client"
216
- }
217
- ],
218
- "definitions": [
219
- {
220
- "type": "subscription",
221
- "is_async": true,
222
- "use": "kraph.funcs.asubscribe"
223
- },
224
- {
225
- "type": "query",
226
- "is_async": true,
227
- "use": "kraph.funcs.aexecute"
228
- },
229
- {
230
- "type": "mutation",
231
- "is_async": true,
232
- "use": "kraph.funcs.aexecute"
233
- },
234
- {
235
- "type": "subscription",
236
- "use": "kraph.funcs.subscribe"
237
- },
238
- {
239
- "type": "query",
240
- "use": "kraph.funcs.execute"
241
- },
242
- {
243
- "type": "mutation",
244
- "use": "kraph.funcs.execute"
245
- }
246
222
  ]
247
223
  }
248
224
  ],
@@ -262,4 +238,4 @@
262
238
  ]
263
239
  }
264
240
  }
265
- }
241
+ }