{"name":"progress","helper":"rui_progress","complexity":"simple","param_count":8,"slot_count":0,"form_builder":false,"standalone":true,"ai_score":9,"human_score":9,"token_estimate":56,"slots":{},"gotchas":[{"id":"progress_value_silently_coerces_invalid_input","severity":"low","component":"rui_progress","summary":"value: silently coerces nil/non-numeric input to 0% via #to_i — no error, so an upstream calculation bug renders as an empty bar instead of failing loudly","params":["value"],"behavior":"clamp_value calls val.to_i.clamp(0, 100). Ruby's #to_i on nil returns 0, and on a non-numeric String (e.g. \"N/A\", \"\", a broken interpolation) also returns 0 with no exception. A value: that should have been a real percentage but came from a nil association or a failed calculation renders as a plain empty 0% bar — visually indistinguishable from a legitimately-zero metric.","wrong":"\u003c%= rui_progress(@deal.completion_percentage) %\u003e  \u003c%# renders 0% silently if @deal.completion_percentage is nil due to a missing association %\u003e","right":"\u003c%= rui_progress(@deal.completion_percentage || raise(\"completion_percentage missing for deal #{@deal.id}\")) %\u003e  \u003c%# fail loudly in dev/staging instead of shipping a silently-wrong 0% bar %\u003e","notes":"Values \u003e 100 or \u003c 0 are also clamped silently (150 -\u003e 100, -10 -\u003e 0) per progress/USAGE.md's documented \"Value Clamping\" behavior — same silent-mask-a-bug risk applies to out-of-range values from a bad calculation, not just nil.","detection":"Scan for rui_progress(value) / rui_stat(..., progress: value) calls where value comes directly from a nullable association or an unguarded arithmetic expression with no presence check.","recovery":"Add an explicit presence/range check (or a development-mode warning) upstream of the component call when the value is expected to always be a real 0-100 number — don't rely on rui_progress to surface the bug for you."}],"families":[{"tree":"progress_display","question":"What kind of progress/metric display?","use_case":"Simple progress bar","notes":"Standalone progress bar. Supports label, show_value, animated, 5 sizes, 2 variants."}],"compositions":[],"relationships":{}}