You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kibble.apache.org by hu...@apache.org on 2017/10/21 20:28:00 UTC

[kibble] branch master updated: kludge evolution count

This is an automated email from the ASF dual-hosted git repository.

humbedooh pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kibble.git


The following commit(s) were added to refs/heads/master by this push:
     new fc9350b  kludge evolution count
fc9350b is described below

commit fc9350baa615d66b05c564fa55b7dbe1d4c1d413
Author: Daniel Gruno <hu...@apache.org>
AuthorDate: Sat Oct 21 22:27:52 2017 +0200

    kludge evolution count
    
    for some reason, numbers are being reported as strings.
    so kludge it for now.
---
 api/pages/code/evolution.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/api/pages/code/evolution.py b/api/pages/code/evolution.py
index 09b9eff..f6909ac 100644
--- a/api/pages/code/evolution.py
+++ b/api/pages/code/evolution.py
@@ -146,9 +146,9 @@ def run(API, environ, indata, session):
             if breakdown:
                 pass
             else:
-                item['blanks'] = item.get('blanks', 0) + updates['blank']
-                item['comments'] = item.get('comments', 0) + updates['comments']
-                item['code'] = item.get('code', 0) + updates['loc']
+                item['blanks'] = item.get('blanks', 0) + int(updates['blank'])
+                item['comments'] = item.get('comments', 0) + int(updates['comments'])
+                item['code'] = item.get('code', 0) + int(updates['loc'])
                 
         res = session.DB.ES.scroll(scroll_id = sid, scroll = '1m')
         sid = res['_scroll_id']

-- 
To stop receiving notification emails like this one, please contact
['"commits@kibble.apache.org" <co...@kibble.apache.org>'].