Skip to content

CI: Validate LocalStack 2026.3#726

Draft
amotl wants to merge 1 commit intomainfrom
localstack-2026.3
Draft

CI: Validate LocalStack 2026.3#726
amotl wants to merge 1 commit intomainfrom
localstack-2026.3

Conversation

@amotl
Copy link
Copy Markdown
Member

@amotl amotl commented Mar 25, 2026

About

Just a version bump, following LocalStack's announcement Project Update: Consolidation into the Unified LocalStack Image:

To provide a more reliable and streamlined experience, we are consolidating our development into a single, unified image. As part of this transition, this repository is now archived and read-only.

This decision reflects our commitment to reducing fragmentation and focusing our resources on building the most robust AWS emulation layer possible. We are deeply grateful to the contributors who helped make this project into what it is today–your work remains integral to the future of the LocalStack ecosystem.

Evaluation

Updating to LocalStack NG does not work out of the box for integration testing the DynamoDB and Kinesis data I/O nozzles. It is possible we need a newer localstack Python package, but possibly, the testcontainers package is not ready yet.

/cc @hampsterx 🌻

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Mar 25, 2026

Walkthrough

Updated the default LocalStack version from "4.14" to "2026.3" across the test infrastructure by modifying both the CI workflow matrix for DynamoDB tests and the testcontainers default constant.

Changes

Cohort / File(s) Summary
CI Workflow Configuration
.github/workflows/dynamodb.yml
Added LocalStack version "2026.3" to the localstack-version job matrix, enabling DynamoDB tests to run with the new version alongside the existing version.
Testcontainers Default Version
cratedb_toolkit/testing/testcontainers/localstack.py
Updated LocalStackContainerWithKeepalive.LOCALSTACK_VERSION default from "4.14" to "2026.3".

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

Suggested reviewers

  • surister
  • hammerhead

Poem

🐰 A hoppy update, version springs anew,
From four-point-fourteen to twenty-twenty-six, too!
LocalStack dances in the CI so bright,
Fresh containers tested throughout the night! ✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: updating LocalStack to version 2026.3 for CI validation, which aligns with the actual changeset that updates the LocalStack version from 4.14 to 2026.3.
Description check ✅ Passed The PR description clearly explains the version bump from LocalStack 4.14 to 2026.3, references the official LocalStack consolidation announcement, and provides context about testing status and known issues.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch localstack-2026.3

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 and usage tips.

@amotl amotl force-pushed the localstack-2026.3 branch from d001385 to 5d17b36 Compare March 25, 2026 21:15
@amotl amotl changed the title CI: Update LocalStack from 4.14 to 2026.3 CI: Validate LocalStack 2026.3 Mar 25, 2026
@amotl
Copy link
Copy Markdown
Member Author

amotl commented Mar 25, 2026

It is possible the testcontainers package is not ready yet.

Here we go:

localstack/localstack:latest will require auth token from March 23.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@cratedb_toolkit/testing/testcontainers/localstack.py`:
- Line 36: The fallback LOCALSTACK_VERSION constant currently set to "2026.3"
(used by LocalStackContainerWithKeepalive()) may be too new for some workflows
(kinesis.yml lacks a version matrix); either change the default to a
known-stable version used in your test matrix (e.g., revert LOCALSTACK_VERSION
to the previous stable tag) or add an explicit localstack-version matrix entry
to kinesis.yml so callers won’t implicitly use 2026.3; update the environment
default in the LOCALSTACK_VERSION declaration or add the matrix in kinesis.yml
to make the version selection explicit.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: f64f0038-5c6c-4eae-ad7d-a3362757220b

📥 Commits

Reviewing files that changed from the base of the PR and between dcf80c7 and 5d17b36.

📒 Files selected for processing (2)
  • .github/workflows/dynamodb.yml
  • cratedb_toolkit/testing/testcontainers/localstack.py

"""

LOCALSTACK_VERSION = os.environ.get("LOCALSTACK_VERSION", "4.14")
LOCALSTACK_VERSION = os.environ.get("LOCALSTACK_VERSION", "2026.3")
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== LocalStack container call sites =="
ast-grep --pattern 'LocalStackContainerWithKeepalive($$$)' || true

echo
echo "== Workflow entries that explicitly set LocalStack version =="
rg -n -C2 'LOCALSTACK_VERSION|localstack-version' .github/workflows || true

echo
echo "== Current fallback definition =="
rg -n -C2 'LOCALSTACK_VERSION = os\.environ\.get\("LOCALSTACK_VERSION"' cratedb_toolkit/testing/testcontainers/localstack.py

Repository: crate/cratedb-toolkit

Length of output: 1440


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== Recent commits affecting localstack.py =="
git log --oneline -20 -- cratedb_toolkit/testing/testcontainers/localstack.py 2>/dev/null || echo "No git history available"

echo
echo "== Full context of line 36 with nearby lines =="
cat -n cratedb_toolkit/testing/testcontainers/localstack.py | sed -n '30,45p'

echo
echo "== Search for exit code 55 in logs or issues =="
rg -i "exit.*55|code.*55" --type-list | head -20 || true

echo
echo "== Check all workflow files for LocalStack references =="
fd -e yml -e yaml .github/workflows | xargs grep -l "localstack\|LocalStack" || true

echo
echo "== Check if there are other conftest files using LocalStackContainerWithKeepalive =="
rg -l "LocalStackContainerWithKeepalive" tests/

Repository: crate/cratedb-toolkit

Length of output: 1844


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== Git diff for recent localstack.py commit =="
git show 5d17b36 -- cratedb_toolkit/testing/testcontainers/localstack.py | head -100

echo
echo "== Check previous version of line 36 =="
git show 5d17b36^:cratedb_toolkit/testing/testcontainers/localstack.py | sed -n '30,40p' || echo "Previous version not available"

echo
echo "== Search workflow files in .github/workflows =="
find .github/workflows -type f \( -name "*.yml" -o -name "*.yaml" \) -exec grep -l "localstack\|LocalStack" {} \;

echo
echo "== Content of kinesis workflow (if exists) =="
if [ -f ".github/workflows/kinesis.yml" ]; then grep -C3 -i "localstack" ".github/workflows/kinesis.yml" || echo "No LocalStack refs"; else echo "kinesis.yml not found"; fi

echo
echo "== Look for any CI test failures in comments or docs =="
rg -i "exit.*55|container.*exit|failed.*local" docs/ README* .github/ 2>/dev/null | head -20 || true

Repository: crate/cratedb-toolkit

Length of output: 3685


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== Content of kinesis.yml workflow =="
cat .github/workflows/kinesis.yml

echo
echo "== All files in cratedb_toolkit/testing/testcontainers/ =="
ls -la cratedb_toolkit/testing/testcontainers/

echo
echo "== Check git log to see if localstack.py existed before =="
git log --all --oneline -- cratedb_toolkit/testing/testcontainers/localstack.py | head -10

Repository: crate/cratedb-toolkit

Length of output: 3505


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== Check if LocalStack was previously imported/configured elsewhere =="
git log --all -p --follow -S "LocalStack" -- "**/*.py" | grep -A5 -B5 "LOCALSTACK_VERSION\|LocalStackContainer" | head -100

echo
echo "== Look at conftest.py files to see how they configured LocalStack before =="
git show c83a622:tests/io/kinesis/conftest.py 2>/dev/null | head -60 || echo "File doesn't exist in that commit"

echo
echo "== Check commit c83a622 (race condition fix) details =="
git show c83a622 --stat

echo
echo "== Check previous conftest.py before new localstack.py file =="
git show fe406b6:tests/io/kinesis/conftest.py 2>/dev/null | head -60 || echo "Not available"

Repository: crate/cratedb-toolkit

Length of output: 151


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== Commit message for c83a622 (race condition fix) =="
git log --format=fuller c83a622 -1

echo
echo "== Commit message for fe406b6 (Update to LocalStack 4.14) =="
git log --format=fuller fe406b6 -1

echo
echo "== Check kinesis conftest.py current state =="
cat -n tests/io/kinesis/conftest.py

echo
echo "== Check dynamodb conftest.py current state =="
cat -n tests/io/dynamodb/conftest.py

Repository: crate/cratedb-toolkit

Length of output: 8518


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== Check if kinesis.yml ever had a LOCALSTACK_VERSION matrix =="
git log --all -p -- .github/workflows/kinesis.yml | grep -A20 -B5 "LOCALSTACK_VERSION\|localstack-version" | head -80

echo
echo "== Check if there are any TODO or FIXME comments in localstack.py =="
grep -n "TODO\|FIXME\|XXX" cratedb_toolkit/testing/testcontainers/localstack.py

echo
echo "== Verify the state of dynamodb.yml =="
cat .github/workflows/dynamodb.yml | grep -A30 "matrix:"

Repository: crate/cratedb-toolkit

Length of output: 128


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== Full dynamodb.yml matrix section =="
cat .github/workflows/dynamodb.yml | sed -n '/matrix:/,/env:/p'

echo
echo "== Check full kinesis.yml for any environment variables or version setup =="
cat .github/workflows/kinesis.yml | grep -A50 "jobs:" | grep -A40 "tests:"

echo
echo "== Look for any issue or discussion about LocalStack 2026.3 =="
rg -i "2026\.3|exit.*55" . --type markdown --type text 2>/dev/null | head -20 || true

echo
echo "== Verify the exact git status of localstack.py - was it created or modified =="
git show --stat 5d17b36 | grep localstack.py

Repository: crate/cratedb-toolkit

Length of output: 1528


Reconsider the fallback version for unmatrixe d workflows.

This new file introduces 2026.3 as the default fallback for all callers of LocalStackContainerWithKeepalive() that don't set LOCALSTACK_VERSION. While dynamodb.yml has a test matrix to override this, kinesis.yml has no version matrix and will implicitly use 2026.3 for all runs. Given the recent race condition fixes in LocalStack readiness handling (commit c83a622), consider using a more battle-tested version as the fallback, or add an explicit matrix to kinesis.yml.

Suggested approach

Either:

  1. Revert the fallback to a stable version known to work with the test suite:
-    LOCALSTACK_VERSION = os.environ.get("LOCALSTACK_VERSION", "2026.3")
+    LOCALSTACK_VERSION = os.environ.get("LOCALSTACK_VERSION", "4.14")
  1. Or, add a localstack-version matrix to kinesis.yml similar to dynamodb.yml to make the version choice explicit.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
LOCALSTACK_VERSION = os.environ.get("LOCALSTACK_VERSION", "2026.3")
LOCALSTACK_VERSION = os.environ.get("LOCALSTACK_VERSION", "4.14")
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@cratedb_toolkit/testing/testcontainers/localstack.py` at line 36, The
fallback LOCALSTACK_VERSION constant currently set to "2026.3" (used by
LocalStackContainerWithKeepalive()) may be too new for some workflows
(kinesis.yml lacks a version matrix); either change the default to a
known-stable version used in your test matrix (e.g., revert LOCALSTACK_VERSION
to the previous stable tag) or add an explicit localstack-version matrix entry
to kinesis.yml so callers won’t implicitly use 2026.3; update the environment
default in the LOCALSTACK_VERSION declaration or add the matrix in kinesis.yml
to make the version selection explicit.

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