Describe the bug
When calling methods of classes that are wrapped in structured configs, ConfigAttributeError is raised.
To Reproduce
from omegaconf import OmegaConf
from dataclasses import dataclass
@dataclass
class MyConfig:
value: int
def print_formatted_value(self):
print(f'This is my value: {self.value}')
# prints This is my value: 42
MyConfig(value=42).print_formatted_value()
# raises omegaconf.errors.ConfigAttributeError: Key 'print_formatted_value' not in 'MyConfig'
OmegaConf.structured(MyConfig(value=42)).print_formatted_value()
Expected behavior
Method calls on structured configs are possible.
Additional context
Describe the bug
When calling methods of classes that are wrapped in structured configs,
ConfigAttributeErroris raised.To Reproduce
Expected behavior
Method calls on structured configs are possible.
Additional context