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

Add support for mysql-connector-python v9 #2720

Closed
omikader opened this issue Jul 17, 2024 · 1 comment · Fixed by #2751
Closed

Add support for mysql-connector-python v9 #2720

omikader opened this issue Jul 17, 2024 · 1 comment · Fixed by #2751

Comments

@omikader
Copy link
Contributor

What problem do you want to solve?

The mysql-connector-python package had a major version bump on July 1, 2024. However, the opentelemetry-instrumentation-mysql plugin only supports 8.x

Describe the solution you'd like

It would be great if opentelemetry-instrumentation-mysql worked for mysql-connector-python >= 8.0 vs ~= 8.0

Describe alternatives you've considered

It is worth noting that the 9.0.0 changelog for mysql-connector-python includes opentelemetry support, but I prefer to have the auto-instrumentation capabilities provided by this library as opposed to explicitly/manually instrumenting MySQL connections.

Additional Context

I did a quick pass and I don't think their API had any breaking changes so I think it might be as easy as just relaxing the version constraints and trying it out. Happy to open a PR if it's actually that easy 😅

Would you like to implement a fix?

Yes

@xrmx
Copy link
Contributor

xrmx commented Jul 24, 2024

@omikader please give it a try! You have to:

  • update project.optional-dependencies in pyproject.toml
  • update src/opentelemetry/instrumentation/mysql/package.py
  • add a new version of test-requirements.txt using version 9 of the library and update tox.ini accordingly
  • run tox -e generate

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants