Skip to content

Conversation

rads-1996
Copy link
Contributor

@rads-1996 rads-1996 commented Sep 2, 2025

Description

Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

Fixes #2808

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Added tests for Django instrumentation

Does This PR Require a Core Repo Change?

  • Yes. - Link to PR:
  • No.

Checklist:

See contributing.md for styleguide, changelog guidelines, and more.

  • Followed the style guidelines of this project
  • Changelogs have been updated
  • Unit tests have been added
  • Documentation has been updated

@rads-1996 rads-1996 requested a review from a team as a code owner September 2, 2025 23:11
Comment on lines 173 to 177
if hasattr(value, "__class__"):
if value.__class__.__name__ in (
"HttpRequest",
"WSGIRequest",
):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since this file is already doing from django.http import HttpRequest, would it work if this check instead did isinstance(value, HttpRequest)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tammy-baylis-swi Sounds good. Thanks a lot for the review, I have addressed your feedback. Could you please take another look when you have a moment. Thanks!

Copy link
Contributor

@tammy-baylis-swi tammy-baylis-swi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks again @rads-1996 , this lgtm. Maintainers will also have a look.

@rads-1996
Copy link
Contributor Author

Thanks again @rads-1996 , this lgtm. Maintainers will also have a look.

Thank you so much. Really appreciate the review :)

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

Successfully merging this pull request may close these issues.

Invalid type WSGIRequest for attribute 'request' value opentelemetry
2 participants