From b4cc4bb4b7b5d3311158fdabd8296284e36aff62 Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Thu, 25 Oct 2012 08:03:30 -0400 Subject: [PATCH] storage:util:mapfile: fix YAML -> JSON in docstrings. This should have been done back in: commit a95915c6c7d6a4e29c1e5547580e0c1fed2467e1 Author: W. Trevor King Date: Mon Sep 17 08:14:21 2012 -0400 storage:util:mapfile: convert YAML settings to JSON. I also add an empty-settings generation as a sanity check. --- libbe/storage/util/mapfile.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libbe/storage/util/mapfile.py b/libbe/storage/util/mapfile.py index d17f0d3..71e5b0d 100644 --- a/libbe/storage/util/mapfile.py +++ b/libbe/storage/util/mapfile.py @@ -40,12 +40,14 @@ class InvalidMapfileContents (Exception): def generate(map): - """Generate a YAML mapfile content string. + """Generate a JSON mapfile content string. Examples -------- >>> import sys + >>> sys.stdout.write(generate({})) + {} >>> sys.stdout.write(generate({'q':'p'})) { @@ -100,7 +102,7 @@ def generate(map): return '\n\n\n\n\n\n\n'.join(lines) + '\n' def parse(contents): - """Parse a YAML mapfile string. + """Parse a JSON mapfile string. Examples -------- -- 2.26.2