Skip to content

ensure matching size schemas in filter_connected_components_by_size - #433

Merged
johandahlberg merged 1 commit into
devfrom
fix/ensure-matching-size-schemas-in-filter_connected_components_by_size
Aug 4, 2026
Merged

ensure matching size schemas in filter_connected_components_by_size#433
johandahlberg merged 1 commit into
devfrom
fix/ensure-matching-size-schemas-in-filter_connected_components_by_size

Conversation

@ptajvar

@ptajvar ptajvar commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Small fix to ensure that the schemas match when concatenating remaining component sizes and discarded component sizes in filter_connected_components_by_size.


Note

Low Risk
Localized graph filtering/statistics fix with a targeted test; no auth, data persistence, or API surface changes.

Overview
Fixes a Polars vertical concat failure when filter_connected_components_by_size merges in-component sizes with early-discarded component sizes that include an extra n_edges column.

discard_sizes from write_hive_partitioned_edgelist_without_out_of_size_bound_components carries component, n_umi, and n_edges, while sizes computed from the remaining edgelist only have component and n_umi. The filter now selects component and n_umi from discard_sizes before concatenation so pre-filtering component statistics stay correct without schema mismatch.

A regression test covers discard_sizes frames that include n_edges (e.g. multiplet recovery with max component size threshold).

Reviewed by Cursor Bugbot for commit 148a722. Bugbot is set up for automated code reviews on this repo. Configure here.

@ptajvar
ptajvar requested a review from johandahlberg August 4, 2026 14:22
@ptajvar
ptajvar force-pushed the fix/ensure-matching-size-schemas-in-filter_connected_components_by_size branch from a41dd7a to 148a722 Compare August 4, 2026 14:28
@johandahlberg
johandahlberg merged commit 946f1eb into dev Aug 4, 2026
17 checks passed
@johandahlberg
johandahlberg deleted the fix/ensure-matching-size-schemas-in-filter_connected_components_by_size branch August 4, 2026 15:00
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.

2 participants