Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove requirements for flask and werkzeug in Pythn docs #4047

Merged
merged 4 commits into from
Feb 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions content/en/docs/kubernetes/operator/automatic.md
Original file line number Diff line number Diff line change
Expand Up @@ -318,8 +318,7 @@ EOF
```

> **Note**: OpenTelemetry Python automatic instrumentation does not support
> Flask or Werkzeug 3.0+ at this time. See the troubleshooting section
> [No Data When Using Flask](/docs/languages/python/automatic#no-data-when-using-flask)
> Flask or Werkzeug 3.0+ at this time.

By default, the `Instrumentation` resource that auto-instruments Python services
uses `otlp` with the `http/protobuf` protocol (gRPC is not supported at this
Expand Down
13 changes: 0 additions & 13 deletions content/en/docs/languages/python/automatic/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,19 +75,6 @@ You can find the full list

## Troubleshooting

### No data when using Flask

Using OpenTelemetry with Flask requires both Flask and Werkzeug versions as <
3.0. Because Flask 2.x does not specify Werkzeug as < 3.0, conflicts can arise.

Ensure your Flask version is < 3.x, and specify the Werkzeug version explicitly
as < 3.0. For example, in a `pyproject.toml` file:

```console
flask = "2.2.2"
Werkzeug = "2.2.2"
```

### Python package installation failure

The Python package installs require `gcc` and `gcc-c++`, which you may need to
Expand Down
6 changes: 1 addition & 5 deletions content/en/docs/languages/python/automatic/example.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,13 +101,9 @@ which provides several commands that help automatically instrument a program.

```sh
pip install opentelemetry-distro
pip install 'flask<3' 'werkzeug<3' requests
pip install flask requests
```

> **Note**: OpenTelemetry Python automatic instrumentation does not support
> Flask or Werkzeug 3.0+ at this time. See the troubleshooting section
> [No Data When Using Flask](/docs/languages/python/automatic#no-data-when-using-flask)

Run the `opentelemetry-bootstrap` command:

```shell
Expand Down
8 changes: 2 additions & 6 deletions content/en/docs/languages/python/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,12 @@ python3 -m venv venv
source ./venv/bin/activate
```

Now install Flask and Werkzeug:
Now install Flask:

```shell
pip install 'flask<3' 'werkzeug<3'
pip install flask
```

> **Note**: OpenTelemetry Python automatic instrumentation does not support
> Flask or Werkzeug 3.0+ at this time. See the troubleshooting section
> [No Data When Using Flask](/docs/languages/python/automatic#no-data-when-using-flask)

### Create and launch an HTTP Server

Create a file `app.py` and add the following code to it:
Expand Down
Loading