We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
ERROR: No matching distribution found for opentelemetry-instrumentation-aiohttp-server==0.42b0
Python Version - 3.8

**Steps to reproduce**
Using 'opentelemetry-bootstrap -a install' Command to Install the Dependencies for Auto Instrumentation.

**What is the expected behavior?**
package : opentelemetry-instrumentation-aiohttp-server==0.42b0 should be downloaded from pypi

**What is the actual behavior?**
ERROR: No matching distribution found for opentelemetry-instrumentation-aiohttp-server==0.42b0


--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py`
Content:
```
1 # Copyright The OpenTelemetry Authors
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 #     http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14 
15 # DO NOT EDIT. THIS FILE WAS AUTOGENERATED FROM INSTRUMENTATION PACKAGES.
16 # RUN `python scripts/generate_instrumentation_bootstrap.py` TO REGENERATE.
17 
18 libraries = [
19     {
20         "library": "aio_pika >= 7.2.0, < 10.0.0",
21         "instrumentation": "opentelemetry-instrumentation-aio-pika==0.46b0.dev",
22     },
23     {
24         "library": "aiohttp ~= 3.0",
25         "instrumentation": "opentelemetry-instrumentation-aiohttp-client==0.46b0.dev",
26     },
27     {
28         "library": "aiohttp ~= 3.0",
29         "instrumentation": "opentelemetry-instrumentation-aiohttp-server==0.46b0.dev",
30     },
31     {
32         "library": "aiopg >= 0.13.0, < 2.0.0",
33         "instrumentation": "opentelemetry-instrumentation-aiopg==0.46b0.dev",
34     },
35     {
36         "library": "asgiref ~= 3.0",
37         "instrumentation": "opentelemetry-instrumentation-asgi==0.46b0.dev",
38     },
39     {
40         "library": "asyncpg >= 0.12.0",
41         "instrumentation": "opentelemetry-instrumentation-asyncpg==0.46b0.dev",
42     },
43     {
44         "library": "boto~=2.0",
45         "instrumentation": "opentelemetry-instrumentation-boto==0.46b0.dev",
46     },
47     {
48         "library": "boto3 ~= 1.0",
49         "instrumentation": "opentelemetry-instrumentation-boto3sqs==0.46b0.dev",
50     },
51     {
52         "library": "botocore ~= 1.0",
53         "instrumentation": "opentelemetry-instrumentation-botocore==0.46b0.dev",
54     },
55     {
56         "library": "cassandra-driver ~= 3.25",
57         "instrumentation": "opentelemetry-instrumentation-cassandra==0.46b0.dev",
58     },
59     {
60         "library": "scylla-driver ~= 3.25",
61         "instrumentation": "opentelemetry-instrumentation-cassandra==0.46b0.dev",
62     },
63     {
64         "library": "celery >= 4.0, < 6.0",
65         "instrumentation": "opentelemetry-instrumentation-celery==0.46b0.dev",
66     },
67     {
68         "library": "confluent-kafka >= 1.8.2, <= 2.3.0",
69         "instrumentation": "opentelemetry-instrumentation-confluent-kafka==0.46b0.dev",
70     },
71     {
72         "library": "django >= 1.10",
73         "instrumentation": "opentelemetry-instrumentation-django==0.46b0.dev",
74     },
75     {
76         "library": "elasticsearch >= 6.0",
77         "instrumentation": "opentelemetry-instrumentation-elasticsearch==0.46b0.dev",
78     },
79     {
80         "library": "falcon >= 1.4.1, < 3.1.2",
81         "instrumentation": "opentelemetry-instrumentation-falcon==0.46b0.dev",
82     },
83     {
84         "library": "fastapi ~= 0.58",
85         "instrumentation": "opentelemetry-instrumentation-fastapi==0.46b0.dev",
86     },
87     {
88         "library": "flask >= 1.0",
89         "instrumentation": "opentelemetry-instrumentation-flask==0.46b0.dev",
90     },
91     {
92         "library": "grpcio ~= 1.27",
93         "instrumentation": "opentelemetry-instrumentation-grpc==0.46b0.dev",
94     },
95     {
96         "library": "httpx >= 0.18.0",
97         "instrumentation": "opentelemetry-instrumentation-httpx==0.46b0.dev",
98     },
99     {
100         "library": "jinja2 >= 2.7, < 4.0",
101         "instrumentation": "opentelemetry-instrumentation-jinja2==0.46b0.dev",
102     },
103     {
104         "library": "kafka-python >= 2.0",
105         "instrumentation": "opentelemetry-instrumentation-kafka-python==0.46b0.dev",
106     },
107     {
108         "library": "mysql-connector-python ~= 8.0",
109         "instrumentation": "opentelemetry-instrumentation-mysql==0.46b0.dev",
110     },
111     {
112         "library": "mysqlclient < 3",
113         "instrumentation": "opentelemetry-instrumentation-mysqlclient==0.46b0.dev",
114     },
115     {
116         "library": "pika >= 0.12.0",
117         "instrumentation": "opentelemetry-instrumentation-pika==0.46b0.dev",
118     },
119     {
120         "library": "psycopg >= 3.1.0",
121         "instrumentation": "opentelemetry-instrumentation-psycopg==0.46b0.dev",
122     },
123     {
124         "library": "psycopg2 >= 2.7.3.1",
125         "instrumentation": "opentelemetry-instrumentation-psycopg2==0.46b0.dev",
126     },
127     {
128         "library": "pymemcache >= 1.3.5, < 5",
129         "instrumentation": "opentelemetry-instrumentation-pymemcache==0.46b0.dev",
130     },
131     {
132         "library": "pymongo >= 3.1, < 5.0",
133         "instrumentation": "opentelemetry-instrumentation-pymongo==0.46b0.dev",
134     },
135     {
136         "library": "PyMySQL < 2",
137         "instrumentation": "opentelemetry-instrumentation-pymysql==0.46b0.dev",
138     },
139     {
140         "library": "pyramid >= 1.7",
141         "instrumentation": "opentelemetry-instrumentation-pyramid==0.46b0.dev",
142     },
143     {
144         "library": "redis >= 2.6",
145         "instrumentation": "opentelemetry-instrumentation-redis==0.46b0.dev",
146     },
147     {
148         "library": "remoulade >= 0.50",
149         "instrumentation": "opentelemetry-instrumentation-remoulade==0.46b0.dev",
150     },
151     {
152         "library": "requests ~= 2.0",
153         "instrumentation": "opentelemetry-instrumentation-requests==0.46b0.dev",
154     },
155     {
156         "library": "scikit-learn ~= 0.24.0",
157         "instrumentation": "opentelemetry-instrumentation-sklearn==0.46b0.dev",
158     },
159     {
160         "library": "sqlalchemy",
161         "instrumentation": "opentelemetry-instrumentation-sqlalchemy==0.46b0.dev",
162     },
163     {
164         "library": "starlette ~= 0.13.0",
165         "instrumentation": "opentelemetry-instrumentation-starlette==0.46b0.dev",
166     },
167     {
168         "library": "psutil >= 5",
169         "instrumentation": "opentelemetry-instrumentation-system-metrics==0.46b0.dev",
170     },
171     {
172         "library": "tornado >= 5.1.1",
173         "instrumentation": "opentelemetry-instrumentation-tornado==0.46b0.dev",
174     },
175     {
176         "library": "tortoise-orm >= 0.17.0",
177         "instrumentation": "opentelemetry-instrumentation-tortoiseorm==0.46b0.dev",
178     },
179     {
180         "library": "pydantic >= 1.10.2",
181         "instrumentation": "opentelemetry-instrumentation-tortoiseorm==0.46b0.dev",
182     },
183     {
184         "library": "urllib3 >= 1.0.0, < 3.0.0",
185         "instrumentation": "opentelemetry-instrumentation-urllib3==0.46b0.dev",
186     },
187 ]
188 default_instrumentations = [
189     "opentelemetry-instrumentation-asyncio==0.46b0.dev",
190     "opentelemetry-instrumentation-aws-lambda==0.46b0.dev",
191     "opentelemetry-instrumentation-dbapi==0.46b0.dev",
192     "opentelemetry-instrumentation-logging==0.46b0.dev",
193     "opentelemetry-instrumentation-sqlite3==0.46b0.dev",
194     "opentelemetry-instrumentation-threading==0.46b0.dev",
195     "opentelemetry-instrumentation-urllib==0.46b0.dev",
196     "opentelemetry-instrumentation-wsgi==0.46b0.dev",
197 ]
198
```

Path: `scripts/otel_packaging.py`
Content:
```
1 # Copyright The OpenTelemetry Authors
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 #     http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14 
15 import os
16 import subprocess
17 from subprocess import CalledProcessError
18 
19 import tomli
20 
21 scripts_path = os.path.dirname(os.path.abspath(__file__))
22 root_path = os.path.dirname(scripts_path)
23 instrumentations_path = os.path.join(root_path, "instrumentation")
24 
25 
26 def get_instrumentation_packages():
27     for pkg in sorted(os.listdir(instrumentations_path)):
28         pkg_path = os.path.join(instrumentations_path, pkg)
29         if not os.path.isdir(pkg_path):
30             continue
31 
32         try:
33             version = subprocess.check_output(
34                 "hatch version",
35                 shell=True,
36                 cwd=pkg_path,
37                 universal_newlines=True,
38             )
39         except CalledProcessError as exc:
40             print(f"Could not get hatch version from path {pkg_path}")
41             print(exc.output)
42             raise exc
43 
44         pyproject_toml_path = os.path.join(pkg_path, "pyproject.toml")
45 
46         with open(pyproject_toml_path, "rb") as file:
47             pyproject_toml = tomli.load(file)
48 
49         instrumentation = {
50             "name": pyproject_toml["project"]["name"],
51             "version": version.strip(),
52             "instruments": pyproject_toml["project"]["optional-dependencies"][
53                 "instruments"
54             ],
55         }
56         instrumentation["requirement"] = "==".join(
57             (
58                 instrumentation["name"],
59                 instrumentation["version"],
60             )
61         )
62         yield instrumentation
63 
64 
65 if __name__ == "__main__":
66     print(list(get_instrumentation_packages()))
67
```
--- 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/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py b/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py
--- a/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py
+++ b/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py
@@ -24,10 +24,6 @@
         "library": "aiohttp ~= 3.0",
         "instrumentation": "opentelemetry-instrumentation-aiohttp-client==0.46b0.dev",
     },
-    {
-        "library": "aiohttp ~= 3.0",
-        "instrumentation": "opentelemetry-instrumentation-aiohttp-server==0.46b0.dev",
-    },
     {
         "library": "aiopg >= 0.13.0, < 2.0.0",
         "instrumentation": "opentelemetry-instrumentation-aiopg==0.46b0.dev",
@@ -191,7 +187,6 @@
     "opentelemetry-instrumentation-dbapi==0.46b0.dev",
     "opentelemetry-instrumentation-logging==0.46b0.dev",
     "opentelemetry-instrumentation-sqlite3==0.46b0.dev",
-    "opentelemetry-instrumentation-threading==0.46b0.dev",
     "opentelemetry-instrumentation-urllib==0.46b0.dev",
     "opentelemetry-instrumentation-wsgi==0.46b0.dev",
 ]
diff --git a/scripts/otel_packaging.py b/scripts/otel_packaging.py
--- a/scripts/otel_packaging.py
+++ b/scripts/otel_packaging.py
@@ -12,43 +12,55 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-import os
-import subprocess
-from subprocess import CalledProcessError
+from tomli import load
+from os import path, listdir
+from subprocess import check_output, CalledProcessError
+from requests import get
 
-import tomli
-
-scripts_path = os.path.dirname(os.path.abspath(__file__))
-root_path = os.path.dirname(scripts_path)
-instrumentations_path = os.path.join(root_path, "instrumentation")
+scripts_path = path.dirname(path.abspath(__file__))
+root_path = path.dirname(scripts_path)
+instrumentations_path = path.join(root_path, "instrumentation")
 
 
 def get_instrumentation_packages():
-    for pkg in sorted(os.listdir(instrumentations_path)):
-        pkg_path = os.path.join(instrumentations_path, pkg)
-        if not os.path.isdir(pkg_path):
+    for pkg in sorted(listdir(instrumentations_path)):
+        pkg_path = path.join(instrumentations_path, pkg)
+        if not path.isdir(pkg_path):
             continue
 
+        error = f"Could not get version for package {pkg}"
+
         try:
-            version = subprocess.check_output(
+            hatch_version = check_output(
                 "hatch version",
                 shell=True,
                 cwd=pkg_path,
-                universal_newlines=True,
+                universal_newlines=True
             )
+
         except CalledProcessError as exc:
             print(f"Could not get hatch version from path {pkg_path}")
             print(exc.output)
-            raise exc
 
-        pyproject_toml_path = os.path.join(pkg_path, "pyproject.toml")
+        try:
+            response = get(f"https://pypi.org/pypi/{pkg}/json", timeout=10)
+
+        except Exception:
+            print(error)
+            continue
+
+        if response.status_code != 200:
+            print(error)
+            continue
+
+        pyproject_toml_path = path.join(pkg_path, "pyproject.toml")
 
         with open(pyproject_toml_path, "rb") as file:
-            pyproject_toml = tomli.load(file)
+            pyproject_toml = load(file)
 
         instrumentation = {
             "name": pyproject_toml["project"]["name"],
-            "version": version.strip(),
+            "version": hatch_version.strip(),
             "instruments": pyproject_toml["project"]["optional-dependencies"][
                 "instruments"
             ],

{"golden_diff": "diff --git a/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py b/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py\n--- a/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py\n+++ b/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py\n@@ -24,10 +24,6 @@\n         \"library\": \"aiohttp ~= 3.0\",\n         \"instrumentation\": \"opentelemetry-instrumentation-aiohttp-client==0.46b0.dev\",\n     },\n-    {\n-        \"library\": \"aiohttp ~= 3.0\",\n-        \"instrumentation\": \"opentelemetry-instrumentation-aiohttp-server==0.46b0.dev\",\n-    },\n     {\n         \"library\": \"aiopg >= 0.13.0, < 2.0.0\",\n         \"instrumentation\": \"opentelemetry-instrumentation-aiopg==0.46b0.dev\",\n@@ -191,7 +187,6 @@\n     \"opentelemetry-instrumentation-dbapi==0.46b0.dev\",\n     \"opentelemetry-instrumentation-logging==0.46b0.dev\",\n     \"opentelemetry-instrumentation-sqlite3==0.46b0.dev\",\n-    \"opentelemetry-instrumentation-threading==0.46b0.dev\",\n     \"opentelemetry-instrumentation-urllib==0.46b0.dev\",\n     \"opentelemetry-instrumentation-wsgi==0.46b0.dev\",\n ]\ndiff --git a/scripts/otel_packaging.py b/scripts/otel_packaging.py\n--- a/scripts/otel_packaging.py\n+++ b/scripts/otel_packaging.py\n@@ -12,43 +12,55 @@\n # See the License for the specific language governing permissions and\n # limitations under the License.\n \n-import os\n-import subprocess\n-from subprocess import CalledProcessError\n+from tomli import load\n+from os import path, listdir\n+from subprocess import check_output, CalledProcessError\n+from requests import get\n \n-import tomli\n-\n-scripts_path = os.path.dirname(os.path.abspath(__file__))\n-root_path = os.path.dirname(scripts_path)\n-instrumentations_path = os.path.join(root_path, \"instrumentation\")\n+scripts_path = path.dirname(path.abspath(__file__))\n+root_path = path.dirname(scripts_path)\n+instrumentations_path = path.join(root_path, \"instrumentation\")\n \n \n def get_instrumentation_packages():\n-    for pkg in sorted(os.listdir(instrumentations_path)):\n-        pkg_path = os.path.join(instrumentations_path, pkg)\n-        if not os.path.isdir(pkg_path):\n+    for pkg in sorted(listdir(instrumentations_path)):\n+        pkg_path = path.join(instrumentations_path, pkg)\n+        if not path.isdir(pkg_path):\n             continue\n \n+        error = f\"Could not get version for package {pkg}\"\n+\n         try:\n-            version = subprocess.check_output(\n+            hatch_version = check_output(\n                 \"hatch version\",\n                 shell=True,\n                 cwd=pkg_path,\n-                universal_newlines=True,\n+                universal_newlines=True\n             )\n+\n         except CalledProcessError as exc:\n             print(f\"Could not get hatch version from path {pkg_path}\")\n             print(exc.output)\n-            raise exc\n \n-        pyproject_toml_path = os.path.join(pkg_path, \"pyproject.toml\")\n+        try:\n+            response = get(f\"https://pypi.org/pypi/{pkg}/json\", timeout=10)\n+\n+        except Exception:\n+            print(error)\n+            continue\n+\n+        if response.status_code != 200:\n+            print(error)\n+            continue\n+\n+        pyproject_toml_path = path.join(pkg_path, \"pyproject.toml\")\n \n         with open(pyproject_toml_path, \"rb\") as file:\n-            pyproject_toml = tomli.load(file)\n+            pyproject_toml = load(file)\n \n         instrumentation = {\n             \"name\": pyproject_toml[\"project\"][\"name\"],\n-            \"version\": version.strip(),\n+            \"version\": hatch_version.strip(),\n             \"instruments\": pyproject_toml[\"project\"][\"optional-dependencies\"][\n                 \"instruments\"\n             ],\n", "issue": "ERROR: No matching distribution found for opentelemetry-instrumentation-aiohttp-server==0.42b0\nPython Version - 3.8\r\n\r\n**Steps to reproduce**\r\nUsing 'opentelemetry-bootstrap -a install' Command to Install the Dependencies for Auto Instrumentation.\r\n\r\n**What is the expected behavior?**\r\npackage : opentelemetry-instrumentation-aiohttp-server==0.42b0 should be downloaded from pypi\r\n\r\n**What is the actual behavior?**\r\nERROR: No matching distribution found for opentelemetry-instrumentation-aiohttp-server==0.42b0\r\n\n", "before_files": [{"content": "# Copyright The OpenTelemetry Authors\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#     http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n\n# DO NOT EDIT. THIS FILE WAS AUTOGENERATED FROM INSTRUMENTATION PACKAGES.\n# RUN `python scripts/generate_instrumentation_bootstrap.py` TO REGENERATE.\n\nlibraries = [\n    {\n        \"library\": \"aio_pika >= 7.2.0, < 10.0.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-aio-pika==0.46b0.dev\",\n    },\n    {\n        \"library\": \"aiohttp ~= 3.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-aiohttp-client==0.46b0.dev\",\n    },\n    {\n        \"library\": \"aiohttp ~= 3.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-aiohttp-server==0.46b0.dev\",\n    },\n    {\n        \"library\": \"aiopg >= 0.13.0, < 2.0.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-aiopg==0.46b0.dev\",\n    },\n    {\n        \"library\": \"asgiref ~= 3.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-asgi==0.46b0.dev\",\n    },\n    {\n        \"library\": \"asyncpg >= 0.12.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-asyncpg==0.46b0.dev\",\n    },\n    {\n        \"library\": \"boto~=2.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-boto==0.46b0.dev\",\n    },\n    {\n        \"library\": \"boto3 ~= 1.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-boto3sqs==0.46b0.dev\",\n    },\n    {\n        \"library\": \"botocore ~= 1.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-botocore==0.46b0.dev\",\n    },\n    {\n        \"library\": \"cassandra-driver ~= 3.25\",\n        \"instrumentation\": \"opentelemetry-instrumentation-cassandra==0.46b0.dev\",\n    },\n    {\n        \"library\": \"scylla-driver ~= 3.25\",\n        \"instrumentation\": \"opentelemetry-instrumentation-cassandra==0.46b0.dev\",\n    },\n    {\n        \"library\": \"celery >= 4.0, < 6.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-celery==0.46b0.dev\",\n    },\n    {\n        \"library\": \"confluent-kafka >= 1.8.2, <= 2.3.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-confluent-kafka==0.46b0.dev\",\n    },\n    {\n        \"library\": \"django >= 1.10\",\n        \"instrumentation\": \"opentelemetry-instrumentation-django==0.46b0.dev\",\n    },\n    {\n        \"library\": \"elasticsearch >= 6.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-elasticsearch==0.46b0.dev\",\n    },\n    {\n        \"library\": \"falcon >= 1.4.1, < 3.1.2\",\n        \"instrumentation\": \"opentelemetry-instrumentation-falcon==0.46b0.dev\",\n    },\n    {\n        \"library\": \"fastapi ~= 0.58\",\n        \"instrumentation\": \"opentelemetry-instrumentation-fastapi==0.46b0.dev\",\n    },\n    {\n        \"library\": \"flask >= 1.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-flask==0.46b0.dev\",\n    },\n    {\n        \"library\": \"grpcio ~= 1.27\",\n        \"instrumentation\": \"opentelemetry-instrumentation-grpc==0.46b0.dev\",\n    },\n    {\n        \"library\": \"httpx >= 0.18.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-httpx==0.46b0.dev\",\n    },\n    {\n        \"library\": \"jinja2 >= 2.7, < 4.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-jinja2==0.46b0.dev\",\n    },\n    {\n        \"library\": \"kafka-python >= 2.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-kafka-python==0.46b0.dev\",\n    },\n    {\n        \"library\": \"mysql-connector-python ~= 8.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-mysql==0.46b0.dev\",\n    },\n    {\n        \"library\": \"mysqlclient < 3\",\n        \"instrumentation\": \"opentelemetry-instrumentation-mysqlclient==0.46b0.dev\",\n    },\n    {\n        \"library\": \"pika >= 0.12.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-pika==0.46b0.dev\",\n    },\n    {\n        \"library\": \"psycopg >= 3.1.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-psycopg==0.46b0.dev\",\n    },\n    {\n        \"library\": \"psycopg2 >= 2.7.3.1\",\n        \"instrumentation\": \"opentelemetry-instrumentation-psycopg2==0.46b0.dev\",\n    },\n    {\n        \"library\": \"pymemcache >= 1.3.5, < 5\",\n        \"instrumentation\": \"opentelemetry-instrumentation-pymemcache==0.46b0.dev\",\n    },\n    {\n        \"library\": \"pymongo >= 3.1, < 5.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-pymongo==0.46b0.dev\",\n    },\n    {\n        \"library\": \"PyMySQL < 2\",\n        \"instrumentation\": \"opentelemetry-instrumentation-pymysql==0.46b0.dev\",\n    },\n    {\n        \"library\": \"pyramid >= 1.7\",\n        \"instrumentation\": \"opentelemetry-instrumentation-pyramid==0.46b0.dev\",\n    },\n    {\n        \"library\": \"redis >= 2.6\",\n        \"instrumentation\": \"opentelemetry-instrumentation-redis==0.46b0.dev\",\n    },\n    {\n        \"library\": \"remoulade >= 0.50\",\n        \"instrumentation\": \"opentelemetry-instrumentation-remoulade==0.46b0.dev\",\n    },\n    {\n        \"library\": \"requests ~= 2.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-requests==0.46b0.dev\",\n    },\n    {\n        \"library\": \"scikit-learn ~= 0.24.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-sklearn==0.46b0.dev\",\n    },\n    {\n        \"library\": \"sqlalchemy\",\n        \"instrumentation\": \"opentelemetry-instrumentation-sqlalchemy==0.46b0.dev\",\n    },\n    {\n        \"library\": \"starlette ~= 0.13.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-starlette==0.46b0.dev\",\n    },\n    {\n        \"library\": \"psutil >= 5\",\n        \"instrumentation\": \"opentelemetry-instrumentation-system-metrics==0.46b0.dev\",\n    },\n    {\n        \"library\": \"tornado >= 5.1.1\",\n        \"instrumentation\": \"opentelemetry-instrumentation-tornado==0.46b0.dev\",\n    },\n    {\n        \"library\": \"tortoise-orm >= 0.17.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-tortoiseorm==0.46b0.dev\",\n    },\n    {\n        \"library\": \"pydantic >= 1.10.2\",\n        \"instrumentation\": \"opentelemetry-instrumentation-tortoiseorm==0.46b0.dev\",\n    },\n    {\n        \"library\": \"urllib3 >= 1.0.0, < 3.0.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-urllib3==0.46b0.dev\",\n    },\n]\ndefault_instrumentations = [\n    \"opentelemetry-instrumentation-asyncio==0.46b0.dev\",\n    \"opentelemetry-instrumentation-aws-lambda==0.46b0.dev\",\n    \"opentelemetry-instrumentation-dbapi==0.46b0.dev\",\n    \"opentelemetry-instrumentation-logging==0.46b0.dev\",\n    \"opentelemetry-instrumentation-sqlite3==0.46b0.dev\",\n    \"opentelemetry-instrumentation-threading==0.46b0.dev\",\n    \"opentelemetry-instrumentation-urllib==0.46b0.dev\",\n    \"opentelemetry-instrumentation-wsgi==0.46b0.dev\",\n]\n", "path": "opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py"}, {"content": "# Copyright The OpenTelemetry Authors\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#     http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n\nimport os\nimport subprocess\nfrom subprocess import CalledProcessError\n\nimport tomli\n\nscripts_path = os.path.dirname(os.path.abspath(__file__))\nroot_path = os.path.dirname(scripts_path)\ninstrumentations_path = os.path.join(root_path, \"instrumentation\")\n\n\ndef get_instrumentation_packages():\n    for pkg in sorted(os.listdir(instrumentations_path)):\n        pkg_path = os.path.join(instrumentations_path, pkg)\n        if not os.path.isdir(pkg_path):\n            continue\n\n        try:\n            version = subprocess.check_output(\n                \"hatch version\",\n                shell=True,\n                cwd=pkg_path,\n                universal_newlines=True,\n            )\n        except CalledProcessError as exc:\n            print(f\"Could not get hatch version from path {pkg_path}\")\n            print(exc.output)\n            raise exc\n\n        pyproject_toml_path = os.path.join(pkg_path, \"pyproject.toml\")\n\n        with open(pyproject_toml_path, \"rb\") as file:\n            pyproject_toml = tomli.load(file)\n\n        instrumentation = {\n            \"name\": pyproject_toml[\"project\"][\"name\"],\n            \"version\": version.strip(),\n            \"instruments\": pyproject_toml[\"project\"][\"optional-dependencies\"][\n                \"instruments\"\n            ],\n        }\n        instrumentation[\"requirement\"] = \"==\".join(\n            (\n                instrumentation[\"name\"],\n                instrumentation[\"version\"],\n            )\n        )\n        yield instrumentation\n\n\nif __name__ == \"__main__\":\n    print(list(get_instrumentation_packages()))\n", "path": "scripts/otel_packaging.py"}], "after_files": [{"content": "# Copyright The OpenTelemetry Authors\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#     http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n\n# DO NOT EDIT. THIS FILE WAS AUTOGENERATED FROM INSTRUMENTATION PACKAGES.\n# RUN `python scripts/generate_instrumentation_bootstrap.py` TO REGENERATE.\n\nlibraries = [\n    {\n        \"library\": \"aio_pika >= 7.2.0, < 10.0.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-aio-pika==0.46b0.dev\",\n    },\n    {\n        \"library\": \"aiohttp ~= 3.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-aiohttp-client==0.46b0.dev\",\n    },\n    {\n        \"library\": \"aiopg >= 0.13.0, < 2.0.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-aiopg==0.46b0.dev\",\n    },\n    {\n        \"library\": \"asgiref ~= 3.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-asgi==0.46b0.dev\",\n    },\n    {\n        \"library\": \"asyncpg >= 0.12.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-asyncpg==0.46b0.dev\",\n    },\n    {\n        \"library\": \"boto~=2.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-boto==0.46b0.dev\",\n    },\n    {\n        \"library\": \"boto3 ~= 1.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-boto3sqs==0.46b0.dev\",\n    },\n    {\n        \"library\": \"botocore ~= 1.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-botocore==0.46b0.dev\",\n    },\n    {\n        \"library\": \"cassandra-driver ~= 3.25\",\n        \"instrumentation\": \"opentelemetry-instrumentation-cassandra==0.46b0.dev\",\n    },\n    {\n        \"library\": \"scylla-driver ~= 3.25\",\n        \"instrumentation\": \"opentelemetry-instrumentation-cassandra==0.46b0.dev\",\n    },\n    {\n        \"library\": \"celery >= 4.0, < 6.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-celery==0.46b0.dev\",\n    },\n    {\n        \"library\": \"confluent-kafka >= 1.8.2, <= 2.3.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-confluent-kafka==0.46b0.dev\",\n    },\n    {\n        \"library\": \"django >= 1.10\",\n        \"instrumentation\": \"opentelemetry-instrumentation-django==0.46b0.dev\",\n    },\n    {\n        \"library\": \"elasticsearch >= 6.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-elasticsearch==0.46b0.dev\",\n    },\n    {\n        \"library\": \"falcon >= 1.4.1, < 3.1.2\",\n        \"instrumentation\": \"opentelemetry-instrumentation-falcon==0.46b0.dev\",\n    },\n    {\n        \"library\": \"fastapi ~= 0.58\",\n        \"instrumentation\": \"opentelemetry-instrumentation-fastapi==0.46b0.dev\",\n    },\n    {\n        \"library\": \"flask >= 1.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-flask==0.46b0.dev\",\n    },\n    {\n        \"library\": \"grpcio ~= 1.27\",\n        \"instrumentation\": \"opentelemetry-instrumentation-grpc==0.46b0.dev\",\n    },\n    {\n        \"library\": \"httpx >= 0.18.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-httpx==0.46b0.dev\",\n    },\n    {\n        \"library\": \"jinja2 >= 2.7, < 4.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-jinja2==0.46b0.dev\",\n    },\n    {\n        \"library\": \"kafka-python >= 2.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-kafka-python==0.46b0.dev\",\n    },\n    {\n        \"library\": \"mysql-connector-python ~= 8.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-mysql==0.46b0.dev\",\n    },\n    {\n        \"library\": \"mysqlclient < 3\",\n        \"instrumentation\": \"opentelemetry-instrumentation-mysqlclient==0.46b0.dev\",\n    },\n    {\n        \"library\": \"pika >= 0.12.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-pika==0.46b0.dev\",\n    },\n    {\n        \"library\": \"psycopg >= 3.1.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-psycopg==0.46b0.dev\",\n    },\n    {\n        \"library\": \"psycopg2 >= 2.7.3.1\",\n        \"instrumentation\": \"opentelemetry-instrumentation-psycopg2==0.46b0.dev\",\n    },\n    {\n        \"library\": \"pymemcache >= 1.3.5, < 5\",\n        \"instrumentation\": \"opentelemetry-instrumentation-pymemcache==0.46b0.dev\",\n    },\n    {\n        \"library\": \"pymongo >= 3.1, < 5.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-pymongo==0.46b0.dev\",\n    },\n    {\n        \"library\": \"PyMySQL < 2\",\n        \"instrumentation\": \"opentelemetry-instrumentation-pymysql==0.46b0.dev\",\n    },\n    {\n        \"library\": \"pyramid >= 1.7\",\n        \"instrumentation\": \"opentelemetry-instrumentation-pyramid==0.46b0.dev\",\n    },\n    {\n        \"library\": \"redis >= 2.6\",\n        \"instrumentation\": \"opentelemetry-instrumentation-redis==0.46b0.dev\",\n    },\n    {\n        \"library\": \"remoulade >= 0.50\",\n        \"instrumentation\": \"opentelemetry-instrumentation-remoulade==0.46b0.dev\",\n    },\n    {\n        \"library\": \"requests ~= 2.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-requests==0.46b0.dev\",\n    },\n    {\n        \"library\": \"scikit-learn ~= 0.24.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-sklearn==0.46b0.dev\",\n    },\n    {\n        \"library\": \"sqlalchemy\",\n        \"instrumentation\": \"opentelemetry-instrumentation-sqlalchemy==0.46b0.dev\",\n    },\n    {\n        \"library\": \"starlette ~= 0.13.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-starlette==0.46b0.dev\",\n    },\n    {\n        \"library\": \"psutil >= 5\",\n        \"instrumentation\": \"opentelemetry-instrumentation-system-metrics==0.46b0.dev\",\n    },\n    {\n        \"library\": \"tornado >= 5.1.1\",\n        \"instrumentation\": \"opentelemetry-instrumentation-tornado==0.46b0.dev\",\n    },\n    {\n        \"library\": \"tortoise-orm >= 0.17.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-tortoiseorm==0.46b0.dev\",\n    },\n    {\n        \"library\": \"pydantic >= 1.10.2\",\n        \"instrumentation\": \"opentelemetry-instrumentation-tortoiseorm==0.46b0.dev\",\n    },\n    {\n        \"library\": \"urllib3 >= 1.0.0, < 3.0.0\",\n        \"instrumentation\": \"opentelemetry-instrumentation-urllib3==0.46b0.dev\",\n    },\n]\ndefault_instrumentations = [\n    \"opentelemetry-instrumentation-asyncio==0.46b0.dev\",\n    \"opentelemetry-instrumentation-aws-lambda==0.46b0.dev\",\n    \"opentelemetry-instrumentation-dbapi==0.46b0.dev\",\n    \"opentelemetry-instrumentation-logging==0.46b0.dev\",\n    \"opentelemetry-instrumentation-sqlite3==0.46b0.dev\",\n    \"opentelemetry-instrumentation-urllib==0.46b0.dev\",\n    \"opentelemetry-instrumentation-wsgi==0.46b0.dev\",\n]\n", "path": "opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py"}, {"content": "# Copyright The OpenTelemetry Authors\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#     http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n\nfrom tomli import load\nfrom os import path, listdir\nfrom subprocess import check_output, CalledProcessError\nfrom requests import get\n\nscripts_path = path.dirname(path.abspath(__file__))\nroot_path = path.dirname(scripts_path)\ninstrumentations_path = path.join(root_path, \"instrumentation\")\n\n\ndef get_instrumentation_packages():\n    for pkg in sorted(listdir(instrumentations_path)):\n        pkg_path = path.join(instrumentations_path, pkg)\n        if not path.isdir(pkg_path):\n            continue\n\n        error = f\"Could not get version for package {pkg}\"\n\n        try:\n            hatch_version = check_output(\n                \"hatch version\",\n                shell=True,\n                cwd=pkg_path,\n                universal_newlines=True\n            )\n\n        except CalledProcessError as exc:\n            print(f\"Could not get hatch version from path {pkg_path}\")\n            print(exc.output)\n\n        try:\n            response = get(f\"https://pypi.org/pypi/{pkg}/json\", timeout=10)\n\n        except Exception:\n            print(error)\n            continue\n\n        if response.status_code != 200:\n            print(error)\n            continue\n\n        pyproject_toml_path = path.join(pkg_path, \"pyproject.toml\")\n\n        with open(pyproject_toml_path, \"rb\") as file:\n            pyproject_toml = load(file)\n\n        instrumentation = {\n            \"name\": pyproject_toml[\"project\"][\"name\"],\n            \"version\": hatch_version.strip(),\n            \"instruments\": pyproject_toml[\"project\"][\"optional-dependencies\"][\n                \"instruments\"\n            ],\n        }\n        instrumentation[\"requirement\"] = \"==\".join(\n            (\n                instrumentation[\"name\"],\n                instrumentation[\"version\"],\n            )\n        )\n        yield instrumentation\n\n\nif __name__ == \"__main__\":\n    print(list(get_instrumentation_packages()))\n", "path": "scripts/otel_packaging.py"}]}