{"record":{"id":"017ca421c2774827","repo":"tensorflow/models","slug":"max-ids-per-table-is-not-either-a-list-or-an-int-o","errorCode":null,"errorMessage":"max_ids_per_table is not either a list or an int or None, got {type(max_ids_per_table)}","messagePattern":"max_ids_per_table is not either a list or an int or None, got (.+?)","errorType":"exception","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"official/recommendation/ranking/task.py","lineNumber":93,"sourceCode":"      )\n  elif isinstance(embedding_dim, int):\n    embedding_dim = [embedding_dim] * len(vocab_sizes)\n  else:\n    raise ValueError(\n        'embedding_dim is not either a list or an int, got '\n        f'{type(embedding_dim)}'\n    )\n\n  if isinstance(max_ids_per_table, List):\n    if len(vocab_sizes) != len(max_ids_per_table):\n      raise ValueError(\n          f'length of vocab_sizes: {len(vocab_sizes)} is not equal to the '\n          f'length of max_ids_per_table: {len(max_ids_per_table)}'\n      )\n  elif isinstance(max_ids_per_table, int):\n    max_ids_per_table = [max_ids_per_table] * len(vocab_sizes)\n  elif max_ids_per_table is not None:\n    raise ValueError(\n        'max_ids_per_table is not either a list or an int or None, got '\n        f'{type(max_ids_per_table)}'\n    )\n\n  if isinstance(max_unique_ids_per_table, List):\n    if len(vocab_sizes) != len(max_unique_ids_per_table):\n      raise ValueError(\n          f'length of vocab_sizes: {len(vocab_sizes)} is not equal to the '\n          'length of max_unique_ids_per_table: '\n          f'{len(max_unique_ids_per_table)}'\n      )\n  elif isinstance(max_unique_ids_per_table, int):\n    max_unique_ids_per_table = [max_unique_ids_per_table] * len(vocab_sizes)\n  elif max_unique_ids_per_table is not None:\n    raise ValueError(\n        'max_unique_ids_per_table is not either a list or an int or None, '\n        f'got {type(max_unique_ids_per_table)}'\n    )","sourceCodeStart":75,"sourceCodeEnd":111,"githubUrl":"https://github.com/tensorflow/models/blob/e006f5f0d534913e49c1f1dae87364039fa607e2/official/recommendation/ranking/task.py#L75-L111","documentation":"Error \"max_ids_per_table is not either a list or an int or None, got {type(max_ids_per_table)}\" thrown in tensorflow/models.","triggerScenarios":"Thrown at official/recommendation/ranking/task.py:93 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"e006f5f0d534913e49c1f1dae87364039fa607e2","analyzedAt":"2026-08-24T14:09:15.576Z","schemaVersion":2},"datasetVersion":"2026-08-24T17:17:21.512Z"}