summaryrefslogtreecommitdiff
path: root/coverage/html.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2014-09-14 17:08:33 -0400
committerNed Batchelder <ned@nedbatchelder.com>2014-09-14 17:08:33 -0400
commitebfa5a5bcbd0256193e01076bd4cad0d3b22b56f (patch)
treee2d32c759bc54b5f07723bfa129492da445351c3 /coverage/html.py
parent941eeb588459098a85266b4c5d176d6deed2eb53 (diff)
downloadpython-coveragepy-git-ebfa5a5bcbd0256193e01076bd4cad0d3b22b56f.tar.gz
Don't ask people to pass source back into CodeUnits
Diffstat (limited to 'coverage/html.py')
-rw-r--r--coverage/html.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/coverage/html.py b/coverage/html.py
index 85f47ab4..863d1508 100644
--- a/coverage/html.py
+++ b/coverage/html.py
@@ -164,7 +164,7 @@ class HtmlReporter(Reporter):
# If need be, determine the encoding of the source file. We use it
# later to properly write the HTML.
if sys.version_info < (3, 0):
- encoding = cu.source_encoding(source)
+ encoding = cu.source_encoding()
# Some UTF8 files have the dreaded UTF8 BOM. If so, junk it.
if encoding.startswith("utf-8") and source[:3] == "\xef\xbb\xbf":
source = source[3:]
@@ -184,7 +184,7 @@ class HtmlReporter(Reporter):
lines = []
- for lineno, line in enumerate(cu.source_token_lines(source), start=1):
+ for lineno, line in enumerate(cu.source_token_lines(), start=1):
# Figure out how to mark this line.
line_class = []
annotate_html = ""