Skip to content

Commit 97c7f70

Browse files
committed
Add folder_id in the item metadata
1 parent 2afd5a1 commit 97c7f70

File tree

4 files changed

+6
-2
lines changed

4 files changed

+6
-2
lines changed

src/superannotate/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import sys
44

55

6-
__version__ = "4.4.32"
6+
__version__ = "4.4.33b1"
77

88
os.environ.update({"sa_version": __version__})
99
sys.path.append(os.path.split(os.path.realpath(__file__))[0])

src/superannotate/lib/core/entities/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ class TimedBaseModel(BaseModel):
5757
class BaseItemEntity(TimedBaseModel):
5858
id: Optional[int]
5959
name: Optional[str]
60+
folder_id: Optional[int]
6061
path: Optional[str] = Field(
6162
None, description="Item’s path in SuperAnnotate project"
6263
)

src/superannotate/lib/infrastructure/annotation_adapter.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,9 @@ def get_component_value(self, component_id: str):
4444
return None
4545

4646
def set_component_value(self, component_id: str, value: Any):
47-
self.annotation.setdefault("data", {}).setdefault(component_id, {})["value"] = value
47+
self.annotation.setdefault("data", {}).setdefault(component_id, {})[
48+
"value"
49+
] = value
4850
return self
4951

5052

tests/integration/items/test_get_item_metadata.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ class TestGetEntityMetadataVector(BaseTestCase):
2020
EXPECTED_ITEM_METADATA = {
2121
"name": "example_image_1.jpg",
2222
"path": "TestGetEntityMetadataVector",
23+
"folder_id": None,
2324
"url": None,
2425
"annotator_email": None,
2526
"qa_email": None,

0 commit comments

Comments
 (0)