diff --git a/litsupport/modules/codesize.py b/litsupport/modules/codesize.py --- a/litsupport/modules/codesize.py +++ b/litsupport/modules/codesize.py @@ -34,9 +34,11 @@ if values[0] == 'Total': continue try: - name = values[0] + # Strip leading underscores and periods, which are + # platform-dependent. E.g. __text -> text or .text -> text + name = values[0].lstrip("__").lstrip(".") val = int(values[1]) - metrics['size.%s' % name] = val + metrics['size_%s' % name] = val except ValueError: logging.info("Ignoring malformed output line: %s", line)