mirror of
https://github.com/esphome/esphome.git
synced 2025-09-27 15:42:22 +01:00
Dump full parsed config to json-config api call (#4373)
This commit is contained in:
@@ -390,8 +390,11 @@ def _load_yaml_internal(fname):
|
||||
loader.dispose()
|
||||
|
||||
|
||||
def dump(dict_):
|
||||
def dump(dict_, show_secrets=False):
|
||||
"""Dump YAML to a string and remove null."""
|
||||
if show_secrets:
|
||||
_SECRET_VALUES.clear()
|
||||
_SECRET_CACHE.clear()
|
||||
return yaml.dump(
|
||||
dict_, default_flow_style=False, allow_unicode=True, Dumper=ESPHomeDumper
|
||||
)
|
||||
|
Reference in New Issue
Block a user