Repository navigation
feat: address requested issues - closes #703, closes #704, closes #708, closes #709 - #774
Conversation
…ft#704, closes Tollcraft#708, closes Tollcraft#709 Draft implementation for four cargo-budget-report issues. This commit has NOT been built, tested, linted or formatted. - Tollcraft#703 validate.rs: reuse a single Levenshtein DP row instead of the full (n+1)x(m+1) matrix and drop the two Vec<char> copies per call, prune candidates whose length difference already exceeds the typo threshold before running the DP, replace the per-name linear scan of available functions with an O(1) set lookup, build the available-functions hint lazily on the first missing name, and deserialize budget.toml once instead of twice per call. Adds 10 edge-case tests. - Tollcraft#704 contract_exports.rs: 12 new unit tests covering runtime-symbol classification, filtering of runtime and memory exports, stable export ordering, a module with no export section, invalid wasm, diagnostic wording and ExportScan value semantics. - Tollcraft#708 fixture.rs: 21 new unit tests covering save/load round trips for every JSON shape, overwrite, idempotent reload, unknown top-level fields, unicode keys and values, and every read/parse/version-mismatch/write error path. - Tollcraft#709 json_output.rs: module, type and function documentation for the JSON envelope, a worked example document, inline rationale for the borrowed snapshots and the unreachable expect, and 5 new tests pinning the envelope shape.
|
@aetheron06 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
|
MergeKeeper review Scope: in scope for linked issue The PR successfully addresses all four linked issues (#703, #704, #708, and #709) by optimizing validation performance in validate.rs, adding comprehensive test suites for contract_exports.rs and fixture.rs, and improving documentation and test coverage for json_output.rs. All changes are clean, strictly scoped, and well-tested. Reviewed commit: |
|
MergeKeeper merge status Status: blocked Reason: One or more required CI checks failed. Failing checks:
Next steps:
|
|
MergeKeeper review unavailable AI provider failed: gemini-3.5-flash-lite (200) No approval or merge action was taken. |
Formatting only, to satisfy the repo's `cargo fmt --all -- --check` lint gate. No behaviour changed.
There was a problem hiding this comment.
Approved
The PR successfully addresses all four linked issues (#703, #704, #708, and #709) by optimizing validation performance in validate.rs, adding comprehensive test suites for contract_exports.rs and fixture.rs, and improving documentation and test coverage for json_output.rs. All changes are clean, strictly scoped, and well-tested.
|
Merged Merged with |
closes #703, closes #704, closes #708, closes #709
Draft implementation for four cargo-budget-report issues. This commit has NOT been built, tested, linted or formatted.
Review and optimize performance/allocations in
cargo-budget-report/src/validate.rs#703 validate.rs: reuse a single Levenshtein DP row instead of the full (n+1)x(m+1) matrix and drop the two Vec copies per call, prune candidates whose length difference already exceeds the typo threshold before running the DP, replace the per-name linear scan of available functions with an O(1) set lookup, build the available-functions hint lazily on the first missing name, and deserialize budget.toml once instead of twice per call. Adds 10 edge-case tests.Add comprehensive unit tests for
cargo-budget-report/src/contract_exports.rs#704 contract_exports.rs: 12 new unit tests covering runtime-symbol classification, filtering of runtime and memory exports, stable export ordering, a module with no export section, invalid wasm, diagnostic wording and ExportScan value semantics.Add comprehensive unit tests for
cargo-budget-report/src/fixture.rs#708 fixture.rs: 21 new unit tests covering save/load round trips for every JSON shape, overwrite, idempotent reload, unknown top-level fields, unicode keys and values, and every read/parse/version-mismatch/write error path.Improve inline documentation and comments in
cargo-budget-report/src/json_output.rs#709 json_output.rs: module, type and function documentation for the JSON envelope, a worked example document, inline rationale for the borrowed snapshots and the unreachable expect, and 5 new tests pinning the envelope shape.