Skip to content

Commit

Permalink
Improve docstring of config.stringify_invalid (#103965)
Browse files Browse the repository at this point in the history
  • Loading branch information
emontnemery committed Nov 14, 2023
1 parent 94a2087 commit 2d39eaf
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions homeassistant/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -581,8 +581,9 @@ def find_annotation_rec(
def stringify_invalid(ex: vol.Invalid) -> str:
"""Stringify voluptuous.Invalid.
Based on voluptuous.error.Invalid.__str__, the main modification
is to format the path delimited by -> instead of @data[].
This is an alternative to the custom __str__ implemented in
voluptuous.error.Invalid. The main modification is to format
the path delimited by -> instead of @data[].
"""
path = "->".join(str(m) for m in ex.path)
# This function is an alternative to the stringification done by
Expand Down

0 comments on commit 2d39eaf

Please sign in to comment.