Skip to content

Commit ec9d781

Browse files
authored
Remove reconfigure from easy resource (#1030)
1 parent 5650741 commit ec9d781

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/viam/resource/easy_resource.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -113,12 +113,11 @@ def __init__(self, name: str):
113113
@classmethod
114114
def new(cls, config: ComponentConfig, dependencies: Mapping[ResourceName, ResourceBase]):
115115
"""
116-
This is passed to register_resource_creator; the default implementation calls reconfigure()
116+
This is passed to register_resource_creator. The default implementation only sets the resource name
117117
when an instance of your model is instantiated. You can override this in your subclass.
118118
"""
119119
self = cls(config.name)
120120
logger.debug("created %s %s %s", cls.API, cls.MODEL, config.name)
121-
self.reconfigure(config, dependencies)
122121
return self
123122

124123
@classmethod
@@ -148,6 +147,3 @@ def register(cls):
148147
cls.MODEL,
149148
ResourceCreatorRegistration(cls.new, cls.validate_config), # pyright: ignore [reportArgumentType]
150149
)
151-
152-
def reconfigure(self, config: ComponentConfig, dependencies: Mapping[ResourceName, ResourceBase]):
153-
logger.debug("reconfigure %s %s", self.API, self.MODEL)

0 commit comments

Comments
 (0)