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

use minorversion 75 by default #381

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Conversation

laf-rge
Copy link
Contributor

@laf-rge laf-rge commented Mar 16, 2025

Default to minimum supported minor version (75) when none specified

Issue

Fixes #377 - Minor version should be 75 by default

Problem

Currently, when no minor version is specified in the QuickBooks client initialization, the minorversion parameter is not sent in API requests. In this case, Intuit's API defaults to minor version 1. According to Intuit's announcement, starting August 1, 2025, all API requests will use minor version 75 by default and previous minor versions (1-74) will be deprecated.

Solution

  • Modified make_request to always send a minorversion parameter
  • When no minor version is specified during client initialization, default to MINIMUM_MINOR_VERSION (75)
  • Added a deprecation warning to encourage users to explicitly specify the minor version

Breaking Changes

This change may affect applications that rely on behavior specific to minor version 1 (the previous implicit default). Users should:

  1. Test their applications with minor version 75
  2. If needed, explicitly set the minor version during client initialization
  3. Plan to update any code that depends on behavior from versions 1-74, as these will be deprecated by Intuit in August 2025

Migration Guide

If your application requires a specific minor version, initialize the client with the minorversion parameter:

from quickbooks.client import QuickBooks

# Explicitly set minor version (recommended)
client = QuickBooks(
    auth_client=auth_client,
    company_id="company_id",
    minorversion=75  # Specify the desired version (must be >= 75)
)

# No minor version specified (will use 75 and show deprecation warning)
client = QuickBooks(
    auth_client=auth_client,
    company_id="company_id"
)

Testing

  • Tested API requests with and without explicit minor version specification
  • Verified deprecation warning is shown when no minor version is specified
  • Confirmed minor version 75 is used by default when not specified

laf-rge added 4 commits March 16, 2025 13:10
@codecov-commenter
Copy link

codecov-commenter commented Mar 16, 2025

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

Attention: Patch coverage is 82.75862% with 5 lines in your changes missing coverage. Please review.

Project coverage is 93.47%. Comparing base (67141c2) to head (b4014b4).

Files with missing lines Patch % Lines
quickbooks/client.py 77.27% 1 Missing and 4 partials ⚠️

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #381      +/-   ##
==========================================
- Coverage   93.53%   93.47%   -0.06%     
==========================================
  Files         104      104              
  Lines        3991     4003      +12     
  Branches      108      113       +5     
==========================================
+ Hits         3733     3742       +9     
  Misses        219      219              
- Partials       39       42       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

Minor version should be 75 by default
2 participants