Skip to content

Commit 0dec5a3

Browse files
committed
fix: new l2 cx edge attribute
1 parent 96be98b commit 0dec5a3

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

pychunkedgraph/graph/attributes.py

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
1+
# pylint: disable=invalid-name, missing-docstring, protected-access, raise-missing-from
2+
13
# TODO design to use these attributes across different clients
24
# `family_id` is specific to bigtable
35

6+
from enum import Enum
47
from typing import NamedTuple
58

69
from .utils import serializers
@@ -101,8 +104,8 @@ class Connectivity:
101104
serializer=serializers.NumPyArray(dtype=basetypes.EDGE_AREA),
102105
)
103106

104-
CrossChunkEdge = _AttributeArray(
105-
pattern=b"atomic_cross_edges_%d",
107+
L2CrossChunkEdge = _AttributeArray(
108+
pattern=b"l2_cross_edge_%d",
106109
family_id="3",
107110
serializer=serializers.NumPyArray(
108111
dtype=basetypes.NODE_ID, shape=(-1, 2), compression_level=22
@@ -115,6 +118,14 @@ class Connectivity:
115118
serializer=serializers.NumPyArray(dtype=basetypes.NODE_ID, shape=(-1, 2)),
116119
)
117120

121+
CrossChunkEdge = _AttributeArray(
122+
pattern=b"atomic_cross_edges_%d",
123+
family_id="4",
124+
serializer=serializers.NumPyArray(
125+
dtype=basetypes.NODE_ID, shape=(-1, 2), compression_level=22
126+
),
127+
)
128+
118129

119130
class Hierarchy:
120131
Child = _Attribute(
@@ -157,8 +168,6 @@ class GraphVersion:
157168
class OperationLogs:
158169
key = b"ioperations"
159170

160-
from enum import Enum
161-
162171
class StatusCodes(Enum):
163172
SUCCESS = 0 # all is well, new changes persisted
164173
CREATED = 1 # log record created in storage

0 commit comments

Comments
 (0)