From 1802707307b29b4cb0ee1459509fda5a5d87db6c Mon Sep 17 00:00:00 2001 From: Mathew Robinson Date: Thu, 17 Jan 2019 11:20:44 -0500 Subject: WIP: fix bad typing which resulted in 0% being displayed --- src/third_party/scons-2.5.0/scons-local-2.5.0/SCons/Node/FS.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/third_party/scons-2.5.0/scons-local-2.5.0/SCons/Node/FS.py b/src/third_party/scons-2.5.0/scons-local-2.5.0/SCons/Node/FS.py index 168e52f242c..d71ded6549a 100644 --- a/src/third_party/scons-2.5.0/scons-local-2.5.0/SCons/Node/FS.py +++ b/src/third_party/scons-2.5.0/scons-local-2.5.0/SCons/Node/FS.py @@ -2636,14 +2636,14 @@ def log_cache_rate(fn): global hits requests += 1 - print('req', requests) result = fn(self) - print('res', result) if result: hits += 1 - print('hits', hits) + ratio = (float(hits) / float(requests)) * 100.0 - print 'Cache hit ratio: %d%%' % (hits / requests) + print 'Cache hits: %d' % (hits) + print 'Cache requests: %d' % (requests) + print 'Cache hit ratio: %d%%' % (ratio) return result return wrapper -- cgit v1.2.1