pycrdt 0.12.41__cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl → 0.12.43__cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.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 pycrdt might be problematic. Click here for more details.

pycrdt/__init__.py CHANGED
@@ -1,3 +1,7 @@
1
+ from pkgutil import extend_path
2
+
3
+ __path__ = extend_path(__path__, __name__)
4
+
1
5
  from ._array import Array as Array
2
6
  from ._array import ArrayEvent as ArrayEvent
3
7
  from ._array import TypedArray as TypedArray
pycrdt/_doc.py CHANGED
@@ -2,7 +2,19 @@ from __future__ import annotations
2
2
 
3
3
  from functools import partial
4
4
  from inspect import iscoroutinefunction
5
- from typing import Any, Awaitable, Callable, Generic, Iterable, Literal, Type, TypeVar, Union, cast, overload
5
+ from typing import (
6
+ Any,
7
+ Awaitable,
8
+ Callable,
9
+ Generic,
10
+ Iterable,
11
+ Literal,
12
+ Type,
13
+ TypeVar,
14
+ Union,
15
+ cast,
16
+ overload,
17
+ )
6
18
 
7
19
  from anyio import BrokenResourceError, create_memory_object_stream
8
20
  from anyio.streams.memory import MemoryObjectReceiveStream, MemoryObjectSendStream
@@ -15,7 +27,9 @@ from ._snapshot import Snapshot
15
27
  from ._transaction import NewTransaction, ReadTransaction, Transaction
16
28
 
17
29
  T = TypeVar("T", bound=BaseType)
18
- TransactionOrSubdocsEvent = TypeVar("TransactionOrSubdocsEvent", bound=TransactionEvent | SubdocsEvent)
30
+ TransactionOrSubdocsEvent = TypeVar(
31
+ "TransactionOrSubdocsEvent", bound=TransactionEvent | SubdocsEvent
32
+ )
19
33
 
20
34
 
21
35
  class Doc(BaseDoc, Generic[T]):
@@ -47,7 +61,11 @@ class Doc(BaseDoc, Generic[T]):
47
61
  allow_multithreading: Whether to allow the document to be used in different threads.
48
62
  """
49
63
  super().__init__(
50
- client_id=client_id, skip_gc=skip_gc, doc=doc, Model=Model, allow_multithreading=allow_multithreading
64
+ client_id=client_id,
65
+ skip_gc=skip_gc,
66
+ doc=doc,
67
+ Model=Model,
68
+ allow_multithreading=allow_multithreading,
51
69
  )
52
70
  for k, v in init.items():
53
71
  self[k] = v
@@ -292,7 +310,8 @@ class Doc(BaseDoc, Generic[T]):
292
310
 
293
311
  def observe(
294
312
  self,
295
- callback: Callable[[TransactionEvent], None] | Callable[[TransactionEvent], Awaitable[None]],
313
+ callback: Callable[[TransactionEvent], None]
314
+ | Callable[[TransactionEvent], Awaitable[None]],
296
315
  ) -> Subscription:
297
316
  """
298
317
  Subscribes a callback to be called with the document change event.
@@ -405,7 +424,9 @@ class Doc(BaseDoc, Generic[T]):
405
424
  observe = self.observe_subdocs if subdocs else self.observe
406
425
  if not self._send_streams[subdocs]:
407
426
  if async_transactions:
408
- self._event_subscription[subdocs] = observe(partial(self._async_send_event, subdocs))
427
+ self._event_subscription[subdocs] = observe(
428
+ partial(self._async_send_event, subdocs)
429
+ )
409
430
  else:
410
431
  self._event_subscription[subdocs] = observe(partial(self._send_event, subdocs))
411
432
  send_stream, receive_stream = create_memory_object_stream[
pycrdt/_xml.py CHANGED
@@ -269,9 +269,7 @@ class XmlText(_XmlTraitMixin):
269
269
  self._do_and_integrate("insert", value, txn._txn, index, _attrs)
270
270
  else:
271
271
  # primitive type
272
- self.integrated.insert_embed(
273
- txn._txn, index, value, _attrs
274
- )
272
+ self.integrated.insert_embed(txn._txn, index, value, _attrs)
275
273
 
276
274
  def format(self, start: int, stop: int, attrs: dict[str, Any]) -> None:
277
275
  """
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pycrdt
3
- Version: 0.12.41
3
+ Version: 0.12.43
4
4
  Classifier: Development Status :: 4 - Beta
5
5
  Classifier: Intended Audience :: Developers
6
6
  Classifier: License :: OSI Approved :: MIT License
@@ -1,14 +1,14 @@
1
- pycrdt-0.12.41.dist-info/METADATA,sha256=WNyaOg8XClNq__xl6Jq7i1x97SjZqFf_caCjDfT_T0Q,1530
2
- pycrdt-0.12.41.dist-info/WHEEL,sha256=Zh2Nm9_KPw53ft3ii58WjPmMCU4Yjeq6NqKuwRR6qU4,131
3
- pycrdt-0.12.41.dist-info/licenses/LICENSE,sha256=Sesm0tdTWXYb_Om3U3LUusWWhxEyBNO19HXj8nLklfc,1081
4
- pycrdt/__init__.py,sha256=uGg4-TDp_XHh-RM17bWVk_V50Oh4n10MXTS91RLz3cw,2106
1
+ pycrdt-0.12.43.dist-info/METADATA,sha256=WjsPXYmdmXwkx11AXEfOfxugK-CamsyPc_kFk6SrGzY,1530
2
+ pycrdt-0.12.43.dist-info/WHEEL,sha256=Zh2Nm9_KPw53ft3ii58WjPmMCU4Yjeq6NqKuwRR6qU4,131
3
+ pycrdt-0.12.43.dist-info/licenses/LICENSE,sha256=Sesm0tdTWXYb_Om3U3LUusWWhxEyBNO19HXj8nLklfc,1081
4
+ pycrdt/__init__.py,sha256=iCcAXkPsXiSkeEuV_DuPVI5hJIy1IsxXIo9iTTQBs4w,2183
5
5
  pycrdt/_array.py,sha256=sWGBro3o279Cw1_EOTlEWFe51Ymo66Nt-gLPV2cY0p0,14614
6
6
  pycrdt/_awareness.py,sha256=1F8olK8EgF6ea2VzeDwHjnoy090cAYOjakwA4yLxWH0,10904
7
7
  pycrdt/_base.py,sha256=5BN2wVlyBWqq5j1CF0WEt3eakjirRziJ5SvcNAwdSWs,13073
8
- pycrdt/_doc.py,sha256=BQeYYTNmhNGiFrR_6EA54916xHmbGZqyUtDlW_edm88,16820
8
+ pycrdt/_doc.py,sha256=ZP0ICNo1XhWTmGNXWSquM_j3LIklil4vDZc4jcoFrAM,16970
9
9
  pycrdt/_map.py,sha256=N0rBhDfcMmzPfmzZyWP0lJdprGQhjg086-1OlApwEQw,10595
10
10
  pycrdt/_provider.py,sha256=RigUnf6S6AWuxxZ7I-oDZYZbjnBZYTMD0It7ADBxsSI,5295
11
- pycrdt/_pycrdt.cpython-312-aarch64-linux-gnu.so,sha256=q82ck5AlHnQNbrJuutNTrNU6lkgmbng166dNrV3tXV4,2605160
11
+ pycrdt/_pycrdt.cpython-312-aarch64-linux-gnu.so,sha256=ewEIlub1lKeTSWglXCiMntI9CnTgOlRwEvC-X0Enbhk,2589624
12
12
  pycrdt/_pycrdt.pyi,sha256=hSpWHqxWPRqn0OsMSaWO9v_4yUC48VZfn1V552u5E9A,16200
13
13
  pycrdt/_snapshot.py,sha256=3Yof2MsnKs4T3OlCnBJlxjuvduRViHbtLfN_m65FXqk,1366
14
14
  pycrdt/_sticky_index.py,sha256=3-KoFY3fCHTrQrHHtPJkDjTOCX3AGK9fnZNnOg0qqvE,4467
@@ -18,6 +18,6 @@ pycrdt/_transaction.py,sha256=Nemid8cwfSZqOSiYeCNSWL9Jfg_LgzE5vushb7JqftQ,5442
18
18
  pycrdt/_undo.py,sha256=NYvyngRDFtOnWpCS4M5AGwKNYXjgJQMl2fDsG8iZ6oU,4075
19
19
  pycrdt/_update.py,sha256=VLqfKIab0qlRrHTgWNWjGiULzEC4Zjt-EtN1oltaoJk,1158
20
20
  pycrdt/_version.py,sha256=-6olC6rrn13JKphGwX4vnzXh3q4oCrxxJR8STERSBIw,184
21
- pycrdt/_xml.py,sha256=jHRpLpC07oH4KDY2RskGQ7HTcMqO-TFQj56xbnnwejM,18870
21
+ pycrdt/_xml.py,sha256=D7tewpsOD4UYT6yj2J-QRfJY2o_KjIWLXIWQh1WGZkI,18830
22
22
  pycrdt/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
23
- pycrdt-0.12.41.dist-info/RECORD,,
23
+ pycrdt-0.12.43.dist-info/RECORD,,