Skip to content

Commit aa53ce7

Browse files
committed
Rename to readonly
1 parent 8a9b4e4 commit aa53ce7

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

libs/labelbox/src/labelbox/data/annotation_types/relationship.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ class Type(Enum):
1616
source: Union[ObjectAnnotation, ClassificationAnnotation]
1717
target: ObjectAnnotation
1818
type: Type = Type.UNIDIRECTIONAL
19-
read_only: Optional[bool]
19+
readonly: Optional[bool] = None
2020

2121

2222
class RelationshipAnnotation(BaseAnnotation):

libs/labelbox/src/labelbox/data/serialization/ndjson/relationship.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ class _Relationship(BaseModel):
1414
source: str
1515
target: str
1616
type: str
17-
read_only: Optional[bool]
17+
readonly: Optional[bool] = None
1818

1919
class NDRelationship(NDAnnotation):
2020
relationship: _Relationship
@@ -51,6 +51,6 @@ def from_common(
5151
source=str(relationship.source._uuid),
5252
target=str(relationship.target._uuid),
5353
type=relationship.type.value,
54-
read_only=relationship.read_only,
54+
readonly=relationship.readonly,
5555
),
5656
)

0 commit comments

Comments
 (0)