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

refactor: use HTTResponse.headers instead deprecated HTTPResponse.getheaders() #534

Merged
merged 2 commits into from
Nov 25, 2022

Conversation

bednar
Copy link
Contributor

@bednar bednar commented Nov 25, 2022

Proposed Changes

Refactor code to not deprecated variant:

image

The deprecation warning also causes failure of CI build:

image

https://app.circleci.com/pipelines/github/influxdata/influxdb-client-python/2199/workflows/e1db935d-5dfd-4944-9beb-d113c4108e8b/jobs/12253

Checklist

  • CHANGELOG.md updated
  • Rebased/mergeable
  • pytest tests completes successfully
  • Commit messages are conventional
  • Sign CLA (if not already signed)

@bednar bednar marked this pull request as ready for review November 25, 2022 04:35
@codecov-commenter
Copy link

codecov-commenter commented Nov 25, 2022

Codecov Report

Base: 90.28% // Head: 90.28% // No change to project coverage 👍

Coverage data is based on head (9576138) compared to base (fc6f2d9).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #534   +/-   ##
=======================================
  Coverage   90.28%   90.28%           
=======================================
  Files          39       39           
  Lines        3428     3428           
=======================================
  Hits         3095     3095           
  Misses        333      333           
Impacted Files Coverage Δ
influxdb_client/_sync/rest.py 86.99% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link

@vlastahajek vlastahajek left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@bednar bednar merged commit fcee5b2 into master Nov 25, 2022
@bednar bednar deleted the fix-deprecated branch November 25, 2022 07:42
@bednar bednar added this to the 1.35.0 milestone Nov 25, 2022
@melvilun
Copy link

Hi,

The deprecated method is still used in the getheader() method, which is defined below the getheaders() that you changed.

If you want to clear the deprecation warning for all cases, you need to update that method too.

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

Successfully merging this pull request may close these issues.

4 participants