-
-
Notifications
You must be signed in to change notification settings - Fork 206
Closed
Labels
Description
traitlets/traitlets/traitlets.py
Lines 1022 to 1030 in 2cdbe59
default_method_name = "_%s_default" % name | |
try: | |
mro_trait = mro[: mro.index(trait.this_class) + 1] # type:ignore[arg-type] | |
except ValueError: | |
# this_class not in mro | |
pass | |
for c in mro_trait: | |
if default_method_name in c.__dict__: | |
cls._all_trait_default_generators[name] = c.__dict__[default_method_name] |
Getting error UnboundLocalError: local variable 'mro_trait' referenced before assignment.