Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions codegen/settingsgen.py
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,8 @@ def _populate_classes(parent_dir):
stubf.write(f"{istr1}child_names = ...\n")

for child in child_names:
child_class_strings.append(f"{child}={child}_cls")
child_cls = cls._child_classes[child]
child_class_strings.append(f"{child}={child_cls.__name__}_cls")
if stubf:
stubf.write(f"{istr1}{child} = ...\n")

Expand All @@ -380,7 +381,8 @@ def _populate_classes(parent_dir):

commands_info = _get_commands_info(commands_hash)
for command in command_names:
child_class_strings.append(f"{command}={command}_cls")
command_cls = cls._child_classes[command]
child_class_strings.append(f"{command}={command_cls.__name__}_cls")
# function annotation for commands
if stubf:
command_info = commands_info[command]
Expand All @@ -402,7 +404,8 @@ def _populate_classes(parent_dir):

queries_info = _get_commands_info(queries_hash)
for query in query_names:
child_class_strings.append(f"{query}={query}_cls")
query_cls = cls._child_classes[query]
child_class_strings.append(f"{query}={query_cls.__name__}_cls")
# function annotation for queries
if stubf:
query_info = queries_info[query]
Expand Down