{"record":{"id":"b1074a27b12e2262","repo":"dbt-labs/dbt-core","slug":"issue-13604-selector-yaml-should-parse","errorCode":null,"errorMessage":"issue #13604 selector YAML should parse","messagePattern":"issue #13604 selector YAML should parse","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/dbt-parser/src/resolve/resolve_selectors.rs","lineNumber":896,"sourceCode":"        Ok(())\n    }\n\n    /// Regression (dbt-labs/fs#13604): dbt Core types a method argument's\n    /// `value` as `Any`, so a sequence like `value: [\"models\"]` loads fine\n    /// even for an unused selector. A one-element sequence is no exception:\n    /// `Path.glob()` still gets a `list`, so it must defer, not resolve.\n    #[test]\n    fn test_sequence_valued_selector_argument_parses() -> FsResult<()> {\n        let selector_file: SelectorFile = dbt_yaml::from_str(\n            r#\"\nselectors:\n  - name: default\n    definition:\n      method: path\n      value: [\"models\"]\n\"#,\n        )\n        .expect(\"issue #13604 selector YAML should parse\");\n\n        let original_definition = selector_file.selectors[0].definition.clone();\n        let normalized_include =\n            SelectorParser::new(BTreeMap::new()).parse_definition(&original_definition)?;\n        if let SelectExpression::Atom(criteria) = &normalized_include {\n            assert_eq!(criteria.method, MethodName::Path);\n            assert!(\n                matches!(\n                    criteria.value,\n                    dbt_common::node_selector::SelectionValue::Unsupported(_)\n                ),\n                \"a sequence value has no selection semantics and must be deferred, not treated as a scalar\"\n            );\n        } else {\n            panic!(\"Expected a single deferred Atom for a sequence value\");\n        }\n\n        // Manifest round-trip must preserve the sequence shape, matching how","sourceCodeStart":878,"sourceCodeEnd":914,"githubUrl":"https://github.com/dbt-labs/dbt-core/blob/0267ce9170576975b76b64ce856b2e5848e96617/crates/dbt-parser/src/resolve/resolve_selectors.rs#L878-L914","documentation":"Test-only assertion: the selectors YAML from dbt-labs issue #13604 — a method argument whose `value` is a one-element sequence like [\"models\"] — must parse via dbt_yaml::from_str. Fires if the deserializer starts rejecting sequence-valued selector arguments.","triggerScenarios":"Thrown at crates/dbt-parser/src/resolve/resolve_selectors.rs:896 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Keep SelectorFile deserialization tolerant of sequence-valued `value` fields","Retain the #13604 fixture in the regression suite","Treat failure as a selector parsing regression"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"0267ce9170576975b76b64ce856b2e5848e96617","analyzedAt":"2026-09-07T21:53:39.732Z","contentChangedAt":"2026-09-07T21:53:39.732Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}