Skip to content

Commit 38c18e2

Browse files
committed
finish #1613
1 parent 15002fe commit 38c18e2

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

CHANGES.rst

+5
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,16 @@ development at the same time, such as 4.5.x and 5.0.
2020
Unreleased
2121
----------
2222

23+
- When the HTML report location is printed to the terminal, it's now a
24+
terminal-compatible URL, so that you can click the location to open the HTML
25+
file in your browser. Thanks, `Ricardo Newbery <pull 1613_>`_.
26+
2327
- Docs: a new :ref:`Migrating page <migrating>` with details about how to
2428
migrate between major versions of coverage.py. It currently covers the
2529
wildcard changes in 7.x. Thanks, `Brian Grohe <pull 1610_>`_.
2630

2731
.. _pull 1610: https://github.com/nedbat/coveragepy/pull/1610
32+
.. _pull 1613: https://github.com/nedbat/coveragepy/pull/1613
2833

2934
.. scriv-start-here
3035

CONTRIBUTORS.txt

+1
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,7 @@ Peter Ebden
147147
Peter Portante
148148
Phebe Polk
149149
Reya B
150+
Ricardo Newbery
150151
Rodrigue Cloutier
151152
Roger Hu
152153
Ross Lawley

coverage/report.py

+1-7
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55

66
from __future__ import annotations
77

8-
import os
98
import sys
109

1110
from typing import Callable, Iterable, Iterator, IO, Optional, Tuple, TYPE_CHECKING
@@ -59,12 +58,7 @@ def render_report(
5958
try:
6059
ret = reporter.report(morfs, outfile=outfile)
6160
if file_to_close is not None:
62-
if sys.stdout.isatty():
63-
file_path = f"file://{os.path.abspath(output_path)}"
64-
print_path = f"\033]8;;{file_path}\a{output_path}\033]8;;\a"
65-
else:
66-
print_path = output_path
67-
msgfn(f"Wrote {reporter.report_type} to {print_path}")
61+
msgfn(f"Wrote {reporter.report_type} to {output_path}")
6862
delete_file = False
6963
return ret
7064
finally:

0 commit comments

Comments
 (0)