Skip to content

Commit c37d493

Browse files
committed
Fix comments again.
1 parent 65e5e4d commit c37d493

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

scripts/generate_connection_stubs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def create_definition(name, method, overloaded: bool) -> str:
6969
definition += f" -> {method['return']}: ..."
7070
return definition
7171

72-
# We have "duplicate" methods, which are overloaded
72+
# We have "duplicate" methods, which are overloaded.
7373
# We keep note of them to add the @overload decorator.
7474
overloaded_methods: set[str] = {m for m in connection_methods if isinstance(m['name'], list)}
7575

scripts/generate_connection_wrapper_stubs.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ def create_definition(name, method, overloaded: bool) -> str:
8787
return definition
8888

8989
# We have "duplicate" methods, which are overloaded.
90+
# We keep note of them to add the @overload decorator.
9091
overloaded_methods: set[str] = {m for m in connection_methods if isinstance(m['name'], list)}
9192

9293
body = []
@@ -102,6 +103,7 @@ def create_definition(name, method, overloaded: bool) -> str:
102103
method['kwargs'].append({'name': 'connection', 'type': 'DuckDBPyConnection', 'default': '...'})
103104

104105
for name in names:
106+
body.append(create_definition(name, method, name in overloaded_methods))
105107

106108
# ---- End of generation code ----
107109

0 commit comments

Comments
 (0)