@@ -1390,9 +1390,24 @@ def test_workers_one_does_not_set_omp_thread_limit(self, db, monkeypatch):
13901390 assert "OMP_THREAD_LIMIT" not in os .environ
13911391
13921392
1393+ _CLUSTERING_DISABLED_REASON = (
1394+ "addendum item 2a's clustering pre-pass is disabled in run_pilot (2026-07-16) - it's a "
1395+ "sequential fetch over the whole selected pool, unaffected by --workers, and its own fixed "
1396+ "cost measurably exceeded the compute time it saved at full-catalog scale (see "
1397+ "local_identify_printing_tags.py's run_pilot comment at the cluster_result assignment). "
1398+ "compute_own_image_clusters itself is untouched and still tested directly above; only the "
1399+ "run_pilot integration is skipped until a future chunk-scoped redesign re-enables it."
1400+ )
1401+
1402+
13931403class TestClusterDedup :
13941404 """Addendum item 2a (2026-07-15): distance-0 (byte-identical fetched image) clustering,
1395- scoped to this run only - no schema/content_hash persistence (that's item 2b, deferred)."""
1405+ scoped to this run only - no schema/content_hash persistence (that's item 2b, deferred).
1406+
1407+ NOTE (2026-07-16): run_pilot no longer calls compute_own_image_clusters (see
1408+ _CLUSTERING_DISABLED_REASON) - the tests below that exercise clustering directly still
1409+ pass and still matter; the ones that expect run_pilot's own integration to cluster are
1410+ marked skip, not deleted, so they're ready to re-enable alongside a future redesign."""
13961411
13971412 def test_two_cards_with_identical_images_cluster_with_lower_pk_as_representative (self , db ):
13981413 CanonicalCardFactory (name = "Forest" )
@@ -1458,6 +1473,7 @@ def test_unfetchable_image_stays_a_singleton_representative(self, db, monkeypatc
14581473 assert cluster_result .members_by_representative == {}
14591474 assert [s .card .pk for s in cluster_result .representatives ] == [card .pk ]
14601475
1476+ @pytest .mark .skip (reason = _CLUSTERING_DISABLED_REASON )
14611477 def test_accepted_vote_on_representative_propagates_to_absorbed_member (self , db , monkeypatch ):
14621478 printing = CanonicalCardFactory (name = "Forest" , expansion = CanonicalExpansionFactory (code = "aaa" ))
14631479 card_a = CardFactory (name = "Forest" )
@@ -1491,6 +1507,11 @@ def test_accepted_vote_on_representative_propagates_to_absorbed_member(self, db,
14911507 assert vote_a .source == vote_b .source == VoteSource .OCR
14921508 assert vote_a .is_no_match == vote_b .is_no_match is False
14931509
1510+ @pytest .mark .skip (
1511+ reason = _CLUSTERING_DISABLED_REASON + " Passes vacuously with clustering off (no "
1512+ "propagation is ever attempted, so the guard it tests is never exercised) - skipped "
1513+ "rather than left green for the wrong reason."
1514+ )
14941515 def test_member_with_an_existing_vote_from_a_prior_run_is_not_double_voted_or_overwritten (self , db , monkeypatch ):
14951516 printing = CanonicalCardFactory (name = "Forest" , expansion = CanonicalExpansionFactory (code = "aaa" ))
14961517 other_printing = CanonicalCardFactory (name = "Forest" , expansion = CanonicalExpansionFactory (code = "bbb" ))
@@ -1533,6 +1554,7 @@ def test_member_with_an_existing_vote_from_a_prior_run_is_not_double_voted_or_ov
15331554 assert untouched_vote .pk == existing_vote .pk
15341555 assert untouched_vote .printing_id == other_printing .pk # unchanged, not overwritten
15351556
1557+ @pytest .mark .skip (reason = _CLUSTERING_DISABLED_REASON )
15361558 def test_absorbed_member_never_reaches_ocr_or_phash_processing (self , db , monkeypatch ):
15371559 # the whole point of dedup is not re-running the expensive engines on cluster members -
15381560 # this is the test that actually proves the efficiency win, not just vote correctness.
@@ -1559,6 +1581,7 @@ def recording_run_ocr_for_card(selected, image, crop_box, bleed_class=None):
15591581 assert ocr_called_for_card_ids == [card_a .pk ]
15601582 assert card_b .pk not in ocr_called_for_card_ids
15611583
1584+ @pytest .mark .skip (reason = _CLUSTERING_DISABLED_REASON )
15621585 def test_absorbed_members_own_engine_eligibility_still_runs_via_the_representative (self , db , monkeypatch ):
15631586 # card_a (the lower-pk representative) is only phash-eligible; card_b (absorbed member)
15641587 # is only ocr-eligible - the representative must still run OCR on card_a's behalf, or
0 commit comments