Skip to content

feat(source-postgres,source-mysql): add local e2e prove-fix test harness skills#82249

Draft
sophiecuiy wants to merge 1 commit into
masterfrom
devin/1784245093-db-e2e-skills
Draft

feat(source-postgres,source-mysql): add local e2e prove-fix test harness skills#82249
sophiecuiy wants to merge 1 commit into
masterfrom
devin/1784245093-db-e2e-skills

Conversation

@sophiecuiy

Copy link
Copy Markdown
Contributor

What

Adds connector-local e2e test-harness skills for source-postgres and source-mysql, modeled on the existing source-mssql-e2e-tests harness. These are the per-engine evidence engine for the new database-source /ai-prove-fix playbook (db_prove_fix.md in airbytehq/ai-skills: https://github.com/airbytehq/ai-skills/pull/608) — they let Devin (or a maintainer) stand up a throwaway local DB, apply an authored SQL fixture, and run protocol commands against a PR image vs a control image to prove a fix, without touching customer data.

Requested by Sophie Cui (sophiecuiy).

Each skill lives under airbyte-integrations/connectors/source-<engine>/.agents/skills/source-<engine>-e2e-tests/ with the same script contract as mssql:

scripts/start-backend.sh    # throwaway DB container (postgres:16 / mysql:8.0)
scripts/stop-backend.sh     # docker rm -f
scripts/apply-sql.sh        # load a .sql fixture
scripts/render-config.sh    # jq the backend bridge IP into a config template
scripts/run-protocol-cmd.sh # wrapper over `airbyte-ops … regression-test`
fixtures/configs/base.template.json
fixtures/sql/00-init-base.sql

How

Faithful ports of the mssql scripts, adapted per engine:

  • Postgres backend starts postgres:16 with wal_level=logical + WAL sender/slot headroom so a CDC repro can add a logical replication slot without a restart. Readiness via pg_isready; apply-sql.sh pipes into psql over the trust-auth unix socket.
  • MySQL backend starts mysql:8.0 with --binlog-format=ROW --binlog-row-image=FULL + GTIDs for CDC; readiness via a SELECT 1 probe; apply-sql.sh uses MYSQL_PWD to avoid the plaintext-password warning.
  • Config templates use each engine's real spec shape (verified against the connectors): Postgres ssl_mode: {mode: disable} + replication_method: {method: Standard}; MySQL ssl_mode: {mode: preferred} + replication_method: {method: STANDARD}.
  • run-protocol-cmd.sh adds comparison mode on top of the mssql single-version wrapper: setting CONTROL_VERSION=<tag> drops --skip-compare=True and adds --control-image=airbyte/source-<engine>:<tag>, producing the side-by-side SPEC/CHECK/DISCOVER/READ diff the prove-fix playbook consumes. Default (no CONTROL_VERSION) is single-version, exactly like mssql.

Docs-only/harness files — no connector runtime code changes.

Review guide

  1. source-postgres/.agents/skills/source-postgres-e2e-tests/SKILL.md and source-mysql/.agents/skills/source-mysql-e2e-tests/SKILL.md — the two skill entrypoints; engine-specific gotchas are documented at the bottom of each.
  2. scripts/run-protocol-cmd.sh (both) — the only script that diverges from mssql (adds CONTROL_VERSION comparison mode).
  3. scripts/start-backend.sh (both) — CDC-ready backend flags.

Local verification (both engines, against published images on this machine):

  • start-backend.sh → container healthy; direct psql / mysql query returns the 3 fixture rows.
  • render-config.sh → bridge IP substituted into a valid config.
  • run-protocol-cmd.sh checkairbyte/source-postgres:3.8.1 and airbyte/source-mysql:3.53.1 both return CONNECTION_STATUS: SUCCEEDED, wrapper exit code 0.
  • run-protocol-cmd.sh discover (postgres) → sample stream discovered with id/label.

Note on versioning

The merged mssql harness PR (#77775) added .agents/skills/ with no dockerImageTag bump or changelog row, so this PR follows that precedent (no runtime change, no release intended). Happy to add a patch bump + changelog rows to both connectors if the connector-CI matrix detector requires it.

User Impact

None for end users — this only adds maintainer/agent test tooling under .agents/.

Can this PR be safely reverted and rolled back?

  • YES 💚
  • NO ❌

Link to Devin session: https://app.devin.ai/sessions/33ca2c4f3fe040659c79757d590f2c30

…ess skills

Co-Authored-By: sophie.cui@airbyte.io <sophie.cui@airbyte.io>
@sophiecuiy sophiecuiy self-assigned this Jul 16, 2026
@devin-ai-integration

Copy link
Copy Markdown
Contributor

🤖 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, CI, and merge conflict monitoring

@github-actions

Copy link
Copy Markdown
Contributor

👋 Greetings, Airbyte Team Member!

Here are some helpful tips and reminders for your convenience.

💡 Show Tips and Tricks

PR Slash Commands

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

  • 🛠️ Quick Fixes
    • /format-fix - Fixes most formatting issues.
    • /bump-version - Bumps connector versions, scraping changelog description from the PR title.
      • Bump types: patch (default), minor, major, major_rc, rc, promote.
      • The rc type is a smart default: applies minor_rc if stable, or bumps the RC number if already RC.
      • The promote type strips the RC suffix to finalize a release.
      • Example: /bump-version type=rc or /bump-version type=minor
    • /bump-progressive-rollout-version - Alias for /bump-version type=rc. Bumps with an RC suffix and enables progressive rollout.
  • ❇️ AI Testing and Review (internal link: AI-SDLC Docs):
    • /ai-prove-fix - Runs prerelease readiness checks, including testing against customer connections.
    • /ai-canary-prerelease - Rolls out prerelease to 5-10 connections for canary testing.
    • /ai-review - AI-powered PR review for connector safety and quality gates.
  • 📝 AI Documentation:
    • /ai-docs-review - AI-powered documentation review for PRs with connector changes.
    • /ai-create-docs-pr - Creates a documentation PR for connector changes, stacked on the current PR.
  • 🚀 Connector Releases:
    • /publish-connectors-prerelease - Publishes pre-release connector builds (tagged as {version}-preview.{git-sha}) for all modified connectors in the PR.
    • /enable-autopilot-rollouts - Enables autopilot progressive rollouts for the modified connector(s) in the PR, remediating "autopilot rollouts not enabled for {connector-name}" auto-merge blockers. Sets defaultRolloutMode: autopilot and enableProgressiveRollout: true, preserving any existing autopilotConfig.
      • Optional args: connector=<CONNECTOR_NAME> (defaults to the modified connectors in the PR), strategy=fast|slow|default (defaults to fast).
      • Example: /enable-autopilot-rollouts or /enable-autopilot-rollouts connector=source-faker strategy=slow
  • ☕️ 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
  • 🐍 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.
  • ⚙️ Admin commands:
    • /force-merge reason="<REASON>" - Force merges the PR using admin privileges, bypassing CI checks. Requires a reason.
      Example: /force-merge reason="CI is flaky, tests pass locally"
📚 Show Repo Guidance

Helpful Resources

📝 Edit this welcome message.

@coderabbitai

coderabbitai Bot commented Jul 16, 2026

Copy link
Copy Markdown

Caution

Review failed

An error occurred during the review process. Please try again later.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch devin/1784245093-db-e2e-skills

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown
Contributor

source-mysql Connector Test Results

 10 files   10 suites   45s ⏱️
101 tests 101 ✅ 0 💤 0 ❌
225 runs  225 ✅ 0 💤 0 ❌

Results for commit 26788b7.

@github-actions

Copy link
Copy Markdown
Contributor

source-postgres Connector Test Results

 14 files   14 suites   11m 32s ⏱️
 92 tests  92 ✅ 0 💤 0 ❌
286 runs  286 ✅ 0 💤 0 ❌

Results for commit 26788b7.

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.

1 participant