lift_actions: kausal (Depends) + ActionDef.raises — AT-CARRY-2 autarke Arme A+C#168
Merged
Conversation
Function::raises already exists in ruff_spo_triplet (core-7) but had no ActionDef slot to land in. Add `pub raises: Vec<String>` right after the existing `calls` effect annotation, mirroring its shape exactly - additive, Default-derived, no existing `ActionDef::new(...)`/`..Default:: default()` construction site needs to change. Also add the exhaustive-match governance test for KausalSpec (`kausal_spec_match_is_exhaustive`) required by SPEC-ATC2-OGAR §7: a wildcard-free match over all five current variants that will fail to compile the moment Arm B (Constrains/Onchange) lands without updating this match - the COUNT_FUSE-style loud break the doctrine asks for instead of leaning on #[non_exhaustive] alone.
… + C) Arm A: build a compute-method -> @api.depends-paths index from Model::fields (Field::emitted_by / Field::depends_on - both already flow through ruff, no ruff change needed) and populate ActionDef::kausal = Some(KausalSpec::depends(paths)) for exactly the methods that are a field's compute target. Provenance-honest: `reads` never fabricates a `kausal` trigger, only the real @api.depends fact does; a method with no matching Field::emitted_by keeps kausal == None (pins lift_actions_plain_read_still_no_kausal). Arm C: a.raises = f.raises.clone() - straight verbatim carry now that ActionDef has the slot. Updates the two stale doc comments that said kausal/raises had no path onto ActionDef. New tests: lift_actions_depends_field_yields_kausal_ depends, lift_actions_plain_read_still_no_kausal, lift_actions_raises_carried_on_actiondef. Existing lift_actions_is_facts_ only / lift_actions_carries_read_write_call_effect_facts stay green unchanged (their fixtures declare no compute fields). Arms B (Constrains/Onchange) and D (ComputedField.stored) are out of scope - they need ruff_spo_triplet::Function::constrains/onchange and Field::stored, which do not exist yet on ruff main (confirmed by reading ruff_spo_triplet's Function/Field structs in the resolved git dependency checkout).
…key round-trip test, D-ATC2-KAUSAL-AUTARK - ActionDef.raises now carries #[cfg_attr(feature = "serde", serde(default))] per the vocab's own additive-field convention; pre-raises JSON deserializes (new feature-gated test, serde_json dev-dep added). - DISCOVERY-MAP: D-ATC2-KAUSAL-AUTARK appended (arms A+C autark, B+D gated on ruff #49, last-wins index assumption named).
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_b367ff53-0271-44ca-80c5-1b84ab356528) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Was
Die OGAR-autarke Hälfte von AT-CARRY-2 (KausalSpec-Population), aus der odoo-rs-Triangulation destilliert und gegen Primärquellen verifiziert. Wichtigste Korrektur gegenüber der relayed Studie: der depends-Arm hat keine ruff-Voraussetzung — die Daten fließen längst über
Field::emitted_by→Field::depends_on.lift_actionspopuliertkausal = KausalSpec::Dependsaus einememitted_by→depends_on-Index übermodel.fields— dem ogar-from-schema-Präzedenz (do_arm.rs::kausal_from_entity) folgend, copy not design. Provenance-ehrlich: nie ausreadsfabriziert; die Regressionlift_actions_plain_read_still_no_kausalbeweist, dass ein Read eines computed Fields dem Leser kein kausal unterschiebt (Fixture liestamount_total, das von einer ANDEREN Methode emitted wird).ActionDef.raises-Slot (Function::raises, Authoritative,exc:-Namespace),serde(default)nach vocab-Konvention inkl. Missing-Key-Round-trip-Test.kausal_spec_match_is_exhaustive— wildcard-freier intra-crate Match, der zur COMPILE-Zeit bricht, sobald Arm B Varianten ergänzt. COUNT_FUSE-Encoding, kein Pin (D-NEVER-PIN-BUMP).depends_on).Was NICHT
Arme B (constrains/onchange→neue KausalSpec-Varianten) + D (
computed.stored) — die brauchen ruff #49 auf ruff main und folgen als eigener PR danach (float-on-main, der laute Break bis dahin ist Doktrin).Tests
109 ogar-vocab (inkl. serde-Feature) + 71 ogar-from-ruff + 3 woa_parity_probe, 0 failed; Clippy
--all-features -D warningsclean. Opus-Review: MERGE-READY, 2×P2 — beide adressiert (serde(default)+ Round-trip-Test; Index-Annahme im Ledger benannt). Reviewer hat zusätzlich alle 9 Downstream-ActionDef-Consumer gegen den additiven Slot kompiliert: clean.🤖 Generated with Claude Code
https://claude.ai/code/session_01Cg8DSUz1U4AvKqXiy9Xx2f