We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Change `ignore_missing_stub` default to `false`?
I've been wondering about this.

Possible reasons:
1. More and more stubs are "stubtest" complete (not counting pyright and mypy)
	1.1. It should be relatively easy to "minimally complete" missing ones using stugben. Especially after the reduction of stubtest false-positives by https://github.com/python/mypy/pull/14270
	1.2. Eventually most if not all stubs will have `ignore_missing_stub = false`, which could be the only entry under `[tool.stubtest]`
2. It's easier to search for `ignore_missing_stub = true` than to search for a missing line.
3. `None` would mean `False` in the metadata parser. (feels more intuitive?)
4. #8955
    > I don't want to encourage new incomplete stubs
    
Cons:
- Have to update the metadata parser
- A commit that flips (adds/removes) the value in all metadata.toml
- Maybe wait until there's even less (if not all) "stubtest incomplete" stubs left.

--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `scripts/create_baseline_stubs.py`
Content:
```
1 #!/usr/bin/env python3
2 
3 """Script to generate unannotated baseline stubs using stubgen.
4 
5 Basic usage:
6 $ python3 scripts/create_baseline_stubs.py <project on PyPI>
7 
8 Run with -h for more help.
9 """
10 
11 from __future__ import annotations
12 
13 import argparse
14 import os
15 import re
16 import subprocess
17 import sys
18 
19 if sys.version_info >= (3, 8):
20     from importlib.metadata import distribution
21 
22 PYRIGHT_CONFIG = "pyrightconfig.stricter.json"
23 
24 
25 def search_pip_freeze_output(project: str, output: str) -> tuple[str, str] | None:
26     # Look for lines such as "typed-ast==1.4.2".  '-' matches '_' and
27     # '_' matches '-' in project name, so that "typed_ast" matches
28     # "typed-ast", and vice versa.
29     regex = "^(" + re.sub(r"[-_]", "[-_]", project) + ")==(.*)"
30     m = re.search(regex, output, flags=re.IGNORECASE | re.MULTILINE)
31     if not m:
32         return None
33     return m.group(1), m.group(2)
34 
35 
36 def get_installed_package_info(project: str) -> tuple[str, str] | None:
37     """Find package information from pip freeze output.
38 
39     Match project name somewhat fuzzily (case sensitive; '-' matches '_', and
40     vice versa).
41 
42     Return (normalized project name, installed version) if successful.
43     """
44     r = subprocess.run(["pip", "freeze"], capture_output=True, text=True, check=True)
45     return search_pip_freeze_output(project, r.stdout)
46 
47 
48 def run_stubgen(package: str, output: str) -> None:
49     print(f"Running stubgen: stubgen -o {output} -p {package}")
50     subprocess.run(["stubgen", "-o", output, "-p", package, "--export-less"], check=True)
51 
52 
53 def run_black(stub_dir: str) -> None:
54     print(f"Running black: black {stub_dir}")
55     subprocess.run(["black", stub_dir])
56 
57 
58 def run_isort(stub_dir: str) -> None:
59     print(f"Running isort: isort {stub_dir}")
60     subprocess.run(["python3", "-m", "isort", stub_dir])
61 
62 
63 def create_metadata(stub_dir: str, version: str) -> None:
64     """Create a METADATA.toml file."""
65     match = re.match(r"[0-9]+.[0-9]+", version)
66     if match is None:
67         sys.exit(f"Error: Cannot parse version number: {version}")
68     filename = os.path.join(stub_dir, "METADATA.toml")
69     version = match.group(0)
70     if os.path.exists(filename):
71         return
72     print(f"Writing {filename}")
73     with open(filename, "w", encoding="UTF-8") as file:
74         file.write(
75             f"""\
76 version = "{version}.*"
77 
78 [tool.stubtest]
79 ignore_missing_stub = false
80 """
81         )
82 
83 
84 def add_pyright_exclusion(stub_dir: str) -> None:
85     """Exclude stub_dir from strict pyright checks."""
86     with open(PYRIGHT_CONFIG, encoding="UTF-8") as f:
87         lines = f.readlines()
88     i = 0
89     while i < len(lines) and not lines[i].strip().startswith('"exclude": ['):
90         i += 1
91     assert i < len(lines), f"Error parsing {PYRIGHT_CONFIG}"
92     while not lines[i].strip().startswith("]"):
93         i += 1
94     # Must use forward slash in the .json file
95     line_to_add = f'        "{stub_dir}",'.replace("\\", "/")
96     initial = i - 1
97     while lines[i].lower() > line_to_add.lower():
98         i -= 1
99     if lines[i + 1].strip().rstrip(",") == line_to_add.strip().rstrip(","):
100         print(f"{PYRIGHT_CONFIG} already up-to-date")
101         return
102     if i == initial:
103         # Special case: when adding to the end of the list, commas need tweaking
104         line_to_add = line_to_add.rstrip(",")
105         lines[i] = lines[i].rstrip() + ",\n"
106     lines.insert(i + 1, line_to_add + "\n")
107     print(f"Updating {PYRIGHT_CONFIG}")
108     with open(PYRIGHT_CONFIG, "w", encoding="UTF-8") as f:
109         f.writelines(lines)
110 
111 
112 def main() -> None:
113     parser = argparse.ArgumentParser(
114         description="""Generate baseline stubs automatically for an installed pip package
115                        using stubgen. Also run black and isort. If the name of
116                        the project is different from the runtime Python package name, you may
117                        need to use --package (example: --package yaml PyYAML)."""
118     )
119     parser.add_argument("project", help="name of PyPI project for which to generate stubs under stubs/")
120     parser.add_argument("--package", help="generate stubs for this Python package (default is autodetected)")
121     args = parser.parse_args()
122     project = args.project
123     package = args.package
124 
125     if not re.match(r"[a-zA-Z0-9-_.]+$", project):
126         sys.exit(f"Invalid character in project name: {project!r}")
127 
128     if not package:
129         package = project  # default
130         # Try to find which packages are provided by the project
131         # Use default if that fails or if several packages are found
132         #
133         # The importlib.metadata module is used for projects whose name is different
134         # from the runtime Python package name (example: PyYAML/yaml)
135         if sys.version_info >= (3, 8):
136             dist = distribution(project).read_text("top_level.txt")
137             if dist is not None:
138                 packages = [name for name in dist.split() if not name.startswith("_")]
139                 if len(packages) == 1:
140                     package = packages[0]
141         print(f'Using detected package "{package}" for project "{project}"', file=sys.stderr)
142         print("Suggestion: Try again with --package argument if that's not what you wanted", file=sys.stderr)
143 
144     if not os.path.isdir("stubs") or not os.path.isdir("stdlib"):
145         sys.exit("Error: Current working directory must be the root of typeshed repository")
146 
147     # Get normalized project name and version of installed package.
148     info = get_installed_package_info(project)
149     if info is None:
150         print(f'Error: "{project}" is not installed', file=sys.stderr)
151         print("", file=sys.stderr)
152         print(f'Suggestion: Run "python3 -m pip install {project}" and try again', file=sys.stderr)
153         sys.exit(1)
154     project, version = info
155 
156     stub_dir = os.path.join("stubs", project)
157     package_dir = os.path.join(stub_dir, package)
158     if os.path.exists(package_dir):
159         sys.exit(f"Error: {package_dir} already exists (delete it first)")
160 
161     run_stubgen(package, stub_dir)
162 
163     run_isort(stub_dir)
164     run_black(stub_dir)
165 
166     create_metadata(stub_dir, version)
167 
168     # Since the generated stubs won't have many type annotations, we
169     # have to exclude them from strict pyright checks.
170     add_pyright_exclusion(stub_dir)
171 
172     print("\nDone!\n\nSuggested next steps:")
173     print(f" 1. Manually review the generated stubs in {stub_dir}")
174     print(" 2. Optionally run tests and autofixes (see tests/README.md for details)")
175     print(" 3. Commit the changes on a new branch and create a typeshed PR (don't force-push!)")
176 
177 
178 if __name__ == "__main__":
179     main()
180
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/scripts/create_baseline_stubs.py b/scripts/create_baseline_stubs.py
--- a/scripts/create_baseline_stubs.py
+++ b/scripts/create_baseline_stubs.py
@@ -71,14 +71,7 @@
         return
     print(f"Writing {filename}")
     with open(filename, "w", encoding="UTF-8") as file:
-        file.write(
-            f"""\
-version = "{version}.*"
-
-[tool.stubtest]
-ignore_missing_stub = false
-"""
-        )
+        file.write(f'version = "{version}.*"')
 
 
 def add_pyright_exclusion(stub_dir: str) -> None:

{"golden_diff": "diff --git a/scripts/create_baseline_stubs.py b/scripts/create_baseline_stubs.py\n--- a/scripts/create_baseline_stubs.py\n+++ b/scripts/create_baseline_stubs.py\n@@ -71,14 +71,7 @@\n         return\n     print(f\"Writing {filename}\")\n     with open(filename, \"w\", encoding=\"UTF-8\") as file:\n-        file.write(\n-            f\"\"\"\\\n-version = \"{version}.*\"\n-\n-[tool.stubtest]\n-ignore_missing_stub = false\n-\"\"\"\n-        )\n+        file.write(f'version = \"{version}.*\"')\n \n \n def add_pyright_exclusion(stub_dir: str) -> None:\n", "issue": "Change `ignore_missing_stub` default to `false`?\nI've been wondering about this.\r\n\r\nPossible reasons:\r\n1. More and more stubs are \"stubtest\" complete (not counting pyright and mypy)\r\n\t1.1. It should be relatively easy to \"minimally complete\" missing ones using stugben. Especially after the reduction of stubtest false-positives by https://github.com/python/mypy/pull/14270\r\n\t1.2. Eventually most if not all stubs will have `ignore_missing_stub = false`, which could be the only entry under `[tool.stubtest]`\r\n2. It's easier to search for `ignore_missing_stub = true` than to search for a missing line.\r\n3. `None` would mean `False` in the metadata parser. (feels more intuitive?)\r\n4. #8955\r\n    > I don't want to encourage new incomplete stubs\r\n    \r\nCons:\r\n- Have to update the metadata parser\r\n- A commit that flips (adds/removes) the value in all metadata.toml\r\n- Maybe wait until there's even less (if not all) \"stubtest incomplete\" stubs left.\n", "before_files": [{"content": "#!/usr/bin/env python3\n\n\"\"\"Script to generate unannotated baseline stubs using stubgen.\n\nBasic usage:\n$ python3 scripts/create_baseline_stubs.py <project on PyPI>\n\nRun with -h for more help.\n\"\"\"\n\nfrom __future__ import annotations\n\nimport argparse\nimport os\nimport re\nimport subprocess\nimport sys\n\nif sys.version_info >= (3, 8):\n    from importlib.metadata import distribution\n\nPYRIGHT_CONFIG = \"pyrightconfig.stricter.json\"\n\n\ndef search_pip_freeze_output(project: str, output: str) -> tuple[str, str] | None:\n    # Look for lines such as \"typed-ast==1.4.2\".  '-' matches '_' and\n    # '_' matches '-' in project name, so that \"typed_ast\" matches\n    # \"typed-ast\", and vice versa.\n    regex = \"^(\" + re.sub(r\"[-_]\", \"[-_]\", project) + \")==(.*)\"\n    m = re.search(regex, output, flags=re.IGNORECASE | re.MULTILINE)\n    if not m:\n        return None\n    return m.group(1), m.group(2)\n\n\ndef get_installed_package_info(project: str) -> tuple[str, str] | None:\n    \"\"\"Find package information from pip freeze output.\n\n    Match project name somewhat fuzzily (case sensitive; '-' matches '_', and\n    vice versa).\n\n    Return (normalized project name, installed version) if successful.\n    \"\"\"\n    r = subprocess.run([\"pip\", \"freeze\"], capture_output=True, text=True, check=True)\n    return search_pip_freeze_output(project, r.stdout)\n\n\ndef run_stubgen(package: str, output: str) -> None:\n    print(f\"Running stubgen: stubgen -o {output} -p {package}\")\n    subprocess.run([\"stubgen\", \"-o\", output, \"-p\", package, \"--export-less\"], check=True)\n\n\ndef run_black(stub_dir: str) -> None:\n    print(f\"Running black: black {stub_dir}\")\n    subprocess.run([\"black\", stub_dir])\n\n\ndef run_isort(stub_dir: str) -> None:\n    print(f\"Running isort: isort {stub_dir}\")\n    subprocess.run([\"python3\", \"-m\", \"isort\", stub_dir])\n\n\ndef create_metadata(stub_dir: str, version: str) -> None:\n    \"\"\"Create a METADATA.toml file.\"\"\"\n    match = re.match(r\"[0-9]+.[0-9]+\", version)\n    if match is None:\n        sys.exit(f\"Error: Cannot parse version number: {version}\")\n    filename = os.path.join(stub_dir, \"METADATA.toml\")\n    version = match.group(0)\n    if os.path.exists(filename):\n        return\n    print(f\"Writing {filename}\")\n    with open(filename, \"w\", encoding=\"UTF-8\") as file:\n        file.write(\n            f\"\"\"\\\nversion = \"{version}.*\"\n\n[tool.stubtest]\nignore_missing_stub = false\n\"\"\"\n        )\n\n\ndef add_pyright_exclusion(stub_dir: str) -> None:\n    \"\"\"Exclude stub_dir from strict pyright checks.\"\"\"\n    with open(PYRIGHT_CONFIG, encoding=\"UTF-8\") as f:\n        lines = f.readlines()\n    i = 0\n    while i < len(lines) and not lines[i].strip().startswith('\"exclude\": ['):\n        i += 1\n    assert i < len(lines), f\"Error parsing {PYRIGHT_CONFIG}\"\n    while not lines[i].strip().startswith(\"]\"):\n        i += 1\n    # Must use forward slash in the .json file\n    line_to_add = f'        \"{stub_dir}\",'.replace(\"\\\\\", \"/\")\n    initial = i - 1\n    while lines[i].lower() > line_to_add.lower():\n        i -= 1\n    if lines[i + 1].strip().rstrip(\",\") == line_to_add.strip().rstrip(\",\"):\n        print(f\"{PYRIGHT_CONFIG} already up-to-date\")\n        return\n    if i == initial:\n        # Special case: when adding to the end of the list, commas need tweaking\n        line_to_add = line_to_add.rstrip(\",\")\n        lines[i] = lines[i].rstrip() + \",\\n\"\n    lines.insert(i + 1, line_to_add + \"\\n\")\n    print(f\"Updating {PYRIGHT_CONFIG}\")\n    with open(PYRIGHT_CONFIG, \"w\", encoding=\"UTF-8\") as f:\n        f.writelines(lines)\n\n\ndef main() -> None:\n    parser = argparse.ArgumentParser(\n        description=\"\"\"Generate baseline stubs automatically for an installed pip package\n                       using stubgen. Also run black and isort. If the name of\n                       the project is different from the runtime Python package name, you may\n                       need to use --package (example: --package yaml PyYAML).\"\"\"\n    )\n    parser.add_argument(\"project\", help=\"name of PyPI project for which to generate stubs under stubs/\")\n    parser.add_argument(\"--package\", help=\"generate stubs for this Python package (default is autodetected)\")\n    args = parser.parse_args()\n    project = args.project\n    package = args.package\n\n    if not re.match(r\"[a-zA-Z0-9-_.]+$\", project):\n        sys.exit(f\"Invalid character in project name: {project!r}\")\n\n    if not package:\n        package = project  # default\n        # Try to find which packages are provided by the project\n        # Use default if that fails or if several packages are found\n        #\n        # The importlib.metadata module is used for projects whose name is different\n        # from the runtime Python package name (example: PyYAML/yaml)\n        if sys.version_info >= (3, 8):\n            dist = distribution(project).read_text(\"top_level.txt\")\n            if dist is not None:\n                packages = [name for name in dist.split() if not name.startswith(\"_\")]\n                if len(packages) == 1:\n                    package = packages[0]\n        print(f'Using detected package \"{package}\" for project \"{project}\"', file=sys.stderr)\n        print(\"Suggestion: Try again with --package argument if that's not what you wanted\", file=sys.stderr)\n\n    if not os.path.isdir(\"stubs\") or not os.path.isdir(\"stdlib\"):\n        sys.exit(\"Error: Current working directory must be the root of typeshed repository\")\n\n    # Get normalized project name and version of installed package.\n    info = get_installed_package_info(project)\n    if info is None:\n        print(f'Error: \"{project}\" is not installed', file=sys.stderr)\n        print(\"\", file=sys.stderr)\n        print(f'Suggestion: Run \"python3 -m pip install {project}\" and try again', file=sys.stderr)\n        sys.exit(1)\n    project, version = info\n\n    stub_dir = os.path.join(\"stubs\", project)\n    package_dir = os.path.join(stub_dir, package)\n    if os.path.exists(package_dir):\n        sys.exit(f\"Error: {package_dir} already exists (delete it first)\")\n\n    run_stubgen(package, stub_dir)\n\n    run_isort(stub_dir)\n    run_black(stub_dir)\n\n    create_metadata(stub_dir, version)\n\n    # Since the generated stubs won't have many type annotations, we\n    # have to exclude them from strict pyright checks.\n    add_pyright_exclusion(stub_dir)\n\n    print(\"\\nDone!\\n\\nSuggested next steps:\")\n    print(f\" 1. Manually review the generated stubs in {stub_dir}\")\n    print(\" 2. Optionally run tests and autofixes (see tests/README.md for details)\")\n    print(\" 3. Commit the changes on a new branch and create a typeshed PR (don't force-push!)\")\n\n\nif __name__ == \"__main__\":\n    main()\n", "path": "scripts/create_baseline_stubs.py"}], "after_files": [{"content": "#!/usr/bin/env python3\n\n\"\"\"Script to generate unannotated baseline stubs using stubgen.\n\nBasic usage:\n$ python3 scripts/create_baseline_stubs.py <project on PyPI>\n\nRun with -h for more help.\n\"\"\"\n\nfrom __future__ import annotations\n\nimport argparse\nimport os\nimport re\nimport subprocess\nimport sys\n\nif sys.version_info >= (3, 8):\n    from importlib.metadata import distribution\n\nPYRIGHT_CONFIG = \"pyrightconfig.stricter.json\"\n\n\ndef search_pip_freeze_output(project: str, output: str) -> tuple[str, str] | None:\n    # Look for lines such as \"typed-ast==1.4.2\".  '-' matches '_' and\n    # '_' matches '-' in project name, so that \"typed_ast\" matches\n    # \"typed-ast\", and vice versa.\n    regex = \"^(\" + re.sub(r\"[-_]\", \"[-_]\", project) + \")==(.*)\"\n    m = re.search(regex, output, flags=re.IGNORECASE | re.MULTILINE)\n    if not m:\n        return None\n    return m.group(1), m.group(2)\n\n\ndef get_installed_package_info(project: str) -> tuple[str, str] | None:\n    \"\"\"Find package information from pip freeze output.\n\n    Match project name somewhat fuzzily (case sensitive; '-' matches '_', and\n    vice versa).\n\n    Return (normalized project name, installed version) if successful.\n    \"\"\"\n    r = subprocess.run([\"pip\", \"freeze\"], capture_output=True, text=True, check=True)\n    return search_pip_freeze_output(project, r.stdout)\n\n\ndef run_stubgen(package: str, output: str) -> None:\n    print(f\"Running stubgen: stubgen -o {output} -p {package}\")\n    subprocess.run([\"stubgen\", \"-o\", output, \"-p\", package, \"--export-less\"], check=True)\n\n\ndef run_black(stub_dir: str) -> None:\n    print(f\"Running black: black {stub_dir}\")\n    subprocess.run([\"black\", stub_dir])\n\n\ndef run_isort(stub_dir: str) -> None:\n    print(f\"Running isort: isort {stub_dir}\")\n    subprocess.run([\"python3\", \"-m\", \"isort\", stub_dir])\n\n\ndef create_metadata(stub_dir: str, version: str) -> None:\n    \"\"\"Create a METADATA.toml file.\"\"\"\n    match = re.match(r\"[0-9]+.[0-9]+\", version)\n    if match is None:\n        sys.exit(f\"Error: Cannot parse version number: {version}\")\n    filename = os.path.join(stub_dir, \"METADATA.toml\")\n    version = match.group(0)\n    if os.path.exists(filename):\n        return\n    print(f\"Writing {filename}\")\n    with open(filename, \"w\", encoding=\"UTF-8\") as file:\n        file.write(f'version = \"{version}.*\"')\n\n\ndef add_pyright_exclusion(stub_dir: str) -> None:\n    \"\"\"Exclude stub_dir from strict pyright checks.\"\"\"\n    with open(PYRIGHT_CONFIG, encoding=\"UTF-8\") as f:\n        lines = f.readlines()\n    i = 0\n    while i < len(lines) and not lines[i].strip().startswith('\"exclude\": ['):\n        i += 1\n    assert i < len(lines), f\"Error parsing {PYRIGHT_CONFIG}\"\n    while not lines[i].strip().startswith(\"]\"):\n        i += 1\n    # Must use forward slash in the .json file\n    line_to_add = f'        \"{stub_dir}\",'.replace(\"\\\\\", \"/\")\n    initial = i - 1\n    while lines[i].lower() > line_to_add.lower():\n        i -= 1\n    if lines[i + 1].strip().rstrip(\",\") == line_to_add.strip().rstrip(\",\"):\n        print(f\"{PYRIGHT_CONFIG} already up-to-date\")\n        return\n    if i == initial:\n        # Special case: when adding to the end of the list, commas need tweaking\n        line_to_add = line_to_add.rstrip(\",\")\n        lines[i] = lines[i].rstrip() + \",\\n\"\n    lines.insert(i + 1, line_to_add + \"\\n\")\n    print(f\"Updating {PYRIGHT_CONFIG}\")\n    with open(PYRIGHT_CONFIG, \"w\", encoding=\"UTF-8\") as f:\n        f.writelines(lines)\n\n\ndef main() -> None:\n    parser = argparse.ArgumentParser(\n        description=\"\"\"Generate baseline stubs automatically for an installed pip package\n                       using stubgen. Also run black and isort. If the name of\n                       the project is different from the runtime Python package name, you may\n                       need to use --package (example: --package yaml PyYAML).\"\"\"\n    )\n    parser.add_argument(\"project\", help=\"name of PyPI project for which to generate stubs under stubs/\")\n    parser.add_argument(\"--package\", help=\"generate stubs for this Python package (default is autodetected)\")\n    args = parser.parse_args()\n    project = args.project\n    package = args.package\n\n    if not re.match(r\"[a-zA-Z0-9-_.]+$\", project):\n        sys.exit(f\"Invalid character in project name: {project!r}\")\n\n    if not package:\n        package = project  # default\n        # Try to find which packages are provided by the project\n        # Use default if that fails or if several packages are found\n        #\n        # The importlib.metadata module is used for projects whose name is different\n        # from the runtime Python package name (example: PyYAML/yaml)\n        if sys.version_info >= (3, 8):\n            dist = distribution(project).read_text(\"top_level.txt\")\n            if dist is not None:\n                packages = [name for name in dist.split() if not name.startswith(\"_\")]\n                if len(packages) == 1:\n                    package = packages[0]\n        print(f'Using detected package \"{package}\" for project \"{project}\"', file=sys.stderr)\n        print(\"Suggestion: Try again with --package argument if that's not what you wanted\", file=sys.stderr)\n\n    if not os.path.isdir(\"stubs\") or not os.path.isdir(\"stdlib\"):\n        sys.exit(\"Error: Current working directory must be the root of typeshed repository\")\n\n    # Get normalized project name and version of installed package.\n    info = get_installed_package_info(project)\n    if info is None:\n        print(f'Error: \"{project}\" is not installed', file=sys.stderr)\n        print(\"\", file=sys.stderr)\n        print(f'Suggestion: Run \"python3 -m pip install {project}\" and try again', file=sys.stderr)\n        sys.exit(1)\n    project, version = info\n\n    stub_dir = os.path.join(\"stubs\", project)\n    package_dir = os.path.join(stub_dir, package)\n    if os.path.exists(package_dir):\n        sys.exit(f\"Error: {package_dir} already exists (delete it first)\")\n\n    run_stubgen(package, stub_dir)\n\n    run_isort(stub_dir)\n    run_black(stub_dir)\n\n    create_metadata(stub_dir, version)\n\n    # Since the generated stubs won't have many type annotations, we\n    # have to exclude them from strict pyright checks.\n    add_pyright_exclusion(stub_dir)\n\n    print(\"\\nDone!\\n\\nSuggested next steps:\")\n    print(f\" 1. Manually review the generated stubs in {stub_dir}\")\n    print(\" 2. Optionally run tests and autofixes (see tests/README.md for details)\")\n    print(\" 3. Commit the changes on a new branch and create a typeshed PR (don't force-push!)\")\n\n\nif __name__ == \"__main__\":\n    main()\n", "path": "scripts/create_baseline_stubs.py"}]}