evilution 0.19.0 → 0.21.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. checksums.yaml +4 -4
  2. data/.beads/.migration-hint-ts +1 -1
  3. data/.beads/issues.jsonl +35 -35
  4. data/CHANGELOG.md +36 -0
  5. data/README.md +25 -4
  6. data/lib/evilution/cli.rb +11 -2
  7. data/lib/evilution/config.rb +12 -2
  8. data/lib/evilution/equivalent/detector.rb +3 -1
  9. data/lib/evilution/equivalent/heuristic/alias_swap.rb +2 -1
  10. data/lib/evilution/equivalent/heuristic/void_context.rb +77 -0
  11. data/lib/evilution/integration/crash_detector.rb +55 -0
  12. data/lib/evilution/integration/rspec.rb +64 -29
  13. data/lib/evilution/isolation/fork.rb +3 -6
  14. data/lib/evilution/mutator/base.rb +1 -1
  15. data/lib/evilution/mutator/operator/begin_unwrap.rb +21 -0
  16. data/lib/evilution/mutator/operator/block_param_removal.rb +57 -0
  17. data/lib/evilution/mutator/operator/case_when.rb +55 -0
  18. data/lib/evilution/mutator/operator/equality_to_identity.rb +22 -0
  19. data/lib/evilution/mutator/operator/index_to_dig.rb +1 -1
  20. data/lib/evilution/mutator/operator/lambda_body.rb +18 -0
  21. data/lib/evilution/mutator/operator/loop_flip.rb +27 -0
  22. data/lib/evilution/mutator/operator/method_body_replacement.rb +10 -6
  23. data/lib/evilution/mutator/operator/predicate_replacement.rb +27 -0
  24. data/lib/evilution/mutator/operator/retry_removal.rb +16 -0
  25. data/lib/evilution/mutator/operator/send_mutation.rb +8 -1
  26. data/lib/evilution/mutator/operator/string_interpolation.rb +32 -0
  27. data/lib/evilution/mutator/operator/string_literal.rb +18 -0
  28. data/lib/evilution/mutator/registry.rb +19 -3
  29. data/lib/evilution/related_spec_heuristic.rb +63 -0
  30. data/lib/evilution/reporter/cli.rb +14 -8
  31. data/lib/evilution/reporter/html.rb +32 -2
  32. data/lib/evilution/reporter/json.rb +14 -0
  33. data/lib/evilution/result/coverage_gap.rb +35 -0
  34. data/lib/evilution/result/coverage_gap_grouper.rb +22 -0
  35. data/lib/evilution/result/summary.rb +5 -0
  36. data/lib/evilution/runner.rb +28 -1
  37. data/lib/evilution/session/store.rb +13 -0
  38. data/lib/evilution/temp_dir_tracker.rb +39 -0
  39. data/lib/evilution/version.rb +1 -1
  40. data/lib/evilution.rb +9 -0
  41. metadata +17 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a4c7494a072237a00c9d7d58ad405b454a702ccbe1583090ec9702a0e9d25f13
4
- data.tar.gz: 80a563a5cfce99b212a9002064d0163700eb583192bca1aeac8615c75165e67f
3
+ metadata.gz: c8f4aa7633e70e4a54aded76fcdfeb152cb4e4ad76d587b5aa0c93bda96246e3
4
+ data.tar.gz: b8e65e5d0837b6873c31e6cae9621160a2a6fe75b3949d08a39f91b3df7db60b
5
5
  SHA512:
6
- metadata.gz: 04d89d24c4287d5863c9fcab61e38d2dc4a254cd2a54f729147b51390c41904237a639f4042a6563147b5ab5c978dc2cf0295c1bdc71a6a9e35f9a0d80f2139c
7
- data.tar.gz: 55459bde7f70ec8061f6df67ce582b8fcbe942ce40452add6737d00cb52e92cd5859997b87474666a31e65ffb966600d32fd910300c604bbced4a98d78d1ce0f
6
+ metadata.gz: 923d8fa302a830d1b070e27b2494c5ec3227f6c6188b26f1701a0344e54ac230626a75bd4f0ec70d6e4f10af04e5e62d04b05d93c067ee160ce3c653e86faaf6
7
+ data.tar.gz: f63389c729c4d121cb24a38a2bd9bd4d386707f81c16dbfd106868e952d72200278cd84fc0936ad60e666e53b5c51efce7d40a615c093d5fc327e1e910a39fd4
@@ -1 +1 @@
1
- 1775460080
1
+ 1775646585
data/.beads/issues.jsonl CHANGED
@@ -114,7 +114,7 @@
114
114
  {"id":"EV-196","title":"Show code diffs for survived mutations in text output","description":"Show the exact code diff (original vs mutated) for each survived mutation in the text reporter output, similar to how Mutant displays survived mutants. Currently Evilution shows the mutation description but not the visual diff. This was specifically requested in comparison testing feedback as it helps users quickly understand what test is missing.","status":"in_progress","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:21:02.574157928+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-03T11:00:52.543373742+07:00"}
115
115
  {"id":"EV-197","title":"Implement module include/extend removal","description":"Mutate include/extend/prepend statements: remove each one individually. Tests whether the mixin is actually used.","status":"in_progress","priority":3,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:21:13.978482592+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-28T23:57:39.685072781+07:00","dependencies":[{"issue_id":"EV-197","depends_on_id":"EV-194","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
116
116
  {"id":"EV-198","title":"Add RSpec suggestion templates for class/module mutations","description":"Add concrete suggestion templates for survived class/module mutations.","status":"in_progress","priority":3,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:21:23.284834592+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-28T23:47:56.899533924+07:00","dependencies":[{"issue_id":"EV-198","depends_on_id":"EV-194","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
117
- {"id":"EV-199","title":"Implement keyword argument mutations","description":"Add mutations for keyword arguments and optional keyword argument defaults. Mutations: remove keyword arg default value, swap keyword arg with positional, remove optional keyword. Prism keyword_hash_node, keyword_rest_parameter_node.","notes":"GitHub: #492","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:21:33.74262984+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:12:13.891912984+07:00"}
117
+ {"id":"EV-199","title":"Implement keyword argument mutations","description":"Add mutations for keyword arguments and optional keyword argument defaults. Mutations: remove keyword arg default value, swap keyword arg with positional, remove optional keyword. Prism keyword_hash_node, keyword_rest_parameter_node.","notes":"GitHub: #492","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:21:33.74262984+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T12:55:11.315819563+07:00","closed_at":"2026-04-07T12:55:11.315819563+07:00","close_reason":"Already implemented in v0.18.0: keyword_argument operator removes defaults, removes optional keywords, removes **kwargs rest parameters. Shipped with spec coverage."}
118
118
  {"id":"EV-2","title":"Phase 1: Foundation — End-to-End Single Mutation","description":"Build the core pipeline: parse Ruby with Prism, generate mutations, fork-based isolation, RSpec integration, JSON reporting. Milestone: Runner.new(files: ['lib/user.rb']).call produces JSON output.","status":"closed","priority":2,"issue_type":"epic","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-02T00:04:58.737191467+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-02T11:02:00.342745637+07:00","closed_at":"2026-03-02T11:02:00.342745637+07:00","close_reason":"Phase 1 Foundation complete: Config, AST::Parser, Subject, SourceSurgeon, Mutation, Mutator::Base+Registry, ComparisonReplacement, Isolation::Fork, Integration::RSpec, Result objects, Reporter::JSON, Runner — all 13 tasks done"}
119
119
  {"id":"EV-2.1","title":"Implement Evilution::Config","description":"Immutable configuration value object. Fields: target_files, jobs (default: Etc.nprocessors), timeout (default: 10s), format (:json/:text), diff_base (nil), min_score (0.0), integration (:rspec), config_file path. Merge from defaults + YAML + CLI flags. File: lib/evilution/config.rb + spec.","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-02T00:05:50.275297792+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-02T10:43:14.688620834+07:00","closed_at":"2026-03-02T10:43:14.688620834+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-2.1","depends_on_id":"EV-2","type":"parent-child","created_at":"0001-01-01T00:00:00Z"}]}
120
120
  {"id":"EV-2.10","title":"Implement Evilution::Integration::Base and RSpec adapter","description":"Base: abstract adapter with interface #call(test_files) -> {passed: bool, example_count: int, failure_count: int}. RSpec: programmatic runner using RSpec::Core::Runner.run with StringIO for capture. Auto-detects spec/ directory. Files: lib/evilution/integration/base.rb, lib/evilution/integration/rspec.rb + specs.","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-02T00:05:51.246990324+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-02T10:58:18.324768622+07:00","closed_at":"2026-03-02T10:58:18.324768622+07:00","close_reason":"Integration::Base and Integration::RSpec implemented with 8 passing specs","dependencies":[{"issue_id":"EV-2.10","depends_on_id":"EV-2","type":"parent-child","created_at":"0001-01-01T00:00:00Z"}]}
@@ -130,9 +130,9 @@
130
130
  {"id":"EV-2.8","title":"Implement Evilution::Result::MutationResult and Summary","description":"MutationResult: value object with fields: mutation, status (:killed/:survived/:timeout/:error), duration, killing_test (optional). Summary: aggregates MutationResult array into total/killed/survived/timed_out/errors/score/duration. Files: lib/evilution/result/mutation_result.rb, lib/evilution/result/summary.rb + specs.","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-02T00:05:51.022249568+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-02T10:51:08.482621898+07:00","closed_at":"2026-03-02T10:51:08.482621898+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-2.8","depends_on_id":"EV-2","type":"parent-child","created_at":"0001-01-01T00:00:00Z"}]}
131
131
  {"id":"EV-2.9","title":"Implement Evilution::Isolation::Fork","description":"Fork-based process isolation. Method: run(mutation, test_command, timeout:) -> MutationResult. Flow: create pipe, fork child, child applies mutation via eval, child runs test command, marshal result back via pipe, parent reads with IO.select timeout, SIGKILL on deadline. File: lib/evilution/isolation/fork.rb + spec.","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-02T00:05:51.142167275+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-02T10:54:08.819310594+07:00","closed_at":"2026-03-02T10:54:08.819310594+07:00","close_reason":"Fork isolation implemented with 6 passing specs","dependencies":[{"issue_id":"EV-2.9","depends_on_id":"EV-2","type":"parent-child","created_at":"0001-01-01T00:00:00Z"},{"issue_id":"EV-2.9","depends_on_id":"EV-2.8","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
132
132
  {"id":"EV-20","title":"Deprecate coverage filtering","description":"With line-range and method-name targeting, coverage collection adds overhead for little benefit. Deprecate --no-coverage flag, coverage config key, and remove coverage logic from runner.","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-10T00:30:58.837659684+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-10T00:33:06.453669976+07:00","closed_at":"2026-03-10T00:33:06.453669976+07:00","close_reason":"Deprecated coverage filtering: CLI warns on --no-coverage, config warns on coverage key, runner no longer uses coverage logic"}
133
- {"id":"EV-200","title":"Implement multiple assignment (masgn) mutations","description":"Add mutations for destructuring/parallel assignment (a, b = 1, 2). Mutations: remove individual assignment targets, swap assignment order, reduce to single assignment. Prism multi_write_node.","notes":"GitHub: #493","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:21:44.259585319+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:12:14.085581135+07:00"}
134
- {"id":"EV-201","title":"Implement yield statement mutations","description":"Add mutations for yield statements. Mutations: remove yield, remove yield arguments, replace yield value with nil. Prism yield_node.","notes":"GitHub: #494","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:21:53.437749245+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:12:14.275449093+07:00"}
135
- {"id":"EV-202","title":"Implement splat operator mutations","description":"Add mutations for splat (*) and double-splat (**) operators. Mutations: remove splat (pass array directly), remove double-splat (pass hash directly). Prism splat_node, assoc_splat_node.","notes":"GitHub: #491","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:22:01.958187896+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:12:13.694553415+07:00"}
133
+ {"id":"EV-200","title":"Implement multiple assignment (masgn) mutations","description":"Add mutations for destructuring/parallel assignment (a, b = 1, 2). Mutations: remove individual assignment targets, swap assignment order, reduce to single assignment. Prism multi_write_node.","notes":"GitHub: #493","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:21:44.259585319+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T13:08:55.884730359+07:00","closed_at":"2026-04-07T13:08:55.884730359+07:00","close_reason":"Already implemented in v0.18.0: multiple_assignment operator removes individual targets and swaps 2-element order. Shipped with spec coverage."}
134
+ {"id":"EV-201","title":"Implement yield statement mutations","description":"Add mutations for yield statements. Mutations: remove yield, remove yield arguments, replace yield value with nil. Prism yield_node.","notes":"GitHub: #494","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:21:53.437749245+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T13:09:26.882361994+07:00","closed_at":"2026-04-07T13:09:26.882361994+07:00","close_reason":"Already implemented in v0.18.0: yield_statement operator removes yield, removes yield arguments, replaces yield value with nil. Shipped with spec coverage."}
135
+ {"id":"EV-202","title":"Implement splat operator mutations","description":"Add mutations for splat (*) and double-splat (**) operators. Mutations: remove splat (pass array directly), remove double-splat (pass hash directly). Prism splat_node, assoc_splat_node.","notes":"GitHub: #491","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:22:01.958187896+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T12:13:59.203448703+07:00","closed_at":"2026-04-07T12:13:59.203448703+07:00","close_reason":"Already implemented in v0.18.0: lib/evilution/mutator/operator/splat_operator.rb with spec. Removes splat (*) and double-splat (**) operators. Listed in operator table and changelog."}
136
136
  {"id":"EV-203","title":"Epic: Extended equivalent mutation detection","description":"Extend equivalent mutation detection with more heuristics and manual marking support. Evilution's equivalent detection is already praised in feedback; extending it further strengthens a competitive advantage.","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:22:11.400012571+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-23T11:22:11.400012571+07:00"}
137
137
  {"id":"EV-204","title":"Add more automatic equivalence heuristics","description":"Add new equivalence detection strategies: frozen string mutations (frozen strings are immutable, mutation is equivalent), private method rename (if only called internally with same signature), constant folding equivalences.","status":"in_progress","priority":3,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:22:20.07787144+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-28T21:21:19.35465527+07:00","dependencies":[{"issue_id":"EV-204","depends_on_id":"EV-203","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
138
138
  {"id":"EV-205","title":"Support # evilution:equivalent manual marking","description":"Allow users to mark specific mutations as equivalent using source comments: # evilution:equivalent. These should be excluded from the score denominator like auto-detected equivalents.","status":"in_progress","priority":3,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:22:31.543822152+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-28T22:08:20.967272294+07:00","dependencies":[{"issue_id":"EV-205","depends_on_id":"EV-203","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
@@ -145,18 +145,18 @@
145
145
  {"id":"EV-211","title":"Implement regex capture reference (, ) mutations","description":"Add mutations for numbered regex capture references ($1, $2, etc.). Mutations: swap capture numbers ($1↔$2), replace with nil. Prism numbered_reference_read_node.","status":"open","priority":4,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:23:30.659728763+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-23T11:23:30.659728763+07:00"}
146
146
  {"id":"EV-212","title":"Implement self reference mutations","description":"Add mutations for self references. Mutations: remove self where it's used as an explicit receiver (self.foo → foo). Prism self_node.","status":"open","priority":4,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-23T11:23:42.173027795+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-23T11:23:42.173027795+07:00"}
147
147
  {"id":"EV-213","title":"Critical: SourceSurgeon crashes on multi-byte UTF-8 source files","description":"SourceSurgeon.apply uses String#[]= with Prism byte offsets, but Ruby String#[]= interprets indices as character offsets for UTF-8 strings. This causes IndexError on files containing multi-byte characters (e.g. Cyrillic, CJK, emoji). Fix: use source.b to force ASCII-8BIT before byte-offset operations, or use byteslice-based replacement. Reported by end user on 2026-03-29 against v0.16.0.","status":"closed","priority":0,"issue_type":"bug","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-29T23:19:47.803570297+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:14:32.115438439+07:00","closed_at":"2026-04-04T11:14:32.115438439+07:00","close_reason":"Fixed in commit e973a13, released in v0.17.0. SourceSurgeon now uses binary encoding for byte-offset operations."}
148
- {"id":"EV-214","title":"While/until flip mutation","description":"Add mutation that swaps while cond to until cond and vice versa. Prism: while_node, until_node. Small operator.","notes":"GitHub: #495","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:15.904741396+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:11:48.098621754+07:00","dependencies":[{"issue_id":"EV-214","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
149
- {"id":"EV-215","title":"defined? -> true mutation","description":"Add mutation that replaces defined?(expr) with true. Prism: defined_node. Small operator.","notes":"GitHub: #496","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:21.037349751+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:11:48.438019342+07:00","dependencies":[{"issue_id":"EV-215","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
150
- {"id":"EV-216","title":"String interpolation content mutation","description":"Add mutations for string interpolation content. Replace #{expr} with #{nil} or empty string. Prism: interpolated_string_node, embedded_statements_node. Medium operator.","notes":"GitHub: #497","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:22.095986111+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:11:48.90150684+07:00","dependencies":[{"issue_id":"EV-216","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
151
- {"id":"EV-217","title":"== -> .equal? identity mutation","description":"Add mutation that replaces a == b with a.equal?(b) (object identity check). Prism: call_node with method ==. Small operator.","notes":"GitHub: #501","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:22.723044425+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:12:01.958573728+07:00","dependencies":[{"issue_id":"EV-217","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
152
- {"id":"EV-218","title":"case/when branch mutations","description":"Add mutations for case/when statements. Remove individual when-branches, replace when body with nil, remove else branch. Prism: case_node, when_node. Medium operator.","notes":"GitHub: #498","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:22.912808107+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:11:49.955500409+07:00","dependencies":[{"issue_id":"EV-218","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
153
- {"id":"EV-219","title":"retry removal mutation","description":"Add mutation that removes retry statements in rescue blocks (replace with nil). Prism: retry_node. Small operator.","notes":"GitHub: #499","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:23.739947781+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:11:50.342965697+07:00","dependencies":[{"issue_id":"EV-219","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
148
+ {"id":"EV-214","title":"While/until flip mutation","description":"Add mutation that swaps while cond to until cond and vice versa. Prism: while_node, until_node. Small operator.","notes":"GitHub: #495","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:15.904741396+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T14:17:43.503188236+07:00","closed_at":"2026-04-07T14:17:43.503188236+07:00","close_reason":"Implemented: loop_flip operator swaps while/until loops (block and modifier forms). 7 tests, 61 operators total. Merged via GH #495.","dependencies":[{"issue_id":"EV-214","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
149
+ {"id":"EV-215","title":"defined? -> true mutation","description":"Add mutation that replaces defined?(expr) with true. Prism: defined_node. Small operator.","notes":"GitHub: #496","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:21.037349751+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T14:17:56.362814861+07:00","closed_at":"2026-04-07T14:17:56.362814861+07:00","close_reason":"Already implemented in v0.18.0: defined_check operator replaces defined?(expr) with true. Shipped with spec coverage.","dependencies":[{"issue_id":"EV-215","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
150
+ {"id":"EV-216","title":"String interpolation content mutation","description":"Add mutations for string interpolation content. Replace #{expr} with #{nil} or empty string. Prism: interpolated_string_node, embedded_statements_node. Medium operator.","notes":"GitHub: #497","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:22.095986111+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T18:10:51.520585633+07:00","closed_at":"2026-04-07T18:10:51.520585633+07:00","close_reason":"Implemented: string_interpolation operator replaces #{expr} with #{nil} in interpolated strings and symbols. 10 tests, 62 operators total. Merged via GH #497.","dependencies":[{"issue_id":"EV-216","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
151
+ {"id":"EV-217","title":"== -> .equal? identity mutation","description":"Add mutation that replaces a == b with a.equal?(b) (object identity check). Prism: call_node with method ==. Small operator.","notes":"GitHub: #501","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:22.723044425+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T21:57:45.261222921+07:00","closed_at":"2026-04-07T21:57:45.261222921+07:00","close_reason":"Implemented: equality_to_identity operator replaces a == b with a.equal?(b). 8 tests, 66 operators total. Merged via GH #501.","dependencies":[{"issue_id":"EV-217","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
152
+ {"id":"EV-218","title":"case/when branch mutations","description":"Add mutations for case/when statements. Remove individual when-branches, replace when body with nil, remove else branch. Prism: case_node, when_node. Medium operator.","notes":"GitHub: #498","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:22.912808107+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T21:04:32.266231607+07:00","closed_at":"2026-04-07T21:04:32.266231607+07:00","close_reason":"Implemented: case_when operator removes when branches, replaces when body with nil, removes else branch. 9 tests, 64 operators total. Merged via GH #498.","dependencies":[{"issue_id":"EV-218","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
153
+ {"id":"EV-219","title":"retry removal mutation","description":"Add mutation that removes retry statements in rescue blocks (replace with nil). Prism: retry_node. Small operator.","notes":"GitHub: #499","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:23.739947781+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T20:42:58.086369513+07:00","closed_at":"2026-04-07T20:42:58.086369513+07:00","close_reason":"Implemented: retry_removal operator replaces retry with nil. 6 tests, 63 operators total. Merged via GH #499.","dependencies":[{"issue_id":"EV-219","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
154
154
  {"id":"EV-22","title":"Add --fail-fast flag with survivor threshold","description":"Add --fail-fast [N] CLI flag and fail_fast config option to stop mutation testing after N surviving mutants (default N=1 when flag given without value). Agents fix gaps iteratively, so discovering all survivors upfront is wasted work. A threshold gives control over the speed/thoroughness tradeoff: --fail-fast 1 for quick checks, --fail-fast 5 for CI gates, omit for full scans. Runner#call should stop running mutations and return a partial Summary once the threshold is reached. JSON output should include a 'truncated: true' field when fail-fast triggered.","status":"closed","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-10T06:17:28.018733235+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-16T10:11:01.311500554+07:00","closed_at":"2026-03-16T10:11:01.311500554+07:00","close_reason":"Already merged and released in v0.4.0"}
155
- {"id":"EV-220","title":"Predicate method -> true/false mutation","description":"Add mutation that replaces predicate method calls (methods ending with ?) with true and false literals. Existing NegationInsertion inserts ! before predicates but does not replace with literal boolean. Prism: call_node where method name ends with ?. Small operator.","notes":"GitHub: #500","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:25.02387319+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:11:50.77861531+07:00","dependencies":[{"issue_id":"EV-220","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
156
- {"id":"EV-221","title":"Method body -> self/super replacement","description":"Extend MethodBodyReplacement to also replace method body with self and super (currently only replaces with nil). Mutant does all three: nil, self, super. Small enhancement to existing operator.","notes":"GitHub: #502","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:36.202930745+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:12:02.230820607+07:00","dependencies":[{"issue_id":"EV-221","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
157
- {"id":"EV-222","title":"Proc/lambda body mutation","description":"Add mutation that replaces proc/lambda body with nil. ->() { expr } becomes ->() { nil }. Not covered by BlockRemoval which handles do..end/{ } blocks on method calls. Prism: lambda_node. Small operator.","notes":"GitHub: #503","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:38.002122541+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:12:02.561937274+07:00","dependencies":[{"issue_id":"EV-222","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
158
- {"id":"EV-223","title":"begin..end unwrap mutation","description":"Add mutation that removes begin/end wrapper, leaving just the body statements. begin; expr; end becomes expr. Prism: begin_node. Small operator.","notes":"GitHub: #504","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:38.269119824+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:12:03.442158099+07:00","dependencies":[{"issue_id":"EV-223","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
159
- {"id":"EV-224","title":"Block argument (&block) removal mutation","description":"Add mutation that removes explicit block parameter from method definitions. def foo(&block) becomes def foo. Prism: block_parameter_node. Small operator.","notes":"GitHub: #505","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:37.302228714+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:12:03.723910985+07:00","dependencies":[{"issue_id":"EV-224","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
155
+ {"id":"EV-220","title":"Predicate method -> true/false mutation","description":"Add mutation that replaces predicate method calls (methods ending with ?) with true and false literals. Existing NegationInsertion inserts ! before predicates but does not replace with literal boolean. Prism: call_node where method name ends with ?. Small operator.","notes":"GitHub: #500","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:25.02387319+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T21:26:20.744321395+07:00","closed_at":"2026-04-07T21:26:20.744321395+07:00","close_reason":"Implemented: predicate_replacement operator replaces predicate calls with true and false. 8 tests, 65 operators total. Merged via GH #500.","dependencies":[{"issue_id":"EV-220","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
156
+ {"id":"EV-221","title":"Method body -> self/super replacement","description":"Extend MethodBodyReplacement to also replace method body with self and super (currently only replaces with nil). Mutant does all three: nil, self, super. Small enhancement to existing operator.","notes":"GitHub: #502","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:36.202930745+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T22:16:01.369689765+07:00","closed_at":"2026-04-07T22:16:01.369689765+07:00","close_reason":"Implemented: method_body_replacement now replaces body with nil, self, and super (up from nil only). 7 tests. Merged via GH #502.","dependencies":[{"issue_id":"EV-221","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
157
+ {"id":"EV-222","title":"Proc/lambda body mutation","description":"Add mutation that replaces proc/lambda body with nil. ->() { expr } becomes ->() { nil }. Not covered by BlockRemoval which handles do..end/{ } blocks on method calls. Prism: lambda_node. Small operator.","notes":"GitHub: #503","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:38.002122541+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T23:35:25.41137258+07:00","closed_at":"2026-04-07T23:35:25.41137258+07:00","close_reason":"Implemented: lambda_body operator replaces lambda body with nil. 7 tests, 67 operators total. Merged via GH #503.","dependencies":[{"issue_id":"EV-222","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
158
+ {"id":"EV-223","title":"begin..end unwrap mutation","description":"Add mutation that removes begin/end wrapper, leaving just the body statements. begin; expr; end becomes expr. Prism: begin_node. Small operator.","notes":"GitHub: #504","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:38.269119824+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T08:35:47.716813843+07:00","closed_at":"2026-04-08T08:35:47.716813843+07:00","close_reason":"Implemented: begin_unwrap operator removes begin/end wrapper leaving body statements. 7 tests, 68 operators total. Merged via GH #504.","dependencies":[{"issue_id":"EV-223","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
159
+ {"id":"EV-224","title":"Block argument (&block) removal mutation","description":"Add mutation that removes explicit block parameter from method definitions. def foo(&block) becomes def foo. Prism: block_parameter_node. Small operator.","notes":"GitHub: #505","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:11:37.302228714+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T08:41:59.58270935+07:00","closed_at":"2026-04-08T08:41:59.58270935+07:00","close_reason":"Implemented: block_param_removal operator removes &block parameter from method definitions. 7 tests, 69 operators total. Merged via GH #505.","dependencies":[{"issue_id":"EV-224","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
160
160
  {"id":"EV-225","title":"Bug: Version field in JSON output not updated after version bump","description":"Evilution JSON output (both CLI --format json and MCP tool response) reports version as 0.17.0 when evilution --version says 0.18.0. The MCP server correctly references Evilution::VERSION constant, so the issue is likely that VERSION constant was not bumped to 0.18.0 in lib/evilution/version.rb. Reported across 5 consecutive feedback sessions on 2026-04-04.","notes":"GitHub: #506","status":"closed","priority":0,"issue_type":"bug","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:20:30.428077285+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T13:15:11.40532407+07:00","closed_at":"2026-04-04T13:15:11.40532407+07:00","close_reason":"Not a bug. MCP server is a long-running process — bundle update changes files on disk but the loaded Ruby process retains the old VERSION constant. Restart the MCP server after gem updates. Generic MCP behavior, not evilution-specific."}
161
161
  {"id":"EV-226","title":"Bug: Memory leak: RSS grows linearly per mutation without releasing","description":"During mutation runs, child process RSS grows ~3-8 MB per mutation without releasing. Observed on v0.18.0: RSS went from 190 MB to 730 MB across 159 mutations on a 46-line file (~3.4 MB/mutation average delta). Previous memory fixes (AST node release, StringIO drain) helped but did not fully resolve. The leak appears to be in the fork/child process pool — memory accumulates across mutations within the same worker process. This should be investigated with rake memory:check and profiling tools.","notes":"GitHub: #507","status":"closed","priority":0,"issue_type":"bug","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:20:32.021072642+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-05T23:25:48.383886909+07:00","closed_at":"2026-04-05T23:25:48.383886909+07:00","close_reason":"Core leak fixed (EV-256), regression test added (EV-257). Residual ~128 KB/mutation from MRI Class#subclasses tracking — not fixable without Ruby changes. Follow-ups: EV-274, EV-275, EV-276."}
162
162
  {"id":"EV-227","title":"Smart spec auto-detection (narrow to matching spec file)","description":"Evilution's spec auto-detection selects too broad a test suite per mutation, causing mass timeouts and excessive memory usage. When --spec override is used to point at the correct spec file, timeouts disappear, speed improves 4-7x, and memory drops 6x (282 MB vs 1709 MB). The auto-detection should narrow to the closest matching spec file based on file path conventions (e.g., app/controllers/foo_controller.rb -> spec/requests/foo_spec.rb or spec/controllers/foo_controller_spec.rb). Reported in 7 separate feedback sessions from v0.12.0 through v0.17.0. This is the single biggest pain point in real-world usage. Evidence: HelpController 9-LOC file had 3/18 timeouts without --spec, 0/15 with --spec. GamesController had 25/246 timeouts (10.2%). HomeController: 110s without -> 29s with --spec, 1709 MB -> 282 MB.","status":"closed","priority":1,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:16.691637724+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T09:55:50.887685731+07:00","closed_at":"2026-04-07T09:55:50.887685731+07:00","close_reason":"All subtasks complete: controller→request spec mapping, model/service/lib/Avo conventions, fallback chain with warnings, integration tests with fixture layouts. SpecResolver handles all Rails and gem conventions with parent directory fallback and full-suite fallback with user warnings.","comments":[{"id":1,"issue_id":"EV-227","author":"Denis Kiselev","text":"GitHub issue: #508 (https://github.com/marinazzio/evilution/issues/508)","created_at":"2026-04-04T11:21:46.103310023+07:00"}]}
@@ -167,21 +167,21 @@
167
167
  {"id":"EV-227.5","title":"Implement Avo resource to spec convention mapping","description":"Map app/avo/resources/foo.rb to spec/avo/resources/foo_spec.rb. Mutant gets this wrong; evilution should get it right. Avo resources follow a predictable path convention.","notes":"GitHub: #553","status":"closed","priority":1,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:31:11.220551992+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-06T23:36:54.160582811+07:00","closed_at":"2026-04-06T23:36:54.160582811+07:00","close_reason":"Already handled by existing app/ prefix-stripping logic. Verified for avo/resources/ and avo/actions/.","dependencies":[{"issue_id":"EV-227.5","depends_on_id":"EV-227","type":"parent-child","created_at":"0001-01-01T00:00:00Z"}]}
168
168
  {"id":"EV-227.6","title":"Implement fallback chain when primary convention doesn't match","description":"If the convention-mapped spec file doesn't exist, try parent directory patterns, then fall back to full suite. Log a warning when falling back so users know auto-detection couldn't narrow the spec.","notes":"GitHub: #555","status":"closed","priority":1,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:31:33.254382872+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T09:54:52.004819913+07:00","closed_at":"2026-04-07T09:54:52.004819913+07:00","close_reason":"Fully implemented: parent_fallback_candidates in SpecResolver walks up directory tree. Warnings logged in both baseline.rb and integration/rspec.rb when falling back to full suite. Covered by unit, integration, baseline, and rspec integration tests. Merged via GH #555.","dependencies":[{"issue_id":"EV-227.6","depends_on_id":"EV-227","type":"parent-child","created_at":"0001-01-01T00:00:00Z"}]}
169
169
  {"id":"EV-227.7","title":"Add integration tests for spec auto-detection with fixture project layouts","description":"Test Rails conventions (controller, model, service, Avo), non-Rails lib layout, and fallback behavior using fixture directories under spec/support/fixtures/. Cover all convention mappings and the fallback chain.","notes":"GitHub: #556","status":"closed","priority":1,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:31:58.393834666+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T09:39:42.378355211+07:00","closed_at":"2026-04-07T09:39:42.378355211+07:00","close_reason":"Integration tests added for all spec auto-detection conventions (Rails controller/model/service/Avo, gem lib/, fallback chain) using fixture project layouts. 15 tests passing. Merged via GH #556.","dependencies":[{"issue_id":"EV-227.7","depends_on_id":"EV-227","type":"parent-child","created_at":"0001-01-01T00:00:00Z"}]}
170
- {"id":"EV-228","title":"Equivalent detection: .count → .length as always-equivalent","description":".count → .length mutations are universally unkillable (both return identical integer results). Evilution should detect this pattern and classify as equivalent automatically. Reported in feedback for HomeController stats block.","notes":"GH #509","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:43.587875972+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:22:55.878850271+07:00"}
171
- {"id":"EV-229","title":"Equivalent detection: .each → .map in void context","description":"When .each is called in void context (return value not assigned or passed), replacing with .map or .reverse_each produces equivalent behavior. Evilution should detect void-context method calls and mark these swaps as likely-equivalent. Reported for Avo reset_password action.","notes":"GH #511","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:46.8330208+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:22:56.769310284+07:00"}
170
+ {"id":"EV-228","title":"Equivalent detection: .count → .length as always-equivalent","description":".count → .length mutations are universally unkillable (both return identical integer results). Evilution should detect this pattern and classify as equivalent automatically. Reported in feedback for HomeController stats block.","notes":"GH #509","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:43.587875972+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T08:52:50.669215278+07:00","closed_at":"2026-04-08T08:52:50.669215278+07:00","close_reason":"Closed"}
171
+ {"id":"EV-229","title":"Equivalent detection: .each → .map in void context","description":"When .each is called in void context (return value not assigned or passed), replacing with .map or .reverse_each produces equivalent behavior. Evilution should detect void-context method calls and mark these swaps as likely-equivalent. Reported for Avo reset_password action.","notes":"GH #511","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:46.8330208+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T09:31:47.874981801+07:00","closed_at":"2026-04-08T09:31:47.874981801+07:00","close_reason":"Closed"}
172
172
  {"id":"EV-23","title":"Per-mutation spec targeting","description":"Instead of running the full spec suite for every mutation, map each mutated source file to its relevant spec file(s) using convention-based resolution (e.g. lib/foo/bar.rb -> spec/foo/bar_spec.rb) and only run those. This dramatically reduces per-mutation test time. Depends on convention-based spec file resolution being implemented first.","status":"closed","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-10T06:17:28.98620973+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-16T14:49:13.616876819+07:00","closed_at":"2026-03-16T14:49:13.616876819+07:00","close_reason":"Fixed and merged","dependencies":[{"issue_id":"EV-23","depends_on_id":"EV-34","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
173
173
  {"id":"EV-230","title":"Regex simplification operators","description":"Add mutation operators for regex patterns: /\\s+/ → /\\s/ (remove quantifier), remove anchors (^, $, \\A, \\z), simplify character classes. Mutant's regex mutations caught real test gaps (case sensitivity, whitespace handling) that evilution missed. Reported in 2 sessions on Telegram::NewsScorer.","notes":"GH #514","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:48.930372762+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:22:57.239710634+07:00","dependencies":[{"issue_id":"EV-230","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
174
- {"id":"EV-231","title":".downcase removal operator","description":"Add mutation that removes .downcase calls. This caught real case-sensitivity test gaps in mutant that evilution missed. Useful for testing that code handles mixed-case input. Reported in 2 sessions on NewsScorer.","notes":"GH #516","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:50.682791593+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:22:57.718594841+07:00","dependencies":[{"issue_id":"EV-231","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
175
- {"id":"EV-232","title":"Method chain permutation operators (strip → lstrip/rstrip)","description":"Add mutations that replace string cleaning methods with partial variants: strip → lstrip/rstrip, chomp → chop, etc. Mutant's chain permutations caught a real test gap in NewsScorer keyword processing. Reported in 1 session.","notes":"GH #518","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:52.982750285+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:22:58.679882177+07:00","dependencies":[{"issue_id":"EV-232","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
176
- {"id":"EV-233","title":"Related specs heuristic (run association specs when .includes() mutated)","description":"When mutations remove .includes() eager loading calls, the matching unit spec may not catch N+1 regressions. Consider a heuristic that also runs specs for the included associations or integration specs. Would complement the spec auto-detection feature. Reported in 1 session for NewsController.","notes":"GH #519","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:56.302076763+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:22:59.026458465+07:00"}
177
- {"id":"EV-234","title":"Conceptual deduplication of survived mutations","description":"Multiple operators can flag the same underlying coverage gap (e.g., .includes removal via method_call_removal and symbol_literal both reveal missing eager-load test). Add a post-processing pass that groups conceptually similar survivors and presents them as a single coverage gap with multiple mutation evidence. Reduces noise in reports.","notes":"GitHub: #510","status":"open","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:58.378005036+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:22:53.787757503+07:00"}
174
+ {"id":"EV-231","title":".downcase removal operator","description":"Add mutation that removes .downcase calls. This caught real case-sensitivity test gaps in mutant that evilution missed. Useful for testing that code handles mixed-case input. Reported in 2 sessions on NewsScorer.","notes":"GH #516","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:50.682791593+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T09:42:19.793202916+07:00","closed_at":"2026-04-08T09:42:19.793202916+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-231","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
175
+ {"id":"EV-232","title":"Method chain permutation operators (strip → lstrip/rstrip)","description":"Add mutations that replace string cleaning methods with partial variants: strip → lstrip/rstrip, chomp → chop, etc. Mutant's chain permutations caught a real test gap in NewsScorer keyword processing. Reported in 1 session.","notes":"GH #518","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:52.982750285+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T11:15:28.398677068+07:00","closed_at":"2026-04-08T11:15:28.398677068+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-232","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
176
+ {"id":"EV-233","title":"Related specs heuristic (run association specs when .includes() mutated)","description":"When mutations remove .includes() eager loading calls, the matching unit spec may not catch N+1 regressions. Consider a heuristic that also runs specs for the included associations or integration specs. Would complement the spec auto-detection feature. Reported in 1 session for NewsController.","notes":"GH #519","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:56.302076763+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T12:16:09.453069408+07:00","closed_at":"2026-04-08T12:16:09.453069408+07:00","close_reason":"Closed"}
177
+ {"id":"EV-234","title":"Conceptual deduplication of survived mutations","description":"Multiple operators can flag the same underlying coverage gap (e.g., .includes removal via method_call_removal and symbol_literal both reveal missing eager-load test). Add a post-processing pass that groups conceptually similar survivors and presents them as a single coverage gap with multiple mutation evidence. Reduces noise in reports.","notes":"GitHub: #510","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:21:58.378005036+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T09:21:20.475702136+07:00","closed_at":"2026-04-08T09:21:20.475702136+07:00","close_reason":"Closed"}
178
178
  {"id":"EV-235","title":"Bug: Non-deterministic mutation count on same file","description":"Running evilution twice on the same file (HelpController, 9 LOC) produced different mutation counts (18 vs 15). Unclear cause — possibly non-deterministic operator selection or file state difference. Low priority but should be investigated. Reported once in v0.12.0.","notes":"GitHub: #512","status":"closed","priority":4,"issue_type":"bug","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:22:01.930671333+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T13:20:37.135440498+07:00","closed_at":"2026-04-04T13:20:37.135440498+07:00","close_reason":"Not a bug. The 18 vs 15 difference was exactly the 3 timed-out mutations — counted in run 1 total but excluded in run 2 summary. Mutation generation is fully deterministic (no rand/shuffle/sample in codepath). Reported once in v0.12.0, never reproduced. Reporting has been significantly improved since then."}
179
179
  {"id":"EV-236","title":"--spec-dir flag for directory-level spec inclusion","description":"Add a --spec-dir flag that auto-includes all specs in a directory, reducing the chance of missing coverage from adjacent spec files. Useful when a controller has tests split across spec/requests/, spec/controllers/, and spec/features/. Reported once.","notes":"GitHub: #513","status":"closed","priority":4,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:22:04.618160285+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-07T09:55:50.99913701+07:00","closed_at":"2026-04-07T09:55:50.99913701+07:00","close_reason":"--spec-dir CLI flag implemented, composes with --spec, validates directory existence. 3 unit tests passing. Merged via GH #513.","dependencies":[{"issue_id":"EV-236","depends_on_id":"EV-227","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
180
- {"id":"EV-237","title":"Temp-file based mutation (don't modify original source)","description":"Evilution mutates source files in-place on the filesystem, which triggers file watchers, linters, and IDE notifications during runs. Even with the ensure-based restore (fixed earlier), race conditions exist if the process is killed. Write mutated source to a tempfile and point the test runner at it via load path manipulation. Never modify the original source file. Reported in 2 sessions (v0.16.1).","notes":"GH issue: #520 (https://github.com/marinazzio/evilution/issues/520)","status":"open","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:22:06.770551806+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:23:18.529285207+07:00","external_ref":"gh-520","labels":["reliability"]}
180
+ {"id":"EV-237","title":"Temp-file based mutation (don't modify original source)","description":"Evilution mutates source files in-place on the filesystem, which triggers file watchers, linters, and IDE notifications during runs. Even with the ensure-based restore (fixed earlier), race conditions exist if the process is killed. Write mutated source to a tempfile and point the test runner at it via load path manipulation. Never modify the original source file. Reported in 2 sessions (v0.16.1).","notes":"GH issue: #520 (https://github.com/marinazzio/evilution/issues/520)","status":"closed","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:22:06.770551806+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T15:52:59.896531797+07:00","closed_at":"2026-04-08T15:52:59.896531797+07:00","close_reason":"Closed","external_ref":"gh-520","labels":["reliability"]}
181
181
  {"id":"EV-238","title":"Epic: Research mutation density gap with mutant","description":"Evilution consistently generates 1.8-2.6x fewer mutations than mutant across 25 feedback sessions. While some of mutant's extras are equivalent ([]→fetch, to_i→Integer()), many catch real edge cases. This epic covers: (1) Audit mutant's operator list systematically against evilution's 54 operators, (2) Identify which missing operators catch real bugs vs produce noise, (3) Prioritize operator additions by signal-to-noise ratio, (4) Target closing the gap to <1.5x. Related: existing gap analysis created 15 new operator issues (EV-214 through EV-224, #491-#505).","notes":"GitHub: #515","status":"open","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:22:11.095318733+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:22:55.790159971+07:00"}
182
182
  {"id":"EV-239","title":"Epic: Research and fix high memory baseline","description":"Evilution's memory baseline is 718+ MB even for tiny files in v0.18.0 sessions, and grows across consecutive runs in the same session (718→763→795→800 MB). Previous fixes addressed AST node retention and StringIO leaks but baseline remains high. Mutant peaks at ~200 MB for comparable workloads. This epic covers: (1) Profile memory allocation during boot/setup phase, (2) Identify what's consuming the 718 MB baseline, (3) Investigate cross-run memory growth (session-level leak?), (4) Target bringing baseline under 300 MB. Related: existing rake memory:check infrastructure exists.","notes":"GitHub: #517","status":"closed","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:22:16.602817355+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-06T00:16:38.665740136+07:00","closed_at":"2026-04-06T00:16:38.665740136+07:00","close_reason":"Premise invalid: 718 MB baseline was the MCP host process, not evilution. Standalone evilution baseline is ~30 MB (confirmed via EV-242/245/246 profiling). No memory fix needed. Sub-issues resolved: EV-242 (30 MB boot baseline), EV-243 (single mutation profiled), EV-245 (no cross-run growth), EV-246 (fork has zero parent-side cost), EV-247 (RSS tracking added)."}
183
183
  {"id":"EV-24","title":"Epic: JSON Output Improvements","description":"Make JSON output fully machine-parseable in all scenarios, including errors. Add diagnostic fields that help agents debug failures.","status":"closed","priority":1,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-10T06:17:37.450686472+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-16T11:15:24.900944562+07:00","closed_at":"2026-03-16T11:15:24.900944562+07:00","close_reason":"All children complete: structured errors, test_command in JSON, noise suppression","dependencies":[{"issue_id":"EV-24","depends_on_id":"EV-25","type":"blocks","created_at":"0001-01-01T00:00:00Z"},{"issue_id":"EV-24","depends_on_id":"EV-26","type":"blocks","created_at":"0001-01-01T00:00:00Z"},{"issue_id":"EV-24","depends_on_id":"EV-40","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
184
- {"id":"EV-240","title":"Neutral mutation category (test errors vs test failures)","description":"Add a 'neutral' classification for mutations where tests error (crash/exception) rather than fail (assertion). This helps users distinguish test infrastructure problems from real coverage gaps. Mutant has this distinction and it's valuable — e.g., killfork 403 errors in vanilla-mafia are infrastructure noise, not coverage gaps. Currently evilution has neutral detection implemented but feedback suggests it doesn't always classify correctly. Reported in 3 sessions.","notes":"GH issue: #521 (https://github.com/marinazzio/evilution/issues/521)","status":"open","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:22:18.548454128+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:23:19.479497894+07:00","external_ref":"gh-521","labels":["reliability"]}
184
+ {"id":"EV-240","title":"Neutral mutation category (test errors vs test failures)","description":"Add a 'neutral' classification for mutations where tests error (crash/exception) rather than fail (assertion). This helps users distinguish test infrastructure problems from real coverage gaps. Mutant has this distinction and it's valuable — e.g., killfork 403 errors in vanilla-mafia are infrastructure noise, not coverage gaps. Currently evilution has neutral detection implemented but feedback suggests it doesn't always classify correctly. Reported in 3 sessions.","notes":"GH issue: #521 (https://github.com/marinazzio/evilution/issues/521)","status":"in_progress","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:22:18.548454128+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T12:21:16.372929584+07:00","external_ref":"gh-521","labels":["reliability"]}
185
185
  {"id":"EV-241","title":"Heredoc-aware string literal mutations","description":"Evilution's string_literal operator generates many false survived mutants on heredoc templates by mutating whitespace and literal text around interpolations. MigrationGenerator scored 63.1% due to template whitespace mutations that don't affect generated code behavior. Should either skip literal text in heredocs, only mutate interpolated expressions, or add a --skip-heredoc-literals flag. Reported in 1 session but caused significant score distortion.","notes":"GH issue: #522 (https://github.com/marinazzio/evilution/issues/522)","status":"open","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:22:20.534650035+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:23:19.83846784+07:00","external_ref":"gh-522","labels":["reliability","false-positives"]}
186
186
  {"id":"EV-242","title":"Profile memory allocation during boot/setup phase","description":"Use memory_profiler gem or ObjectSpace to identify what objects are allocated during Evilution boot before any mutations run. Identify the top 10 memory consumers. This will help understand where the 718 MB baseline comes from.","notes":"GitHub: #527","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:28:39.583808805+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-05T23:36:18.3122267+07:00","closed_at":"2026-04-05T23:36:18.3122267+07:00","close_reason":"Boot footprint is ~30 MB. The 718 MB baseline was MCP host process, not evilution.","dependencies":[{"issue_id":"EV-242","depends_on_id":"EV-239","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
187
187
  {"id":"EV-243","title":"Profile memory allocation during single mutation cycle","description":"Measure memory before and after a single mutation+test cycle. Identify what is allocated and not released within one cycle. Compare with mutant's behavior for the same file.","notes":"GitHub: #528","status":"in_progress","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:28:46.085727121+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-05T23:37:08.936438689+07:00","dependencies":[{"issue_id":"EV-243","depends_on_id":"EV-239","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
@@ -190,28 +190,28 @@
190
190
  {"id":"EV-246","title":"Investigate parent vs child process memory split","description":"Measure RSS of the parent (coordinator) process separately from forked child (worker) processes. Determine where the 718 MB baseline lives — is it the parent before forking, or do children inherit and grow independently?","notes":"GitHub: #531","status":"in_progress","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:28:59.300347033+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-05T23:45:11.030185257+07:00","dependencies":[{"issue_id":"EV-246","depends_on_id":"EV-239","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
191
191
  {"id":"EV-247","title":"Add RSS tracking per mutation to JSON output","description":"Include parent_rss_kb and child_rss_kb fields in each mutation result. child_rss_kb partially exists (seen in feedback log) — verify it is accurate and add parent_rss_kb tracking. This provides ongoing observability for memory usage.","notes":"GitHub: #532","status":"in_progress","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:08.569266807+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-05T23:49:30.25391422+07:00","dependencies":[{"issue_id":"EV-247","depends_on_id":"EV-239","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
192
192
  {"id":"EV-248","title":"Implement memory budget CI gate","description":"Add a CI check that runs rake memory:check and fails if peak RSS exceeds a threshold (e.g., 400 MB for a reference fixture). This prevents memory regressions from being merged.","notes":"GitHub: #533","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:16.177682161+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-06T11:45:18.765568988+07:00","close_reason":"Growth-based leak detection in CI (EV-274/PR #571) is sufficient. Absolute peak RSS budget not needed — standalone baseline is ~30 MB (EV-239 premise was invalid). Per-mutation growth check catches regressions effectively.","dependencies":[{"issue_id":"EV-248","depends_on_id":"EV-239","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
193
- {"id":"EV-249","title":"Audit current SourceSurgeon mutation-and-restore flow","description":"Document the current code path: where the file is read, mutated, written, and restored. Identify all callers and the ensure-based restore mechanism. Map the failure modes (SIGKILL, OOM, etc.).","notes":"GitHub: #525","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:17.689070042+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:29:32.825847413+07:00","dependencies":[{"issue_id":"EV-249","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
193
+ {"id":"EV-249","title":"Audit current SourceSurgeon mutation-and-restore flow","description":"Document the current code path: where the file is read, mutated, written, and restored. Identify all callers and the ensure-based restore mechanism. Map the failure modes (SIGKILL, OOM, etc.).","notes":"## Audit Findings\n\n### Read Points\n1. **AST::Parser#call** (parser.rb:11) — File.read to parse with Prism\n2. **Mutator::Base#call** (base.rb:18) — File.read to store as original_source in Mutation\n3. **Integration::RSpec#apply_mutation** (rspec.rb:68) — reads before overwrite (direct-overwrite fallback only)\n4. **Isolation::Fork#restore_original_source** (fork.rb:48) — reads to verify if restore needed (defense-in-depth)\n\n### Mutation (In-Memory)\nSourceSurgeon.apply (source_surgeon.rb:6-10) is pure in-memory byte surgery. Never touches filesystem. Called from Mutator::Base#add_mutation.\n\n### Two Write Paths in Integration::RSpec#apply_mutation\n- **Path A (LOAD_PATH shadow, preferred):** Target under $LOAD_PATH → Dir.mktmpdir, write mutated source to mirrored subpath, prepend to $LOAD_PATH. Original file never touched.\n- **Path B (Direct overwrite, fallback):** Not under $LOAD_PATH → acquires exclusive flock, overwrites original file.\n\n### Restore — Two Layers\n- **Layer 1:** Integration::RSpec#restore_original via ensure in #call (rspec.rb:33-35). Path A: removes temp dir from $LOAD_PATH, purges $LOADED_FEATURES, deletes temp dir. Path B: writes @original_content back, releases flock.\n- **Layer 2:** Isolation::Fork#restore_original_source (fork.rb:47-53) — parent-process defense-in-depth. Only in sequential (Fork isolation) path. NOT in parallel path.\n\n### Execution Paths\n- **Sequential (jobs=1):** Runner → Isolation::Fork → fork child → Integration::RSpec#call → ensure restore (child) + ensure restore (parent)\n- **Parallel (jobs>1):** Runner → Parallel::Pool → WorkQueue forks workers → Isolation::InProcess → Integration::RSpec#call → ensure restore only. No parent-side defense-in-depth.\n\n### Failure Modes\n- Normal flow / exception: Safe on both paths\n- SIGKILL child (sequential): Safe (parent restores on direct-overwrite; file untouched on temp-dir)\n- **SIGKILL worker (parallel) + direct-overwrite: FILE CORRUPTED — no recovery**\n- **OOM parallel worker + direct-overwrite: FILE CORRUPTED**\n- **SIGINT/SIGTERM to parent + direct-overwrite: File may be corrupted (zero signal handlers in lib/)**\n- Disk full during restore: File stays corrupted\n\n### Key Findings\n- Zero trap/at_exit/Signal.trap calls in entire lib/ directory\n- Biggest risk: direct-overwrite fallback in parallel mode (no parent-side restore)\n- Epic EV-237 should eliminate direct-overwrite path entirely, making LOAD_PATH shadow the only path","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:17.689070042+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T15:53:00.183398494+07:00","closed_at":"2026-04-08T15:53:00.183398494+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-249","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
194
194
  {"id":"EV-25","title":"Structured error responses in JSON mode","description":"When --format json is used and exit code is 2 (error), output a JSON object with error details instead of unstructured stderr text. Schema: { \"error\": { \"type\": \"config_error|parse_error|runtime_error\", \"message\": \"...\", \"file\": \"...\" } }. Agents currently have to regex-parse stderr which is fragile.","status":"closed","priority":1,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-10T06:17:38.283715502+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-15T22:41:54.370789377+07:00","closed_at":"2026-03-15T22:41:54.370789377+07:00","close_reason":"Merged PR #74 — structured JSON error output in CLI"}
195
195
  {"id":"EV-250","title":"Classify mutant's extra mutations by operator category","description":"From the head-to-head data (EV-244), group mutant's extra mutations by category (e.g., receiver mutations, argument permutations, method name substitutions, literal boundary values). Count how many are signal vs noise per category. Produce a table of categories with signal/noise breakdown.","notes":"GitHub: #526","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:21.320269648+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:29:32.613448913+07:00","dependencies":[{"issue_id":"EV-250","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
196
196
  {"id":"EV-251","title":"Prioritize operator additions by signal-to-noise ratio","description":"Rank the missing operator categories by: (a) frequency of real signal catches, (b) implementation complexity, (c) expected equivalent mutant rate. Produce a prioritized implementation order for new operators.","notes":"GitHub: #534","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:38.370181376+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:29:53.283203728+07:00","dependencies":[{"issue_id":"EV-251","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
197
197
  {"id":"EV-252","title":"Reproduce and measure per-mutation RSS growth on reference fixture","description":"Create a reproducible benchmark: run evilution on a known fixture file, record RSS after each mutation. Confirm the ~3-8 MB/mutation growth rate. Baseline for measuring fix effectiveness.","notes":"GitHub: #539","status":"in_progress","priority":0,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:39.421709567+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T15:08:27.260195719+07:00","dependencies":[{"issue_id":"EV-252","depends_on_id":"EV-226","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
198
198
  {"id":"EV-253","title":"Profile object allocation delta per mutation cycle","description":"Use ObjectSpace.count_objects or memory_profiler to capture what new objects are allocated during one mutation cycle and not released. Identify the top retained object types.","notes":"GitHub: #540 — Profiling complete. Root cause: RSpec ExampleGroup subclass ivars create reference cycles preventing GC (+3380 slots/mutation). Secondary: World#@sources_by_path cache. Fix proven: clearing EG ivars + sources cache after Runner.run = 0 growth.","status":"closed","priority":0,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:41.259785614+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-05T15:50:12.517441649+07:00","closed_at":"2026-04-05T15:50:12.517441649+07:00","close_reason":"Profiling complete. Root cause identified: RSpec ExampleGroup reference cycles + World source cache. Findings documented on GH #540.","dependencies":[{"issue_id":"EV-253","depends_on_id":"EV-226","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
199
- {"id":"EV-254","title":"Design temp-file mutation architecture","description":"Design how the temp file is created, where it lives (tmpdir vs .evilution/tmp), how the test process is redirected to load it (Ruby $LOAD_PATH manipulation vs file-level bootsnap override vs ENV-based), and how Rails autoloader interacts with it.","notes":"GitHub: #536","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:42.91131604+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:29:55.18898649+07:00","dependencies":[{"issue_id":"EV-254","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
199
+ {"id":"EV-254","title":"Design temp-file mutation architecture","description":"Design how the temp file is created, where it lives (tmpdir vs .evilution/tmp), how the test process is redirected to load it (Ruby $LOAD_PATH manipulation vs file-level bootsnap override vs ENV-based), and how Rails autoloader interacts with it.","notes":"## Architecture Design: Temp-File Mutation\n\n### Problem Statement\nTwo write paths exist in Integration::RSpec#apply_mutation:\n- **Path A (LOAD_PATH shadow):** Works when file is under $LOAD_PATH — writes to temp dir, prepends to $LOAD_PATH. Original file never touched. Already safe.\n- **Path B (Direct overwrite):** Fallback when file is NOT under $LOAD_PATH — overwrites original, restores via ensure. Vulnerable to SIGKILL/OOM (especially in parallel mode where no parent-side defense-in-depth exists).\n\n**Goal:** Eliminate Path B entirely. Never modify the original source file.\n\n---\n\n### Design Decisions\n\n#### 1. Temp file location: Dir.mktmpdir (system tmpdir)\n- Use `Dir.mktmpdir('evilution')` (same as current Path A), NOT .evilution/tmp\n- Rationale: system tmpdir is auto-cleaned on reboot; no risk of polluting the project directory; avoids .gitignore concerns; already proven in current Path A\n\n#### 2. Redirection mechanism: LOAD_PATH shadow + explicit load\n**For files under $LOAD_PATH** (most lib/ files): Keep current approach — mirror subpath in temp dir, prepend to $LOAD_PATH. This handles any `require` calls during the test run.\n\n**For files NOT under $LOAD_PATH** (the current fallback case): \n- Write mutated source to temp dir mirroring the relative path from project root\n- Explicitly `load` the temp file in the forked child to redefine the class/module\n- This replaces the direct-overwrite approach entirely\n- The `load` approach works because it always executes the file (unlike `require` which checks $LOADED_FEATURES)\n\n#### 3. SourceSurgeon: No changes needed\nSourceSurgeon.apply is already pure in-memory byte surgery. It returns a mutated string without touching the filesystem. No changes required for this epic.\n\n#### 4. Where file I/O moves\n**Integration::RSpec#apply_mutation** remains the owner of temp-file writes, but the two-path logic changes:\n- Path A (under $LOAD_PATH): unchanged — temp dir + $LOAD_PATH prepend\n- Path B (not under $LOAD_PATH): temp dir + explicit `load` (replaces direct overwrite)\n- Both paths use temp files. Original is never touched.\n\n#### 5. Restore/cleanup strategy (three layers)\n1. **ensure in Integration::RSpec#call** (existing): Remove temp dir from $LOAD_PATH, purge $LOADED_FEATURES entries, FileUtils.rm_rf temp dir. Works for both paths now.\n2. **ensure in Isolation::Fork#call** (existing): Simplify — no longer needs to check/restore original file content. Instead, just verify temp dir cleanup. Keep as defense-in-depth for temp dir leaks.\n3. **at_exit hook** (new): Register a cleanup for the temp base dir pattern (evilution*) in case of unhandled exit. Safety net for leaked temp dirs.\n4. **Signal traps** (new): Trap SIGTERM/SIGINT in the parent process to ensure temp dir cleanup before exit.\n\n#### 6. Isolation::Fork#restore_original_source\n- Remove the file-content comparison and rewrite logic\n- Replace with temp-dir cleanup verification (check if any evilution temp dirs remain, clean them)\n- This is now truly defense-in-depth rather than a critical restore path\n\n#### 7. Parallel mode (InProcess isolation)\n- No special handling needed — each worker is a forked process with its own $LOAD_PATH\n- Temp dirs are per-mutation, isolated across workers\n- The biggest current risk (corrupted original file on worker SIGKILL) is eliminated because the original file is never modified\n\n#### 8. Zeitwerk (Rails autoloader) compatibility\n- Zeitwerk maps file paths to constant names using autoload_paths (which are $LOAD_PATH entries in Rails)\n- For files under Zeitwerk-managed paths: LOAD_PATH shadow works — Zeitwerk will find the temp version first\n- For files NOT under Zeitwerk paths: the explicit `load` approach bypasses Zeitwerk entirely, which is correct since Zeitwerk wouldn't manage those files anyway\n- Edge case: Zeitwerk caches file-to-constant mappings. In a forked child, the cache is inherited. Since we `load` after fork, the class is redefined in-place — Zeitwerk's cache remains valid (same constant, new definition)\n- Need integration test to verify (EV-268)\n\n---\n\n### Implementation Order\n1. **EV-263** (SourceSurgeon temp-file write): Modify apply_mutation to always use temp files. Add explicit `load` for non-LOAD_PATH files. Remove direct-overwrite fallback.\n2. **EV-265** (Load-path redirection): Refine the LOAD_PATH prepend logic. Handle edge cases (multiple LOAD_PATH matches, nested paths).\n3. **EV-267** (Cleanup): Add at_exit hook and signal traps. Simplify Isolation::Fork defense-in-depth.\n4. **EV-266** (Zeitwerk): Test and handle Zeitwerk edge cases.\n5. **EV-268** (Integration tests): Verify original file never modified, cleanup on normal/exceptional/signal exit, Zeitwerk compat.\n\n### Files to modify\n- `lib/evilution/integration/rspec.rb` — primary changes (apply_mutation, restore_original)\n- `lib/evilution/isolation/fork.rb` — simplify restore_original_source\n- `lib/evilution/isolation/in_process.rb` — no changes expected\n- `lib/evilution/ast/source_surgeon.rb` — no changes\n- `lib/evilution/runner.rb` — possibly add at_exit/signal trap registration","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:42.91131604+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T15:53:00.18355494+07:00","closed_at":"2026-04-08T15:53:00.18355494+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-254","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
200
200
  {"id":"EV-255","title":"Investigate worker process reuse vs fresh fork","description":"Determine if workers are reused across mutations (accumulating state) or fresh-forked each time. If reused, the parent process is accumulating objects passed to/from workers. If fresh-forked, the parent's memory shouldn't grow — investigate what the parent retains.","notes":"## Investigation Results\n\n**Workers are NOT reused across batches** (fresh fork each batch), but ARE reused within a batch (InProcess isolation, batch_size = jobs count).\n\n### Sequential (jobs=1)\n- Fresh fork per mutation via Isolation::Fork\n- Child exits after 1 mutation — no accumulation\n\n### Parallel (jobs>N) \n- N workers forked per batch (each_slice(config.jobs))\n- Workers loop processing multiple mutations via InProcess isolation\n- Workers killed and re-forked between batches\n- RSpec state accumulates within a worker for batch duration\n- EV-256 fix (clear_examples + release_rspec_state) mitigates in-batch accumulation\n\n### Parent-side accumulation\n- Expected O(N) growth: MutationResult + stripped Mutation per mutation for final report\n- Not a leak — required for report generation\n\n**Conclusion:** Architecture is sound. No unexpected reuse or leak path identified.","status":"closed","priority":0,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:44.352572561+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-05T22:33:41.490184078+07:00","closed_at":"2026-04-05T22:33:41.490184078+07:00","close_reason":"Investigation complete. Worker lifecycle is sound: fresh fork per batch, InProcess reuse within batch mitigated by EV-256 cleanup. No action needed.","dependencies":[{"issue_id":"EV-255","depends_on_id":"EV-226","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
201
201
  {"id":"EV-256","title":"Fix identified leak source(s)","description":"Based on profiling results, fix the leak. This could be: mutation results accumulating without GC, Prism parse trees retained, test output buffers, or reporter state growing.","status":"in_progress","priority":0,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:46.524854416+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-05T16:21:16.522830162+07:00","dependencies":[{"issue_id":"EV-256","depends_on_id":"EV-226","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
202
202
  {"id":"EV-257","title":"Add per-mutation RSS regression test","description":"Add a spec that runs N mutations and asserts RSS growth stays below a threshold (e.g., <1 MB/mutation average). Integrate with rake memory:check.","notes":"GitHub: #544","status":"closed","priority":0,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:48.696476684+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-05T23:22:49.927334624+07:00","closed_at":"2026-04-05T23:22:49.927334624+07:00","close_reason":"Merged PR #568. Added RSpec integration per-mutation check to rake memory:check.","dependencies":[{"issue_id":"EV-257","depends_on_id":"EV-226","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
203
- {"id":"EV-258","title":"Identify heredoc nodes in Prism AST","description":"Determine how Prism represents heredocs (interpolated_string_node with heredoc opening?). Document the AST structure for plain heredocs, interpolated heredocs, and squiggly heredocs.","notes":"GitHub: #545","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:50.91761442+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:30:40.004849276+07:00","dependencies":[{"issue_id":"EV-258","depends_on_id":"EV-241","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
204
- {"id":"EV-259","title":"Add heredoc detection to StringLiteral operator","description":"Modify the StringLiteral operator to detect when the target node is inside a heredoc. Add a heredoc? helper method.","notes":"GitHub: #546","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:52.767879347+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:30:40.244997087+07:00","dependencies":[{"issue_id":"EV-259","depends_on_id":"EV-241","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
203
+ {"id":"EV-258","title":"Identify heredoc nodes in Prism AST","description":"Determine how Prism represents heredocs (interpolated_string_node with heredoc opening?). Document the AST structure for plain heredocs, interpolated heredocs, and squiggly heredocs.","notes":"## Findings\n\nPrism represents heredocs using the same node types as regular strings, with a built-in `heredoc?` method for detection:\n\n### Node types\n- **Plain heredoc** (no interpolation): `Prism::StringNode` with `heredoc? = true`\n- **Interpolated heredoc**: `Prism::InterpolatedStringNode` with `heredoc? = true`\n- **Single-quoted heredoc** (`<<~'HEREDOC'`): `Prism::StringNode` with `heredoc? = true` (no interpolation possible)\n\n### Detection\n- `node.heredoc?` — built-in Prism method, works on both `StringNode` and `InterpolatedStringNode`\n- `node.opening` returns the heredoc sigil (e.g. `<<~HEREDOC`, `<<-HEREDOC`, `<<~'HEREDOC'`)\n- Can also check `node.opening&.start_with?(\"<<\")` but `heredoc?` is preferred\n\n### Heredoc variants (all return `heredoc? = true`)\n- `<<HEREDOC` — standard\n- `<<-HEREDOC` — allows indented closing delimiter\n- `<<~HEREDOC` — squiggly (strips leading whitespace)\n- `<<~'HEREDOC'` — single-quoted (no interpolation)\n\n### InterpolatedStringNode parts\nFor interpolated heredocs, `node.parts` contains:\n- `Prism::StringNode` — literal text segments (between interpolations)\n- `Prism::EmbeddedStatementsNode` — interpolated expressions (`#{...}`)\n\n### Key implication for EV-259\nNo custom AST traversal needed — just call `node.heredoc?` in the StringLiteral operator.","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:50.91761442+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T16:02:56.854568029+07:00","closed_at":"2026-04-08T16:02:56.854568029+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-258","depends_on_id":"EV-241","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
204
+ {"id":"EV-259","title":"Add heredoc detection to StringLiteral operator","description":"Modify the StringLiteral operator to detect when the target node is inside a heredoc. Add a heredoc? helper method.","notes":"GitHub: #546","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:52.767879347+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T18:09:45.856242189+07:00","closed_at":"2026-04-08T18:09:45.856242189+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-259","depends_on_id":"EV-241","type":"blocks","created_at":"0001-01-01T00:00:00Z"},{"issue_id":"EV-259","depends_on_id":"EV-258","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
205
205
  {"id":"EV-26","title":"Include test command in mutation result JSON","description":"Add a 'test_command' field to each mutation result in JSON output showing the exact command that was run to test that mutation. Helps agents debug when a mutation errors out or times out.","status":"closed","priority":3,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-10T06:17:39.227881462+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-16T10:11:01.311631114+07:00","closed_at":"2026-03-16T10:11:01.311631114+07:00","close_reason":"Already merged and released in v0.4.0"}
206
- {"id":"EV-260","title":"Implement interpolation-only mutation mode for heredocs","description":"When mutating a heredoc, only mutate the interpolated expressions (embedded_statements_node), not the literal text surrounding them. This preserves template structure while still testing dynamic content.","notes":"GitHub: #547","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:54.680419198+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:30:40.456648209+07:00","dependencies":[{"issue_id":"EV-260","depends_on_id":"EV-241","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
207
- {"id":"EV-261","title":"Add --skip-heredoc-literals CLI flag","description":"Add a flag to completely skip string literal mutations inside heredocs. For users who prefer zero heredoc mutations.","notes":"GitHub: #548","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:56.515382643+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:30:40.698475949+07:00","dependencies":[{"issue_id":"EV-261","depends_on_id":"EV-241","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
208
- {"id":"EV-262","title":"Add tests for heredoc mutation behavior","description":"Test: heredoc with no interpolation (skipped or mutated to empty), heredoc with interpolation (only expressions mutated), squiggly heredoc, nested heredoc.","notes":"GitHub: #549","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:56.333773283+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:30:40.923526567+07:00","dependencies":[{"issue_id":"EV-262","depends_on_id":"EV-241","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
209
- {"id":"EV-263","title":"Implement temp-file write in SourceSurgeon","description":"Modify SourceSurgeon.apply to write mutated source to a temp file instead of overwriting the original. Return the temp file path. Original file is never touched.","notes":"GitHub: #537","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:59.265360981+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:30:11.816752768+07:00","dependencies":[{"issue_id":"EV-263","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
206
+ {"id":"EV-260","title":"Implement interpolation-only mutation mode for heredocs","description":"When mutating a heredoc, only mutate the interpolated expressions (embedded_statements_node), not the literal text surrounding them. This preserves template structure while still testing dynamic content.","notes":"GitHub: #547","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:54.680419198+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T18:25:33.319924888+07:00","closed_at":"2026-04-08T18:25:33.319924888+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-260","depends_on_id":"EV-241","type":"blocks","created_at":"0001-01-01T00:00:00Z"},{"issue_id":"EV-260","depends_on_id":"EV-259","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
207
+ {"id":"EV-261","title":"Add --skip-heredoc-literals CLI flag","description":"Add a flag to completely skip string literal mutations inside heredocs. For users who prefer zero heredoc mutations.","notes":"GitHub: #548","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:56.515382643+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T19:20:01.937747302+07:00","closed_at":"2026-04-08T19:20:01.937747302+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-261","depends_on_id":"EV-241","type":"blocks","created_at":"0001-01-01T00:00:00Z"},{"issue_id":"EV-261","depends_on_id":"EV-260","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
208
+ {"id":"EV-262","title":"Add tests for heredoc mutation behavior","description":"Test: heredoc with no interpolation (skipped or mutated to empty), heredoc with interpolation (only expressions mutated), squiggly heredoc, nested heredoc.","notes":"GitHub: #549","status":"in_progress","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:56.333773283+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T19:20:02.042056553+07:00","dependencies":[{"issue_id":"EV-262","depends_on_id":"EV-241","type":"blocks","created_at":"0001-01-01T00:00:00Z"},{"issue_id":"EV-262","depends_on_id":"EV-261","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
209
+ {"id":"EV-263","title":"Implement temp-file write in SourceSurgeon","description":"Modify SourceSurgeon.apply to write mutated source to a temp file instead of overwriting the original. Return the temp file path. Original file is never touched.","notes":"GitHub: #537","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:29:59.265360981+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T15:53:00.183566714+07:00","closed_at":"2026-04-08T15:53:00.183566714+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-263","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
210
210
  {"id":"EV-264","title":"Define target metric and measurement methodology for mutation density gap","description":"Define what 'closing the gap' means: target ratio (e.g., <1.5x), measurement protocol (which files, which mutant config), and a benchmark script that can be re-run to track progress over time.","notes":"GitHub: #541","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:30:08.545241632+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:30:26.634822515+07:00","dependencies":[{"issue_id":"EV-264","depends_on_id":"EV-238","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
211
- {"id":"EV-265","title":"Implement load-path redirection for forked test process","description":"In the fork isolation, prepend the temp directory to $LOAD_PATH (or use a more targeted mechanism) so that require and load pick up the mutated file instead of the original.","notes":"GitHub: #550","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:30:17.522950262+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:30:34.39887441+07:00","dependencies":[{"issue_id":"EV-265","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
212
- {"id":"EV-266","title":"Handle Rails autoloader (Zeitwerk) compatibility","description":"Zeitwerk uses absolute paths. Test that the temp-file approach works with Zeitwerk's file-to-constant mapping. May need to use Zeitwerk's on_load callbacks or file override mechanism.","notes":"GitHub: #551","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:30:40.575881302+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:30:50.895546091+07:00","dependencies":[{"issue_id":"EV-266","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
213
- {"id":"EV-267","title":"Add cleanup of temp files after mutation run","description":"Ensure temp files are cleaned up on normal exit, exception, and signal (SIGTERM/SIGINT). Use at_exit hooks and signal traps.","notes":"GitHub: #552","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:30:57.733824316+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:31:05.665879929+07:00","dependencies":[{"issue_id":"EV-267","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
214
- {"id":"EV-268","title":"Add integration tests for temp-file mutation","description":"Test: original file never modified during run, mutated code is what the test process sees, cleanup on normal/exceptional exit, Rails autoloader compatibility.","notes":"GitHub: #554","status":"open","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:31:13.886751721+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T11:31:24.33988294+07:00","dependencies":[{"issue_id":"EV-268","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
211
+ {"id":"EV-265","title":"Implement load-path redirection for forked test process","description":"In the fork isolation, prepend the temp directory to $LOAD_PATH (or use a more targeted mechanism) so that require and load pick up the mutated file instead of the original.","notes":"GitHub: #550","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:30:17.522950262+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T15:53:00.18357647+07:00","closed_at":"2026-04-08T15:53:00.18357647+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-265","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
212
+ {"id":"EV-266","title":"Handle Rails autoloader (Zeitwerk) compatibility","description":"Zeitwerk uses absolute paths. Test that the temp-file approach works with Zeitwerk's file-to-constant mapping. May need to use Zeitwerk's on_load callbacks or file override mechanism.","notes":"GitHub: #551","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:30:40.575881302+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T15:53:00.183584148+07:00","closed_at":"2026-04-08T15:53:00.183584148+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-266","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
213
+ {"id":"EV-267","title":"Add cleanup of temp files after mutation run","description":"Ensure temp files are cleaned up on normal exit, exception, and signal (SIGTERM/SIGINT). Use at_exit hooks and signal traps.","notes":"GitHub: #552","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:30:57.733824316+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T15:53:00.18359655+07:00","closed_at":"2026-04-08T15:53:00.18359655+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-267","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
214
+ {"id":"EV-268","title":"Add integration tests for temp-file mutation","description":"Test: original file never modified during run, mutated code is what the test process sees, cleanup on normal/exceptional exit, Rails autoloader compatibility.","notes":"GitHub: #554","status":"closed","priority":2,"issue_type":"task","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T11:31:13.886751721+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-08T15:53:00.183603939+07:00","closed_at":"2026-04-08T15:53:00.183603939+07:00","close_reason":"Closed","dependencies":[{"issue_id":"EV-268","depends_on_id":"EV-237","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
215
215
  {"id":"EV-269","title":"Add 'evil' as alternative executable name","description":"Add exe/evil as an alternative entry point so users with alias be='bundle exec' can run 'be evil'. Need to consider: (1) thin wrapper vs symlink, (2) whether to document the alias suggestion, (3) Windows compatibility of symlinks. Fun quality-of-life feature, not urgent.","status":"open","priority":4,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T12:52:10.764169051+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-04T12:52:10.764169051+07:00"}
216
216
  {"id":"EV-27","title":"Epic: Workflow Integration","description":"Make evilution easier to invoke from AI agent toolchains — MCP server for direct tool calls, stdin mode for piping.","status":"closed","priority":2,"issue_type":"feature","owner":"denis.kiselyov@gmail.com","created_at":"2026-03-10T06:17:43.883767452+07:00","created_by":"Denis Kiselev","updated_at":"2026-03-16T22:59:12.241444308+07:00","closed_at":"2026-03-16T22:59:12.241444308+07:00","close_reason":"Both child issues done: MCP server (EV-28) and --stdin (EV-29)","dependencies":[{"issue_id":"EV-27","depends_on_id":"EV-28","type":"blocks","created_at":"0001-01-01T00:00:00Z"},{"issue_id":"EV-27","depends_on_id":"EV-29","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
217
217
  {"id":"EV-270","title":"Bug: Pipe buffer deadlock in Fork isolation when Marshal payload exceeds 64KB","description":"In Isolation::Fork#wait_for_result, the parent calls read_io.read (blocking until EOF) while the child calls Marshal.dump(result, write_io). If the serialized result exceeds the ~64KB Linux pipe buffer, the child blocks on write waiting for the parent to drain, while the parent blocks on read waiting for the child to close the pipe. Classic pipe deadlock. This is the most likely cause of occasional evilution hangs. Fix: read in a loop with IO.select, or use a tempfile for large payloads, or use non-blocking IO.","notes":"GitHub: #557","status":"closed","priority":1,"issue_type":"bug","owner":"denis.kiselyov@gmail.com","created_at":"2026-04-04T23:39:33.862423078+07:00","created_by":"Denis Kiselev","updated_at":"2026-04-05T11:36:22.036913254+07:00","closed_at":"2026-04-05T11:36:22.036913254+07:00","close_reason":"False positive: Ruby IO#read drains pipe incrementally, no deadlock occurs. Real bug (double Process.wait) filed as EV-273 / GH #561.","dependencies":[{"issue_id":"EV-270","depends_on_id":"EV-226","type":"blocks","created_at":"0001-01-01T00:00:00Z"}]}
data/CHANGELOG.md CHANGED
@@ -1,5 +1,41 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.21.0] - 2026-04-08
4
+
5
+ ### Added
6
+
7
+ - **Heredoc-aware string mutations** — `string_literal` operator now skips literal text in heredocs (all variants: `<<HEREDOC`, `<<-HEREDOC`, `<<~HEREDOC`, `<<~'HEREDOC'`); still mutates string literals inside interpolated expressions (`#{"literal"}`); uses Prism's built-in `heredoc?` detection (#522, #545, #546, #547)
8
+ - **`--skip-heredoc-literals` CLI flag** — completely suppresses all string literal mutations inside heredocs, including strings within interpolated expressions; configurable via CLI flag and `.evilution.yml` (#548)
9
+ - **Temp-file mutation approach** — mutations are applied to temporary file copies instead of overwriting original source files; uses load-path redirection (`$LOAD_PATH.unshift`) so `require` resolves the mutated copy; original files are never modified during mutation runs (#537)
10
+ - **Zeitwerk-compatible load-path redirection** — forked test processes redirect the load path to pick up mutated temp files, compatible with Zeitwerk-like autoloaders (#550, #551)
11
+ - **Temp directory cleanup and tracking** — `TempDirTracker` ensures mutation temp directories are cleaned up after each run, preventing temp file accumulation (#552)
12
+ - **Integration tests for temp-file mutation** — end-to-end tests verifying original file protection, temp file cleanup, and sandbox isolation during forked mutation runs (#554)
13
+ - **Integration tests for heredoc mutation behavior** — full-pipeline tests covering plain, squiggly, non-squiggly, dash, single-quote, interpolated, nested, and mixed heredocs (#549)
14
+
15
+ ### Changed
16
+
17
+ - **Mutation isolation** — mutation runs no longer modify original source files on disk; all mutations are applied to temporary copies, improving safety for concurrent usage and editor integration
18
+ - **Operator options threading** — `Registry#mutations_for` accepts `operator_options` hash, passed through to operator constructors; enables per-operator configuration like `skip_heredoc_literals`
19
+ - **Dependencies** — bumped `mcp` gem to 0.11.0; bumped `ruby/setup-ruby` CI action to 1.300.0
20
+
21
+ ## [0.20.0] - 2026-04-08
22
+
23
+ ### Added
24
+
25
+ - **New mutation operators (10)** — `loop_flip` swaps `while`↔`until` loops (#581); `string_interpolation` replaces `#{expr}` content with `nil` (#582); `retry_removal` removes `retry` statements from rescue blocks (#583); `case_when` removes `when` branches, replaces bodies with `nil`, removes `else` (#584); `predicate_replacement` replaces predicate method calls (`foo?`) with `true`/`false` (#585); `equality_to_identity` converts `a == b` to `a.equal?(b)` (#586); `lambda_body` replaces lambda/proc bodies with `nil` (#588); `begin_unwrap` removes bare `begin..end` wrappers (#589); `block_param_removal` removes `&block` parameters from method definitions (#590)
26
+ - **Method body replacement expansion** — `method_body_replacement` now generates `self` and `super` replacements alongside `nil` (#587)
27
+ - **SendMutation expansions** — added `downcase`↔`upcase` (#594), `strip`→`lstrip`/`rstrip`, `lstrip`→`strip`, `rstrip`→`strip`, `chomp`↔`chop` (#595) method swap pairs
28
+ - **Coverage gap detection and reporting** — survived mutations are grouped by `(file, subject, line)` into coverage gaps; reported in CLI (`N coverage gaps` header with grouped entries), JSON (`coverage_gaps` key), HTML (grouped gap entries with operator tags), and session data (#592)
29
+ - **VoidContext equivalent heuristic** — detects equivalent mutations where collection methods are swapped in void context (e.g. `each`↔`map`, `each`↔`reverse_each` when return value is unused); uses Prism AST parent-node walking (#593)
30
+ - **AliasSwap heuristic expansion** — added `count`↔`size` and `detect`↔`find` alias pairs for equivalent detection (#591)
31
+ - **Related spec heuristic** — automatically detects mutations involving `.includes()` and finds related request/integration/feature/system specs by domain name, improving test targeting for association mutations (#596)
32
+ - **Crash detection in RSpec integration** — `CrashDetector` formatter distinguishes assertion failures from runtime crashes (e.g. `NoMethodError`, `SystemStackError`); when all test failures are crashes (no assertion failures), the result includes a crash summary in the error field; reuses a single detector instance across mutation runs to avoid formatter accumulation (#597)
33
+
34
+ ### Changed
35
+
36
+ - **Operator count** — 69 operators (up from 60), with new loop, string, case/when, predicate, identity, lambda, begin/end, and block parameter operators
37
+ - **Equivalent heuristic count** — 7 heuristics (up from 5), with new void context detection and expanded alias pairs
38
+
3
39
  ## [0.19.0] - 2026-04-07
4
40
 
5
41
  ### Added
data/README.md CHANGED
@@ -63,6 +63,7 @@ evilution [command] [options] [files...]
63
63
  | `--incremental` | Boolean | false | Cache killed/timeout results; skip unchanged mutations on re-runs. |
64
64
  | `--save-session` | Boolean | false | Persist results as timestamped JSON under `.evilution/results/`. |
65
65
  | `--no-progress` | Boolean | _(enabled)_ | Disable the TTY progress bar. |
66
+ | `--skip-heredoc-literals` | Boolean | false | Skip all string literal mutations inside heredocs. |
66
67
  | `--show-disabled` | Boolean | false | Report mutations skipped by `# evilution:disable` comments. |
67
68
  | `--baseline-session PATH` | String | _(none)_ | Saved session file for HTML report comparison. |
68
69
  | `-e CODE`, `--eval CODE` | String | _(none)_ | Inline Ruby code for `util mutation` command. |
@@ -88,6 +89,7 @@ Creates `.evilution.yml`:
88
89
  # integration: rspec # test framework
89
90
  # suggest_tests: false # concrete RSpec test code in suggestions
90
91
  # save_session: false # persist results under .evilution/results/
92
+ # skip_heredoc_literals: false # skip all string literal mutations inside heredocs
91
93
  # show_disabled: false # report mutations skipped by disable comments
92
94
  # baseline_session: null # path to session file for HTML comparison
93
95
  # ignore_patterns: [] # AST patterns to exclude (see docs/ast_pattern_syntax.md)
@@ -148,6 +150,16 @@ Use `--format json` for machine-readable output. Schema:
148
150
  "suggestion": "string — actionable hint for surviving mutants (survived only)"
149
151
  }
150
152
  ],
153
+ "coverage_gaps": [
154
+ {
155
+ "file": "string — relative path to source file",
156
+ "subject": "string — method name (e.g. 'Foo#bar')",
157
+ "line": "integer — line number",
158
+ "operators": ["string — operator names involved"],
159
+ "count": "integer — number of survived mutations in this gap",
160
+ "mutations": ["... same shape as survived entries ..."]
161
+ }
162
+ ],
151
163
  "killed": ["... same shape as survived entries ..."],
152
164
  "timed_out": ["... same shape as survived entries ..."],
153
165
  "errors": ["... same shape as survived entries ..."]
@@ -156,7 +168,7 @@ Use `--format json` for machine-readable output. Schema:
156
168
 
157
169
  **Key metric**: `summary.score` — the mutation score. Higher is better. 1.0 means all mutations were caught.
158
170
 
159
- ## Mutation Operators (60 total)
171
+ ## Mutation Operators (69 total)
160
172
 
161
173
  Each operator name is stable and appears in JSON output under `survived[].operator`.
162
174
 
@@ -177,7 +189,7 @@ Each operator name is stable and appears in JSON output under `survived[].operat
177
189
  | `conditional_branch` | Remove if/else branch | Deletes branch body |
178
190
  | `conditional_flip` | Flip `if` to `unless` and vice versa | `if cond` -> `unless cond` |
179
191
  | `statement_deletion` | Remove statements from method bodies | Deletes a statement |
180
- | `method_body_replacement` | Replace entire method body with `nil` | Method body -> `nil` |
192
+ | `method_body_replacement` | Replace entire method body | Method body -> `nil`, `self`, `super` |
181
193
  | `negation_insertion` | Negate predicate methods | `x.empty?` -> `!x.empty?` |
182
194
  | `return_value_removal` | Strip return values | `return x` -> `return` |
183
195
  | `collection_replacement` | Swap collection methods | `map` -> `each`, `select` <-> `reject` |
@@ -222,6 +234,15 @@ Each operator name is stable and appears in JSON output under `survived[].operat
222
234
  | `splat_operator` | Remove splat/double-splat | `foo(*args)` -> `foo(args)` |
223
235
  | `defined_check` | Replace `defined?` with `true` | `defined?(x)` -> `true` |
224
236
  | `regex_capture` | Swap or nil-ify capture refs | `$1` -> `$2`, `$1` -> `nil` |
237
+ | `loop_flip` | Swap while/until loops | `while cond` -> `until cond` |
238
+ | `string_interpolation` | Replace interpolation content with nil | `"hello #{name}"` -> `"hello #{nil}"` |
239
+ | `retry_removal` | Remove retry statements | `retry` -> `nil` |
240
+ | `case_when` | Remove/replace case/when branches | Remove `when` branch, body -> `nil`, remove `else` |
241
+ | `predicate_replacement` | Replace predicate calls with booleans | `x.empty?` -> `true`, `x.empty?` -> `false` |
242
+ | `equality_to_identity` | Replace equality with identity check | `a == b` -> `a.equal?(b)` |
243
+ | `lambda_body` | Replace lambda body with nil | `-> { expr }` -> `-> { nil }` |
244
+ | `begin_unwrap` | Remove begin/end wrapper | `begin; expr; end` -> `expr` |
245
+ | `block_param_removal` | Remove explicit block parameter | `def foo(&block)` -> `def foo` |
225
246
 
226
247
  ## MCP Server (AI Agent Integration)
227
248
 
@@ -368,8 +389,8 @@ Tests 4 paths (InProcess isolation, Fork isolation, mutation generation + stripp
368
389
  1. **Parse** — Prism parses Ruby files into ASTs with exact byte offsets
369
390
  2. **Extract** — Methods are identified as mutation subjects
370
391
  3. **Filter** — Disable comments, Sorbet `sig` blocks, and AST ignore patterns exclude mutations before execution
371
- 4. **Mutate** — 60 operators produce text replacements at precise byte offsets (source-level surgery, no AST unparsing)
372
- 5. **Isolate** — Default isolation is in-process; `--isolation fork` uses forked child processes. Parallel mode (`--jobs N`) always uses in-process isolation inside pool workers to avoid double forking
392
+ 4. **Mutate** — 69 operators produce text replacements at precise byte offsets (source-level surgery, no AST unparsing); heredoc literal text is skipped by default
393
+ 5. **Isolate** — Mutations are applied to temporary file copies (never modifying originals); load-path redirection ensures `require` resolves the mutated copy. Default isolation is in-process; `--isolation fork` uses forked child processes. Parallel mode (`--jobs N`) always uses in-process isolation inside pool workers to avoid double forking
373
394
  6. **Test** — RSpec executes against the mutated source
374
395
  7. **Collect** — Source strings and AST nodes are released after use to minimize memory retention
375
396
  8. **Report** — Results aggregated into text, JSON, or HTML, including efficiency metrics and peak memory usage
data/lib/evilution/cli.rb CHANGED
@@ -255,6 +255,7 @@ class Evilution::CLI
255
255
  end
256
256
 
257
257
  def add_extra_flag_options(opts)
258
+ opts.on("--skip-heredoc-literals", "Skip all string literal mutations inside heredocs") { @options[:skip_heredoc_literals] = true }
258
259
  opts.on("--show-disabled", "Report mutations skipped by # evilution:disable") { @options[:show_disabled] = true }
259
260
  opts.on("--baseline-session PATH", "Compare against a baseline session in HTML report") { |p| @options[:baseline_session] = p }
260
261
  opts.on("--save-session", "Save session results to .evilution/results/") { @options[:save_session] = true }
@@ -298,10 +299,11 @@ class Evilution::CLI
298
299
 
299
300
  registry = Evilution::Mutator::Registry.default
300
301
  filter = build_subject_filter(config)
302
+ operator_options = build_operator_options(config)
301
303
  total_mutations = 0
302
304
 
303
305
  subjects.each do |subj|
304
- count = registry.mutations_for(subj, filter: filter).length
306
+ count = registry.mutations_for(subj, filter: filter, operator_options: operator_options).length
305
307
  total_mutations += count
306
308
  label = count == 1 ? "1 mutation" : "#{count} mutations"
307
309
  $stdout.puts(" #{subj.name} #{subj.file_path}:#{subj.line_number} (#{label})")
@@ -317,6 +319,10 @@ class Evilution::CLI
317
319
  2
318
320
  end
319
321
 
322
+ def build_operator_options(config)
323
+ { skip_heredoc_literals: config.skip_heredoc_literals? }
324
+ end
325
+
320
326
  def build_subject_filter(config)
321
327
  return nil if config.ignore_patterns.empty?
322
328
 
@@ -425,6 +431,7 @@ class Evilution::CLI
425
431
  " suggest_tests: #{config.suggest_tests}",
426
432
  " save_session: #{config.save_session}",
427
433
  " target: #{config.target || "(all files)"}",
434
+ " skip_heredoc_literals: #{config.skip_heredoc_literals}",
428
435
  " ignore_patterns: #{config.ignore_patterns.empty? ? "(none)" : config.ignore_patterns.inspect}"
429
436
  ]
430
437
  end
@@ -481,8 +488,10 @@ class Evilution::CLI
481
488
  def run_util_mutation
482
489
  source, file_path = resolve_util_mutation_source
483
490
  subjects = parse_source_to_subjects(source, file_path)
491
+ config = Evilution::Config.new(**@options)
484
492
  registry = Evilution::Mutator::Registry.default
485
- mutations = subjects.flat_map { |s| registry.mutations_for(s) }
493
+ operator_options = build_operator_options(config)
494
+ mutations = subjects.flat_map { |s| registry.mutations_for(s, operator_options: operator_options) }
486
495
 
487
496
  if mutations.empty?
488
497
  $stdout.puts("No mutations generated")