The json.dumps function adds trailing whitespace when using
indent, because the default separator is not ','.

The workaround [1] is to set the separators to be ',' and ': ',
e.g. separators=(',', ': ')

[1] https://hg.python.org/cpython/rev/78bad589f205

Signed-off-by: Tim Orling <timothy.t.orl...@linux.intel.com>
---
 meta/recipes-devtools/python/python/create_manifest2.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-devtools/python/python/create_manifest2.py 
b/meta/recipes-devtools/python/python/create_manifest2.py
index bd64ec3ee74..e7450452ba5 100644
--- a/meta/recipes-devtools/python/python/create_manifest2.py
+++ b/meta/recipes-devtools/python/python/create_manifest2.py
@@ -274,4 +274,4 @@ for key in new_manifest:
 
 # Create the manifest from the data structure that was built
 with open('python2-manifest.json.new','w') as outfile:
-    json.dump(new_manifest,outfile,sort_keys=True, indent=4)
+    json.dump(new_manifest,outfile,sort_keys=True, indent=4, separators=(',', 
': '))
-- 
2.13.6

-- 
_______________________________________________
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core

Reply via email to