annotate util/Filters.py @ 29:7e8a8b732db3 draft

planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 1a81ebd0ddea950b84af3fc830e9267a4814b29f
author yating-l
date Wed, 16 May 2018 18:04:20 -0400
parents 25809f699cb3
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
13
25809f699cb3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 65ab931ef2b05a5acf06cbde3a746c94a0a0a4cb
rmarenco
parents:
diff changeset
1 import logging
25809f699cb3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 65ab931ef2b05a5acf06cbde3a746c94a0a0a4cb
rmarenco
parents:
diff changeset
2
25809f699cb3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 65ab931ef2b05a5acf06cbde3a746c94a0a0a4cb
rmarenco
parents:
diff changeset
3 class TraceBackFormatter(logging.Formatter):
25809f699cb3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 65ab931ef2b05a5acf06cbde3a746c94a0a0a4cb
rmarenco
parents:
diff changeset
4 def format(self, record):
25809f699cb3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 65ab931ef2b05a5acf06cbde3a746c94a0a0a4cb
rmarenco
parents:
diff changeset
5 # If the log has some Exception text, we don't display them
25809f699cb3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 65ab931ef2b05a5acf06cbde3a746c94a0a0a4cb
rmarenco
parents:
diff changeset
6 s = super(TraceBackFormatter, self).format(record)
25809f699cb3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 65ab931ef2b05a5acf06cbde3a746c94a0a0a4cb
rmarenco
parents:
diff changeset
7 if record.exc_text or record.exc_info:
25809f699cb3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 65ab931ef2b05a5acf06cbde3a746c94a0a0a4cb
rmarenco
parents:
diff changeset
8 s = record.message
25809f699cb3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 65ab931ef2b05a5acf06cbde3a746c94a0a0a4cb
rmarenco
parents:
diff changeset
9 return s
29
7e8a8b732db3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 1a81ebd0ddea950b84af3fc830e9267a4814b29f
yating-l
parents: 13
diff changeset
10
7e8a8b732db3 planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 1a81ebd0ddea950b84af3fc830e9267a4814b29f
yating-l
parents: 13
diff changeset
11