Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit db94c4d

Browse files
bearomorphismLee-W
authored andcommitted
docs(defaults): deprecate type Questions
1 parent 98a81f8 commit db94c4d

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

commitizen/defaults.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,6 @@
88

99
from commitizen.question import CzQuestion
1010

11-
# Type
12-
Questions = Iterable[MutableMapping[str, Any]] # TODO: deprecate this?
13-
1411

1512
class CzSettings(TypedDict, total=False):
1613
bump_pattern: str
@@ -161,6 +158,10 @@ def get_tag_regexes(
161158
}
162159

163160

161+
# Type
162+
Questions = Iterable[MutableMapping[str, Any]] # TODO: remove this in v5
163+
164+
164165
def __getattr__(name: str) -> Any:
165166
# PEP-562: deprecate module-level variable
166167

@@ -176,6 +177,7 @@ def __getattr__(name: str) -> Any:
176177
"change_type_order": (CHANGE_TYPE_ORDER, "CHANGE_TYPE_ORDER"),
177178
"encoding": (ENCODING, "ENCODING"),
178179
"name": (DEFAULT_SETTINGS["name"], "DEFAULT_SETTINGS['name']"),
180+
"Questions": (Questions, "Iterable[CzQuestion]"),
179181
}
180182
if name in deprecated_vars:
181183
value, replacement = deprecated_vars[name]

0 commit comments

Comments
 (0)