{"record":{"id":"0bfc0206329ec9a0","repo":"Hmbown/CodeWhale","slug":"unsupported-rrule-freq-other-supported-once","errorCode":null,"errorMessage":"Unsupported RRULE FREQ '{other}'. Supported: ONCE, HOURLY, WEEKLY, and CRON","messagePattern":"Unsupported RRULE FREQ '(.+?)'\\. Supported: ONCE, HOURLY, WEEKLY, and CRON","errorType":"validation","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/tui/src/automation_manager.rs","lineNumber":363,"sourceCode":"                continue;\n            }\n            let Some((k, v)) = item.split_once('=') else {\n                bail!(\"Invalid RRULE segment '{item}'\");\n            };\n            parts.insert(k.trim().to_ascii_uppercase(), v.trim().to_string());\n        }\n\n        let freq = match parts\n            .get(\"FREQ\")\n            .map(|value| value.trim().to_ascii_uppercase())\n            .as_deref()\n        {\n            Some(\"ONCE\") => return parse_once_schedule(&parts),\n            Some(\"HOURLY\") => AutomationFrequency::Hourly,\n            Some(\"WEEKLY\") => AutomationFrequency::Weekly,\n            Some(\"CRON\") => return parse_cron_schedule(&parts),\n            Some(other) => {\n                bail!(\"Unsupported RRULE FREQ '{other}'. Supported: ONCE, HOURLY, WEEKLY, and CRON\")\n            }\n            None => bail!(\"RRULE must include FREQ\"),\n        };\n\n        match freq {\n            AutomationFrequency::Hourly => {\n                for key in parts.keys() {\n                    if key != \"FREQ\"\n                        && key != \"INTERVAL\"\n                        && key != \"BYDAY\"\n                        && key != \"BYHOUR\"\n                        && key != \"BYMINUTE\"\n                    {\n                        bail!(\n                            \"Unsupported RRULE field '{key}' for HOURLY. Allowed: FREQ,INTERVAL,BYDAY,BYHOUR,BYMINUTE\"\n                        );\n                    }\n                }","sourceCodeStart":345,"sourceCodeEnd":381,"githubUrl":"https://github.com/Hmbown/CodeWhale/blob/73e0f67d83c59909b571efdfc88c4bc28c309cb1/crates/tui/src/automation_manager.rs#L345-L381","documentation":"The RRULE schedule parser in automation_manager only accepts FREQ values ONCE, HOURLY, WEEKLY, and CRON. Any other FREQ token (e.g. DAILY, MONTHLY, YEARLY, or a misspelled value) hits the catch-all arm and aborts parsing. Standard RFC-5545 frequencies beyond the supported subset are intentionally rejected.","triggerScenarios":"Parsing an automation RRULE string whose FREQ= is anything other than ONCE/HOURLY/WEEKLY/CRON, e.g. 'RRULE:FREQ=DAILY;BYHOUR=9' or a typo like 'FREQ=Hourly' (case-sensitive match).","commonSituations":"Users copy a standard calendar RRULE (DAILY/MONTHLY) from another tool; hand-written schedules with wrong casing; migrating automations from a cron/iCal system that supports more frequencies than this scheduler.","solutions":["Change FREQ to one of ONCE, HOURLY, WEEKLY, or CRON in the RRULE string","Use FREQ=CRON with a cron expression if you need daily/monthly-style scheduling","Check casing: FREQ values are matched in exact uppercase"],"exampleFix":"// before\nRRULE:FREQ=DAILY;BYHOUR=9\n// after\nRRULE:FREQ=CRON;BYHOUR=9  (or restructure as HOURLY/WEEKLY per supported grammar)","handlingStrategy":"validation","validationCode":"const SUPPORTED_FREQ = [\"ONCE\", \"HOURLY\", \"WEEKLY\", \"CRON\"];\nconst freq = rule.match(/FREQ=([A-Z]+)/)?.[1];\nif (!freq || !SUPPORTED_FREQ.includes(freq)) throw new Error(`FREQ must be one of ${SUPPORTED_FREQ.join(\", \")}`);","typeGuard":"function isSupportedFreq(v: string): v is \"ONCE\"|\"HOURLY\"|\"WEEKLY\"|\"CRON\" {\n  return [\"ONCE\",\"HOURLY\",\"WEEKLY\",\"CRON\"].includes(v);\n}","tryCatchPattern":"try {\n  schedule = parse_rrule(rule)?;\n} catch e if e.to_string().contains(\"Unsupported RRULE FREQ\") {\n  eprintln!(\"{e}; rewrite the rule with a supported FREQ\");\n}","preventionTips":["Keep a dropdown/enum in the UI instead of free-text FREQ","Validate RRULE strings at save time, not only at load time","Uppercase-normalize user input before parsing"],"tags":["rrule","scheduling","validation","config"],"backgroundTag":"unsupported-enum-value","analyzedSha":"73e0f67d83c59909b571efdfc88c4bc28c309cb1","analyzedAt":"2026-09-22T01:30:00.501Z","contentChangedAt":"2026-09-22T01:30:00.501Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}