{"record":{"id":"59ceeaf237c03fad","repo":"assafelovic/gpt-researcher","slug":"invalid-retriever-s-found-join-invalid-ret","errorCode":null,"errorMessage":"Invalid retriever(s) found: {', '.join(invalid_retrievers)}. Valid options are: {', '.join(valid_retrievers)}.","messagePattern":"Invalid retriever\\(s\\) found: (.+?)\\. Valid options are: (.+?)\\.","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"gpt_researcher/config/config.py","lineNumber":198,"sourceCode":"    @classmethod\n    def list_available_configs(cls) -> List[str]:\n        \"\"\"List all available configuration names.\"\"\"\n        configs = [\"default\"]\n        for file in os.listdir(cls.CONFIG_DIR):\n            if file.endswith(\".json\"):\n                configs.append(file[:-5])  # Remove .json extension\n        return configs\n\n    def parse_retrievers(self, retriever_str: str) -> List[str]:\n        \"\"\"Parse the retriever string into a list of retrievers and validate them.\"\"\"\n        from ..retrievers.utils import get_all_retriever_names\n        \n        retrievers = [retriever.strip()\n                      for retriever in retriever_str.split(\",\")]\n        valid_retrievers = get_all_retriever_names() or []\n        invalid_retrievers = [r for r in retrievers if r not in valid_retrievers]\n        if invalid_retrievers:\n            raise ValueError(\n                f\"Invalid retriever(s) found: {', '.join(invalid_retrievers)}. \"\n                f\"Valid options are: {', '.join(valid_retrievers)}.\"\n            )\n        return retrievers\n\n    @staticmethod\n    def parse_llm(llm_str: str | None) -> tuple[str | None, str | None]:\n        \"\"\"Parse llm string into (llm_provider, llm_model).\"\"\"\n        from gpt_researcher.llm_provider.generic.base import _SUPPORTED_PROVIDERS\n\n        if llm_str is None:\n            return None, None\n        try:\n            llm_provider, llm_model = llm_str.split(\":\", 1)\n            assert llm_provider in _SUPPORTED_PROVIDERS, (\n                f\"Unsupported {llm_provider}.\\nSupported llm providers are: \"\n                + \", \".join(_SUPPORTED_PROVIDERS)\n            )","sourceCodeStart":180,"sourceCodeEnd":216,"githubUrl":"https://github.com/assafelovic/gpt-researcher/blob/6f998577d547b1e54ec662dac63583aa11e3b84b/gpt_researcher/config/config.py#L180-L216","documentation":"Config.parse_retrievers splits the RETRIEVERS setting on commas and validates each name against the registry of installed retriever providers (get_all_retriever_names). Any name not in the registry raises a ValueError listing the invalid names and the valid ones.","triggerScenarios":"Setting RETRIEVERS='tavily,googl' (typo), naming a retriever whose optional dependency isn't installed so it isn't registered, or including empty/whitespace-only segments from a trailing comma in some versions.","commonSituations":"Typos in the RETRIEVERS env var; expecting a retriever (e.g. 'duckduckgo') that requires an extra pip install; copying a config from a newer/older version with different retriever names.","solutions":["Check the error's valid-options list and correct the spelling","Install the optional dependency that registers the retriever you want (see docs/optional-dependencies)","Pin/upgrade gpt-researcher to the version whose retriever names you're using"],"exampleFix":"# before\nRETRIEVERS=tavily,googl\n# after\nRETRIEVERS=tavily,google","handlingStrategy":"validation","validationCode":"from gpt_researcher.skills.retriever.retriever_automator import get_all_retriever_names\nwanted = [r.strip() for r in os.getenv(\"RETRIEVERS\",\"tavily\").split(\",\")]\nvalid = get_all_retriever_names() or []\nbad = [r for r in wanted if r and r not in valid]\nassert not bad, f\"Invalid retrievers: {bad}. Valid: {valid}\"","typeGuard":null,"tryCatchPattern":"try:\n    cfg = Config()\nexcept ValueError as e:\n    if \"Invalid retriever\" in str(e):\n        print(e); exit(2)\n    raise","preventionTips":["Validate RETRIEVERS at app startup against get_all_retriever_names()","Install optional retriever extras in your Docker image"],"tags":["python","config","retrievers","validation"],"backgroundTag":"invalid-config-value","analyzedSha":"6f998577d547b1e54ec662dac63583aa11e3b84b","analyzedAt":"2026-08-28T17:50:07.383Z","schemaVersion":2},"datasetVersion":"2026-08-28T21:17:43.275Z"}