Skip to content

Commit 9fca0f7

Browse files
author
Matt Sokoloff
committed
fix metaclass conflict
1 parent db0f5d4 commit 9fca0f7

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

labelbox/schema/annotation_import.py

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
import logging
44
import os
55
import time
6-
from abc import ABC, abstractmethod
76
from typing import Any, Dict, List, BinaryIO
87

98
import backoff
@@ -20,7 +19,7 @@
2019
logger = logging.getLogger(__name__)
2120

2221

23-
class AnnotationImport(DbObject, ABC):
22+
class AnnotationImport(DbObject):
2423
name = Field.String("name")
2524
state = Field.Enum(AnnotationImportState, "state")
2625
input_file_url = Field.String("input_file_url")
@@ -135,14 +134,12 @@ def refresh(self) -> None:
135134
self._set_field_values(res)
136135

137136
@classmethod
138-
@abstractmethod
139-
def from_name(cls, client, parent_id: str, name):
140-
...
137+
def from_name(cls, client: "labelbox.Client", parent_id: str, name: str):
138+
raise NotImplementedError("Inheriting class must override")
141139

142140
@property
143-
@abstractmethod
144141
def parent_id(self) -> str:
145-
...
142+
raise NotImplementedError("Inheriting class must override")
146143

147144

148145
class MEAPredictionImport(AnnotationImport):

0 commit comments

Comments
 (0)