From a8a54f34297f76d9379070f0fd2c1bec9f761c47 Mon Sep 17 00:00:00 2001 From: Thierry Parmentelat Date: Wed, 4 Sep 2013 17:46:13 +0200 Subject: [PATCH] cosmetic --- manifold/manifoldapi.py | 6 +++++- views/templates/view-login.html | 9 --------- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/manifold/manifoldapi.py b/manifold/manifoldapi.py index 29c6c980..25247270 100644 --- a/manifold/manifoldapi.py +++ b/manifold/manifoldapi.py @@ -31,7 +31,11 @@ class ManifoldAPI: if not result: print "[no/empty result]" elif isinstance (result,str): print "result is '%s'"%result elif isinstance (result,list): print "result is a %d-elts list"%len(result) - else: print "[dont know how to display result]" + elif isinstance (result,dict): + print "result is a dict with %d keys : %s"%(len(result),result.keys()) + for (k,v) in result.iteritems(): print '...',k,':',v + print "result is a dict with %d keys : %s"%(len(result),result.keys()), + else: print "[dont know how to display result] %s"%result # xxx temporary code for scaffolding a ManifolResult on top of an API that does not expose error info # as of march 2013 we work with an API that essentially either returns the value, or raises diff --git a/views/templates/view-login.html b/views/templates/view-login.html index 305b5c6d..b28f13cd 100644 --- a/views/templates/view-login.html +++ b/views/templates/view-login.html @@ -5,15 +5,6 @@ {% endblock unfold2_margin %} {% block unfold2_main %} -
-- 2.43.0