File tree Expand file tree Collapse file tree 8 files changed +34
-11
lines changed Expand file tree Collapse file tree 8 files changed +34
-11
lines changed Original file line number Diff line number Diff line change 14
14
# -- Project information -----------------------------------------------------
15
15
16
16
project = 'Python SDK reference'
17
- copyright = '2024 , Labelbox'
17
+ copyright = '2025 , Labelbox'
18
18
author = 'Labelbox'
19
- release = '6.6 .0'
19
+ release = '6.7 .0'
20
20
21
21
# -- General configuration ---------------------------------------------------
22
22
Original file line number Diff line number Diff line change 1
1
# Changelog
2
+ # Version 6.7.0 (2025-02-06)
3
+ ## Added
4
+ * MAL support for pdf relationships (beta)([ #1932 ] ( https://github.com/Labelbox/labelbox-python/pull/1932 ) )
5
+ * Allow setting read_only for relationships (beta)([ #1950 ] ( https://github.com/Labelbox/labelbox-python/pull/1950 ) )
6
+
2
7
# Version 6.6.0 (2025-01-14)
3
8
## Added
4
9
* Support for python 3.13([ #1940 ] ( https://github.com/Labelbox/labelbox-python/pull/1940 ) )
Original file line number Diff line number Diff line change 1
1
[project ]
2
2
name = " labelbox"
3
- version = " 6.6 .0"
3
+ version = " 6.7 .0"
4
4
description = " Labelbox Python API"
5
5
authors = [{
name =
" Labelbox" ,
email =
" [email protected] " }]
6
6
dependencies = [
Original file line number Diff line number Diff line change 1
1
name = "labelbox"
2
2
3
- __version__ = "6.6 .0"
3
+ __version__ = "6.7 .0"
4
4
5
5
from labelbox .client import Client
6
6
from labelbox .schema .annotation_import import (
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ class Type(Enum):
19
19
type : Type = Type .UNIDIRECTIONAL
20
20
readonly : Optional [bool ] = None
21
21
22
- @model_validator (mode = ' after' )
22
+ @model_validator (mode = " after" )
23
23
def check_readonly (self ):
24
24
if self .readonly is True :
25
25
warnings .warn (
Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ class _Relationship(BaseModel):
16
16
type : str
17
17
readonly : Optional [bool ] = None
18
18
19
+
19
20
class NDRelationship (NDAnnotation ):
20
21
relationship : _Relationship
21
22
Original file line number Diff line number Diff line change @@ -395,7 +395,10 @@ def test_relationship_readonly_explicit_true():
395
395
value = TextEntity (start = 30 , end = 35 ),
396
396
)
397
397
398
- with pytest .warns (UserWarning , match = "Creating a relationship with readonly=True is in beta.*" ):
398
+ with pytest .warns (
399
+ UserWarning ,
400
+ match = "Creating a relationship with readonly=True is in beta.*" ,
401
+ ):
399
402
relationship = RelationshipAnnotation (
400
403
name = "rel" ,
401
404
value = Relationship (
Original file line number Diff line number Diff line change @@ -261,13 +261,27 @@ def test_readonly_relationships():
261
261
)
262
262
263
263
# Verify readonly relationship
264
- assert readonly_rel_serialized ["relationship" ]["source" ] == ner_source_serialized ["uuid" ]
265
- assert readonly_rel_serialized ["relationship" ]["target" ] == ner_target_serialized ["uuid" ]
264
+ assert (
265
+ readonly_rel_serialized ["relationship" ]["source" ]
266
+ == ner_source_serialized ["uuid" ]
267
+ )
268
+ assert (
269
+ readonly_rel_serialized ["relationship" ]["target" ]
270
+ == ner_target_serialized ["uuid" ]
271
+ )
266
272
assert readonly_rel_serialized ["relationship" ]["type" ] == "unidirectional"
267
273
assert readonly_rel_serialized ["relationship" ]["readonly" ] is True
268
274
269
275
# Verify non-readonly relationship
270
- assert non_readonly_rel_serialized ["relationship" ]["source" ] == ner_source_serialized ["uuid" ]
271
- assert non_readonly_rel_serialized ["relationship" ]["target" ] == ner_target_serialized ["uuid" ]
272
- assert non_readonly_rel_serialized ["relationship" ]["type" ] == "bidirectional"
276
+ assert (
277
+ non_readonly_rel_serialized ["relationship" ]["source" ]
278
+ == ner_source_serialized ["uuid" ]
279
+ )
280
+ assert (
281
+ non_readonly_rel_serialized ["relationship" ]["target" ]
282
+ == ner_target_serialized ["uuid" ]
283
+ )
284
+ assert (
285
+ non_readonly_rel_serialized ["relationship" ]["type" ] == "bidirectional"
286
+ )
273
287
assert non_readonly_rel_serialized ["relationship" ]["readonly" ] is False
You can’t perform that action at this time.
0 commit comments