Skip to content

[fix] release distinct iterators on every return (LET-42) - #194

Merged
vt128 merged 1 commit into
masterfrom
codex/fix-distinct-iterator-let42
Nov 9, 2026
Merged

vt128 merged 1 commit into
masterfrom
codex/fix-distinct-iterator-let42

Conversation

@vt128

@vt128 vt128 commented Nov 9, 2026 •

Copy link
Copy Markdown
Member

distinct(list) left its iterator active after returning, preventing later list mutation. Defer iterator cleanup on every return, including an element-hashing error, while preserving result shapes and input values.

Regressions cover empty/success/error paths for native lists and tracked iterators, exact cleanup, input preservation and mutation after return. This PR retains the existing hash-only deduplication; #198 separately addresses hash collisions and equality.

Validation:

  • Host Go 1.27.3 and library-floor Go 1.19.13: build, race tests (-count=2), vet and coverage comparisons pass. The added statement is covered on each compiler, with no previously covered statements lost.
  • The independent-candidate consumer matrix passes all 200 fresh configurations (190 active and 10 archived MQ diagnostics); all 160 consumer profile comparisons are exact. Packages without unit tests are checked by build/vet.
  • Public hello/qrcard scripts pass all 20 executions across 10 real CLI binaries, on host Go 1.27.3 and the CLI floor Go 1.25.8.

Allocation medians match across eight representative list/tuple/custom/control workloads. The fixed timing comparisons are machine-specific and do not establish equivalence.

Tracks LET-42. No API, dependency, interpreter or Go-floor change.

@codacy-production

codacy-production Bot commented Nov 9, 2026 •

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 41 complexity · 0 duplication

Metric Results
Complexity 41
Duplication 0

View in Codacy

🟢 Coverage 100.00% diff coverage · +0.00% coverage variation

Metric Results
Coverage variation ✅ +0.00% coverage variation (-1.00%)
Diff coverage ✅ 100.00% diff coverage

View coverage diff in Codacy

Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (971eee9) 8429 8014 95.08%
Head commit (7f13503) 8430 (+1) 8015 (+1) 95.08% (+0.00%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#194) 1 1 100.00%

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@codecov

codecov Bot commented Nov 9, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.95%. Comparing base (971eee9) to head (7f13503).

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #194   +/-   ##
=======================================
  Coverage   93.95%   93.95%           
=======================================
  Files          53       53           
  Lines        6746     6747    +1     
=======================================
+ Hits         6338     6339    +1     
  Misses        259      259           
  Partials      149      149           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@vt128
vt128 force-pushed the codex/fix-distinct-iterator-let42 branch from 931c3b5 to 7f13503 Compare November 9, 2026 15:04
@vt128
vt128 marked this pull request as ready for review November 9, 2026 15:46
@vt128
vt128 merged commit b4a1f7f into master Nov 9, 2026
42 of 43 checks passed
@vt128
vt128 deleted the codex/fix-distinct-iterator-let42 branch November 9, 2026 16:51
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