From 89994067699d34b01335a63254be740c6c3984f4 Mon Sep 17 00:00:00 2001 From: Jared Bischof Date: Wed, 17 Dec 2014 12:59:11 -0600 Subject: [PATCH 1/2] Excluding seek, length fields when they exceed int range --- ...anded_sims2overview_no_sort_required_less_memory_used.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/bin/expanded_sims2overview_no_sort_required_less_memory_used.py b/bin/expanded_sims2overview_no_sort_required_less_memory_used.py index 6ae3736..c0fe56e 100755 --- a/bin/expanded_sims2overview_no_sort_required_less_memory_used.py +++ b/bin/expanded_sims2overview_no_sort_required_less_memory_used.py @@ -179,7 +179,11 @@ def print_md5_stats(ohdl, data, imap): match = np.where(imap['md5']==md5) if len(match[0]) > 0: row = match[0][0] - seek, length = str(imap[row][1]), str(imap[row][2]) + # seek and length must be less than 2147483647 + if imap[row][1] <= 2147483647 and imap[row][2] <= 2147483647: + seek, length = str(imap[row][1]), str(imap[row][2]) + else: + seek, length = '\N', '\N' # output line = [ DB_VER, JOBID, From a8f97728ffe0f0d736d5d7c4096a7d3724f639a6 Mon Sep 17 00:00:00 2001 From: Jared Bischof Date: Wed, 17 Dec 2014 13:00:37 -0600 Subject: [PATCH 2/2] Fixed comment --- bin/expanded_sims2overview_no_sort_required_less_memory_used.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/expanded_sims2overview_no_sort_required_less_memory_used.py b/bin/expanded_sims2overview_no_sort_required_less_memory_used.py index c0fe56e..ff8cd92 100755 --- a/bin/expanded_sims2overview_no_sort_required_less_memory_used.py +++ b/bin/expanded_sims2overview_no_sort_required_less_memory_used.py @@ -179,7 +179,7 @@ def print_md5_stats(ohdl, data, imap): match = np.where(imap['md5']==md5) if len(match[0]) > 0: row = match[0][0] - # seek and length must be less than 2147483647 + # seek and length must be less than or equal to 2147483647 if imap[row][1] <= 2147483647 and imap[row][2] <= 2147483647: seek, length = str(imap[row][1]), str(imap[row][2]) else: