We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Ignore __pypackages__ directory contents
**Describe the bug**

When using [PDM](https://pdm.fming.dev/), `black` does not ignore `__pypackages__` directory contents.

**To Reproduce**

Run `pdm run black .`

**Expected behavior**

`black` should reformat only project files.

**Environment**

- Black's version: 22.1.0
- PDM version: 1.12.6
- OS and Python version: Ubuntu 21.10 with Python 3.10.1


--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `src/black/const.py`
Content:
```
1 DEFAULT_LINE_LENGTH = 88
2 DEFAULT_EXCLUDES = r"/(\.direnv|\.eggs|\.git|\.hg|\.mypy_cache|\.nox|\.tox|\.venv|venv|\.svn|_build|buck-out|build|dist)/"  # noqa: B950
3 DEFAULT_INCLUDES = r"(\.pyi?|\.ipynb)$"
4 STDIN_PLACEHOLDER = "__BLACK_STDIN_FILENAME__"
5
```
--- 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/src/black/const.py b/src/black/const.py
--- a/src/black/const.py
+++ b/src/black/const.py
@@ -1,4 +1,4 @@
 DEFAULT_LINE_LENGTH = 88
-DEFAULT_EXCLUDES = r"/(\.direnv|\.eggs|\.git|\.hg|\.mypy_cache|\.nox|\.tox|\.venv|venv|\.svn|_build|buck-out|build|dist)/"  # noqa: B950
+DEFAULT_EXCLUDES = r"/(\.direnv|\.eggs|\.git|\.hg|\.mypy_cache|\.nox|\.tox|\.venv|venv|\.svn|_build|buck-out|build|dist|__pypackages__)/"  # noqa: B950
 DEFAULT_INCLUDES = r"(\.pyi?|\.ipynb)$"
 STDIN_PLACEHOLDER = "__BLACK_STDIN_FILENAME__"

{"golden_diff": "diff --git a/src/black/const.py b/src/black/const.py\n--- a/src/black/const.py\n+++ b/src/black/const.py\n@@ -1,4 +1,4 @@\n DEFAULT_LINE_LENGTH = 88\n-DEFAULT_EXCLUDES = r\"/(\\.direnv|\\.eggs|\\.git|\\.hg|\\.mypy_cache|\\.nox|\\.tox|\\.venv|venv|\\.svn|_build|buck-out|build|dist)/\"  # noqa: B950\n+DEFAULT_EXCLUDES = r\"/(\\.direnv|\\.eggs|\\.git|\\.hg|\\.mypy_cache|\\.nox|\\.tox|\\.venv|venv|\\.svn|_build|buck-out|build|dist|__pypackages__)/\"  # noqa: B950\n DEFAULT_INCLUDES = r\"(\\.pyi?|\\.ipynb)$\"\n STDIN_PLACEHOLDER = \"__BLACK_STDIN_FILENAME__\"\n", "issue": "Ignore __pypackages__ directory contents\n**Describe the bug**\r\n\r\nWhen using [PDM](https://pdm.fming.dev/), `black` does not ignore `__pypackages__` directory contents.\r\n\r\n**To Reproduce**\r\n\r\nRun `pdm run black .`\r\n\r\n**Expected behavior**\r\n\r\n`black` should reformat only project files.\r\n\r\n**Environment**\r\n\r\n- Black's version: 22.1.0\r\n- PDM version: 1.12.6\r\n- OS and Python version: Ubuntu 21.10 with Python 3.10.1\r\n\n", "before_files": [{"content": "DEFAULT_LINE_LENGTH = 88\nDEFAULT_EXCLUDES = r\"/(\\.direnv|\\.eggs|\\.git|\\.hg|\\.mypy_cache|\\.nox|\\.tox|\\.venv|venv|\\.svn|_build|buck-out|build|dist)/\"  # noqa: B950\nDEFAULT_INCLUDES = r\"(\\.pyi?|\\.ipynb)$\"\nSTDIN_PLACEHOLDER = \"__BLACK_STDIN_FILENAME__\"\n", "path": "src/black/const.py"}], "after_files": [{"content": "DEFAULT_LINE_LENGTH = 88\nDEFAULT_EXCLUDES = r\"/(\\.direnv|\\.eggs|\\.git|\\.hg|\\.mypy_cache|\\.nox|\\.tox|\\.venv|venv|\\.svn|_build|buck-out|build|dist|__pypackages__)/\"  # noqa: B950\nDEFAULT_INCLUDES = r\"(\\.pyi?|\\.ipynb)$\"\nSTDIN_PLACEHOLDER = \"__BLACK_STDIN_FILENAME__\"\n", "path": "src/black/const.py"}]}