{"record":{"id":"5931d70aeaad9469","repo":"DIYgod/RSSHub","slug":"type-5931d7","errorCode":null,"errorMessage":"暂不支持对${type}的订阅","messagePattern":"暂不支持对(.+?)的订阅","errorType":"validation","errorClass":"InvalidParameterError","httpStatus":400,"severity":"warning","filePath":"lib/routes/nua/dc.ts","lineNumber":85,"sourceCode":"            listName = 'div.pre65.left p.small_content_2';\n            listDate = '.date';\n            artiContent = '.article';\n            webPageName = 'div.pre65.left.is-inview .big_title';\n            break;\n        case 'party':\n            listName = 'div.pre35.right li.party_list';\n            listDate = '.date';\n            artiContent = '.article';\n            webPageName = 'div.pre35.right .big_title';\n            break;\n        case 'youth':\n            listName = 'ul.works_list p.small_content_2.viewpoint';\n            listDate = '.date';\n            artiContent = '.article';\n            webPageName = 'ul.screen_4 .big_title';\n            break;\n        default:\n            throw new InvalidParameterError(`暂不支持对${type}的订阅`);\n    }\n\n    const items = await util.ProcessList(baseUrl, baseUrl, listName, listDate, webPageName);\n    const results = await util.ProcessFeed(items[0], artiContent);\n\n    return {\n        title: 'NUA-设计学院-' + items[1],\n        link: baseUrl,\n        description: '南京艺术学院 设计学院 ' + items[1],\n        item: results,\n    };\n}\n","sourceCodeStart":67,"sourceCodeEnd":98,"githubUrl":"https://github.com/DIYgod/RSSHub/blob/bed535e0879dc71c5aff6f1e7bd1ac21ede40115/lib/routes/nua/dc.ts#L67-L98","documentation":"Thrown as an `InvalidParameterError` when the `type` path parameter for the NUA (Nanjing University of the Arts) Design College route does not match any of the supported `case` branches in the switch statement. The switch covers specific page types for the design school, and the default branch throws.","triggerScenarios":"A user requests the NUA dc route with a `type` value that is not one of the predefined case labels (the cases assign CSS selectors like 'div.pre35.right li.party_list' for specific sub-pages). The route path uses `type` to select which section of the design college website to scrape.","commonSituations":"User passes an arbitrary or misspelled type value. The website restructured its sections and a previously valid type is no longer in the switch. A radar rule references an unsupported type.","solutions":["Check the switch statement in `lib/routes/nua/dc.ts` for the list of supported type values.","Browse the NUA design college website to find the correct type identifier for the desired section.","If a new section exists, add a new `case` branch with the appropriate CSS selectors."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// Validate type against known switch cases before processing\nconst validDcTypes = new Set(['news', 'notice', /* ...all case labels from the switch */]);\nif (!validDcTypes.has(type)) {\n    throw new InvalidParameterError(`暂不支持对${type}的订阅`);\n}","typeGuard":"function isSupportedDcType(type: string): boolean {\n    // Add all case labels from the switch in dc.ts\n    return ['news', 'notice'].includes(type);\n}","tryCatchPattern":null,"preventionTips":["List all supported type values in the route parameters description.","Validate the type parameter with a Set lookup before the switch.","Keep the switch cases and the route documentation in sync."],"tags":["validation","nua","invalid-parameter","chinese-site","scraper"],"backgroundTag":null,"analyzedSha":"bed535e0879dc71c5aff6f1e7bd1ac21ede40115","analyzedAt":"2026-08-12T19:29:35.364Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}