UNIT-003-B08-fix-01 - Sign off tanpa kode ditahan, bukan error

Type BE
Size S
Tier 2
Origin UNIT-003-B08 (already merged)
Found in another bolt
Finding type In-scope bug
Depends on -
Acceptance AC-BON-034
Status Done

Summary

Problem

Vessel Plan bisa menyimpan alasan sign off berupa teks dengan off_reason_type kosong. Di remora 23eb1925e, MatchException memanggil NormalizeOffReason("") bila bonus punya exception. Panggilan itu mengembalikan error unknown offboard reason "", lalu DecideRelease meneruskannya. Reproduksi: DecideRelease dengan Automate, Accrued, periode sign off, OffReason{Code: "", Text: "Jumpship"} dan satu exception IS [FINISHED] handle MANUAL. Hasilnya error, sehingga kalkulasi B09 akan gagal.

Correct behavior

Bila kode offboard kosong dan bonus punya minimal satu exception, DecideRelease mengembalikan Hold dengan HELD_BY_EXCEPTION dan handle MANUAL, untuk IS maupun IS_NOT, sesuai contract B1 bagian Sign off tanpa kode. Kode tidak ditebak dari Text. Exception dengan trigger, condition, handle atau option tidak dikenal tetap mengembalikan error seperti sekarang. Kode kosong tanpa exception tetap dirilis (baris 5). Kode yang tidak kosong tetapi tidak dikenal tetap error.

New test

How to verify

Scope

Log

Date Event Reason Ref