Skip to content

Conversation

@dependabot
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Jun 18, 2025

Update the Pinterest Generated Client library to support urllib3 2.x and fix CBO (Campaign Budget Optimization) test failures.

Changes Made

1. Fixed Integration Test CBO Configuration

  • File: integration_test/base.py
  • Change: Updated is_campaign_budget_optimization=Falseis_campaign_budget_optimization=True
  • Reason: Pinterest API now requires CBO for AWARENESS objective campaigns
  • Impact: All integration tests now pass (5/5) instead of failing (2/5)

2. urllib3 Version Compatibility

  • Current Status: Already correctly configured with urllib3>=1.26,<3
  • Files: requirements.txt, setup.py
  • Compatibility: Supports both urllib3 1.26.x and 2.x

3. Fixed urllib3 Deprecation Warnings

  • Patch Applied: spec/patches/fix_urllib3_deprecations.py
  • Files Updated:
    • openapi_generated/pinterest_client/rest.py
    • openapi_generated/pinterest_client/api_client.py
    • openapi_generated/pinterest_client/exceptions.py
  • Changes Made:
    # Before (deprecated):
    response.getheader('content-type')
    response.getheaders()
    
    # After (urllib3 2.x compatible):
    response.urllib3_response.headers.get('content-type')
    response.urllib3_response.headers
  • Impact: Eliminates 23 deprecation warnings, ensures compatibility with urllib3 2.6.0+

4. Increment version and autogenerated

Test

image

Bumps [urllib3](https://github.com/urllib3/urllib3) from 1.26.20 to 2.5.0.
- [Release notes](https://github.com/urllib3/urllib3/releases)
- [Changelog](https://github.com/urllib3/urllib3/blob/main/CHANGES.rst)
- [Commits](urllib3/urllib3@1.26.20...2.5.0)

---
updated-dependencies:
- dependency-name: urllib3
  dependency-version: 2.5.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot added dependencies Pull requests that update a dependency file python Pull requests that update python code labels Jun 18, 2025
@dfana01 dfana01 self-assigned this Sep 12, 2025
@dfana01 dfana01 changed the title chore(deps): bump urllib3 from 1.26.20 to 2.5.0 Update Pinterest Generated Client for urllib3 2.x Compatibility Sep 12, 2025
@dfana01 dfana01 merged commit f8ee0af into main Sep 15, 2025
1 of 2 checks passed
@dependabot dependabot bot deleted the dependabot/pip/urllib3-2.5.0 branch September 15, 2025 17:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file python Pull requests that update python code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants