From 186940276c1c6f7eafd4c93368bc5ae28ef7ded7 Mon Sep 17 00:00:00 2001 From: Gilles Dartiguelongue Date: Mon, 14 May 2018 17:40:05 +0200 Subject: Drop pre-python 2.5 compatibility code --- elogv | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/elogv b/elogv index 049a1bf..38d709c 100755 --- a/elogv +++ b/elogv @@ -475,13 +475,7 @@ class ElogViewer: if len(split_up) < 3: continue (cat, pn, other) = split_up[-3:] - if sys.version_info[:2] >= (2, 5): - date = datetime.strptime(other, "%Y%m%d-%H%M%S.log") - else: - # This is for backward compatibility with older version of python - # it will be removed in the future - date_str = other[:8] - date = datetime(int(date_str[:4]),int(date_str[4:6]),int(date_str[6:])) + date = datetime.strptime(other, "%Y%m%d-%H%M%S.log") self.packages.append( (filepath, cat, pn, date, self.get_class(filepath)) ) if not self.packages: -- cgit v1.2.3-18-g5258