Skip to content

Commit 9a327b5

Browse files
execute black
1 parent 6360d8d commit 9a327b5

File tree

1 file changed

+17
-13
lines changed

1 file changed

+17
-13
lines changed

src/pip/_internal/commands/download.py

+17-13
Original file line numberDiff line numberDiff line change
@@ -64,20 +64,22 @@ def add_options(self) -> None:
6464
)
6565

6666
self.cmd_opts.add_option(
67-
'--print-download-urls',
68-
dest='print_download_urls',
69-
metavar='output-file',
67+
"--print-download-urls",
68+
dest="print_download_urls",
69+
metavar="output-file",
7070
default=None,
7171
help=("Print URLs of any downloaded distributions to this file."),
7272
)
7373

7474
self.cmd_opts.add_option(
75-
'--avoid-wheel-downloads',
76-
dest='avoid_wheel_downloads',
75+
"--avoid-wheel-downloads",
76+
dest="avoid_wheel_downloads",
7777
default=False,
78-
action='store_true',
79-
help=("Where possible, avoid downloading wheels. This is "
80-
"currently only useful if --print-download-urls is set."),
78+
action="store_true",
79+
help=(
80+
"Where possible, avoid downloading wheels. This is "
81+
"currently only useful if --print-download-urls is set."
82+
),
8183
)
8284

8385
cmdoptions.add_target_python_options(self.cmd_opts)
@@ -152,17 +154,19 @@ def run(self, options: Values, args: List[str]) -> int:
152154
if req.satisfied_by is None:
153155
assert req.name is not None
154156
assert req.link is not None
155-
download_infos.append({
156-
'name': req.name,
157-
'url': req.link.url,
158-
})
157+
download_infos.append(
158+
{
159+
"name": req.name,
160+
"url": req.link.url,
161+
}
162+
)
159163
preparer.save_linked_requirement(req)
160164
downloaded.append(req.name)
161165

162166
if downloaded:
163167
write_output("Successfully downloaded %s", " ".join(downloaded))
164168
if options.print_download_urls:
165-
with open(options.print_download_urls, 'w') as f:
169+
with open(options.print_download_urls, "w") as f:
166170
json.dump(download_infos, f, indent=4)
167171

168172
return SUCCESS

0 commit comments

Comments
 (0)