Skip to content

Tests depend on cratedb-toolkit, which depends on this package #320

Open

Description

@florinutz

This package and cratedb-toolkit depend on each other. The test suite gets its crate container from the toolkit's test helper (cratedb_toolkit.testing.testcontainers.cratedb.CrateDBTestAdapter), so .[test] installs cratedb-toolkit[testing], while the toolkit requires sqlalchemy-cratedb and imports insert_bulk and CrateDialect from it in util.database.

A change here can fail this whole suite before one test runs, and the fix would then wait on two releases. CI installs this checkout with pip install --editable=.[test], so the released toolkit imports sqlalchemy-cratedb from the checkout. Rename either of those two names and the toolkit's helper no longer loads, until a toolkit release adapts, and the toolkit cannot adapt until this package releases. A library the toolkit builds on should not run its tests on the toolkit.

The tests should start the container from testcontainers-python itself, which since version 4.15 ships a crate container class (testcontainers.community.cratedb.CrateDBContainer) that needs nothing from this ecosystem, and keep the few SQL helpers they use (an engine, run_sql, refresh_table, count_records) in a small class under tests/. crate/crash#502 does the same for crash; the two do not wait on each other.

Settled when .[test] no longer installs cratedb-toolkit and CI is green.

Activity

  1. self-assigned this
    on Oct 9, 2026
  2. amotl commented on Oct 9, 2026

    @amotl
    Contributor

    Yes. Please use vanilla Testcontainers for Python going forward like the referenced patch is doing it.

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

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions