Skip to content

Conversation

@devin-ai-integration
Copy link
Contributor

@devin-ai-integration devin-ai-integration bot commented Nov 25, 2025

What

Fixes the disputes stream to properly capture status updates during incremental syncs.

Related issues:

How

Changed the cursor field from id (with since_id filtering) to initiated_at for the Disputes stream.

Before: The stream used cursor_field = "id" and filter_field = "since_id", which only fetched disputes with IDs greater than the last synced ID. This missed updates to existing disputes when their status changed.

After: The stream uses cursor_field = "initiated_at" and filter_field = "initiated_at", allowing incremental syncs to capture disputes that may have been updated since the last sync.

Review guide

  1. airbyte-integrations/connectors/source-shopify/source_shopify/streams/streams.py - The only file changed; review the Disputes class modification

Key review points:

  • Verify the Shopify Disputes API supports initiated_at as a filter parameter (documentation suggests it does)
  • Consider if a state migration is needed for users with existing id-based state (similar to TransactionsCursorMigration used for the Transactions stream fix)
  • Determine if this should be flagged as a breaking change

User Impact

Users syncing the disputes stream in incremental mode will now receive status updates to existing disputes (e.g., when a dispute changes from "needs_response" to "won" or "lost").

Potential negative impact: Existing syncs may need to reset state or perform a full refresh after upgrading, as the cursor field has changed from id to initiated_at.

Can this PR be safely reverted and rolled back?

  • YES 💚

Devin AI Fix Spike - This is a draft PR created during AI triage. Please review carefully before merging.

Link to Devin run: https://app.devin.ai/sessions/90fddd2921d04ffb898d6a3e49d75652
Requested by: @agarctfi

…r incremental syncs

The disputes stream was using 'id' as the cursor field with 'since_id' filtering,
which only captured new disputes but missed updates to existing disputes (e.g.,
status changes from 'needs_response' to 'won' or 'lost').

This change updates the cursor to use 'initiated_at' field, which allows
incremental syncs to properly capture status updates to existing disputes.

Fixes: airbytehq/oncall#10207
Related: #52561 (similar issue for Transactions stream)
Co-Authored-By: unknown <>
@devin-ai-integration
Copy link
Contributor Author

Original prompt from API User
Comment from @agarctfi: /ai-triage\n\nIMPORTANT: The user will expect a response posted back to the PR. You should post exactly one comment back to the respective issue PR. If the user requested a code change or PR, your comment should contain a link to the PR. Assume the user has no access to your session or conversation thread unless/until you respond back to them.\n\nIssue #10207 by @jnr0790: Shopify: Incorrect `status` in `disputes` stream\n\nIssue URL: https://github.com/airbytehq/oncall/issues/10207\n\nPlease use playbook macro: !issue_triage

PLAYBOOK_md:
# `/ai-triage` Slash Command Playbook

You are AI Triage Devin, an expert at analyzing Airbyte-related issues and providing actionable insights. You are responding to a GitHub slash command request. After reading the provided context, you should post a comment to confirm you understand the request and stating what your next steps will be, along with a link to your session. Once your triage and analysis is complete, update your comment with the full results of your triage. Collapse all of your comments under expandable sections.

IMPORTANT: Expect that your user has no access to the session and cannot talk with you directly. Do not wait for feedback or confirmation on any action.

## Context

You are analyzing the issue provided to you above. You will need to pull comment history on this issue to ensure you have full context.

## Your Task: Static Analysis and Triage

1. **Issue Analysis and Confirmation**: Read the complete issue content including all comments for full context.
   - **Post an initial comment immediately** (within 1-2 minutes) to confirm you understand the assignment and that you are looking into it. Include your session URL.
   - If you are missing any critical information or context (e.g., workspace UUID, connector version, error logs, reproduction steps, customer environment details), include in your initial comment a request for additional context. (Do not block waiting for an answer, but... (9065 chars truncated...)

@devin-ai-integration
Copy link
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

@github-actions
Copy link
Contributor

👋 Greetings, Airbyte Team Member!

Here are some helpful tips and reminders for your convenience.

Helpful Resources

PR Slash Commands

Airbyte Maintainers (that's you!) can execute the following slash commands on your PR:

  • /format-fix - Fixes most formatting issues.
  • /bump-version - Bumps connector versions.
    • You can specify a custom changelog by passing changelog. Example: /bump-version changelog="My cool update"
    • Leaving the changelog arg blank will auto-populate the changelog from the PR title.
  • /run-cat-tests - Runs legacy CAT tests (Connector Acceptance Tests)
  • /run-live-tests - Runs live tests for the modified connector(s).
  • /run-regression-tests - Runs regression tests for the modified connector(s).
  • /build-connector-images - Builds and publishes a pre-release docker image for the modified connector(s).
  • JVM connectors:
    • /update-connector-cdk-version connector=<CONNECTOR_NAME> - Updates the specified connector to the latest CDK version.
      Example: /update-connector-cdk-version connector=destination-bigquery
    • /bump-bulk-cdk-version bump=patch changelog='foo' - Bump the Bulk CDK's version. bump can be major/minor/patch.
  • Python connectors:
    • /poe connector source-example lock - Run the Poe lock task on the source-example connector, committing the results back to the branch.
    • /poe source example lock - Alias for /poe connector source-example lock.
    • /poe source example use-cdk-branch my/branch - Pin the source-example CDK reference to the branch name specified.
    • /poe source example use-cdk-latest - Update the source-example CDK dependency to the latest available version.

📝 Edit this welcome message.

@github-actions
Copy link
Contributor

source-shopify Connector Test Results

207 tests   197 ✅  1m 50s ⏱️
  2 suites   10 💤
  2 files      0 ❌

Results for commit eeb45d9.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants