1From c2e5ba5e5b0a2bfba13272b96ddf9d2522f178ed Mon Sep 17 00:00:00 2001
2From: ptrcnull <git@ptrcnull.me>
3Date: Fri, 17 Nov 2023 19:19:19 +0100
4Subject: [PATCH] change default opt level to 0
5
6the previous default of 0, 1 causes opt-1 bytecode to also be generated,
7which is not used without passing `-O` to `python3` anyway, and doubles
8the size of the resulting package
9---
10 installer/__main__.py | 4 ++--
11 1 file changed, 2 insertions(+), 2 deletions(-)
12
13diff --git a/installer/__main__.py b/installer/__main__.py
14index 51014b9..2a389e8 100644
15--- a/installer/__main__.py
16+++ b/installer/__main__.py
17@@ -36,7 +36,7 @@ def _get_main_parser() -> argparse.ArgumentParser:
18 metavar="level",
19 type=int,
20 choices=[0, 1, 2],
21- help="generate bytecode for the specified optimization level(s) (default=0, 1)",
22+ help="generate bytecode for the specified optimization level(s) (default=0)",
23 )
24 parser.add_argument(
25 "--no-compile-bytecode",
26@@ -81,7 +81,7 @@ def _main(cli_args: Sequence[str], program: Optional[str] = None) -> None:
27 if args.no_compile_bytecode:
28 bytecode_levels = []
29 elif not bytecode_levels:
30- bytecode_levels = [0, 1]
31+ bytecode_levels = [0]
32
33 with WheelFile.open(args.wheel) as source:
34 destination = SchemeDictionaryDestination(
35--
362.44.0
37