Skip to content

Commit

Permalink
Ensuring order of class variables when provided as __annotations__ in…
Browse files Browse the repository at this point in the history
… the class
  • Loading branch information
swansonk14 committed Nov 12, 2023
1 parent 0789b25 commit 70137fd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tap/tap.py
Original file line number Diff line number Diff line change
Expand Up @@ -538,7 +538,7 @@ def _get_annotations(self) -> Dict[str, Any]:

def _get_class_variables(self) -> OrderedDict:
"""Returns an OrderedDict mapping class variables names to their additional information."""
class_variable_names = self._get_class_dict().keys() | self._get_annotations().keys()
class_variable_names = {**self._get_annotations(), **self._get_class_dict()}.keys()

try:
class_variables = self._get_from_self_and_super(
Expand Down

0 comments on commit 70137fd

Please sign in to comment.