{"record":{"id":"0d4cddf6713f59f1","repo":"jax-ml/jax","slug":"unsupported-type-x","errorCode":null,"errorMessage":"Unsupported type: {x}","messagePattern":"Unsupported type: (.+?)","errorType":"exception","errorClass":"TypeError","httpStatus":null,"severity":"error","filePath":"jax/_src/pallas/mosaic_gpu/core.py","lineNumber":1164,"sourceCode":"\n  @classmethod\n  def from_transformed_ref(\n      cls,\n      ref: pallas_core.TransformedRef,\n      byte_offset: int,\n      alias_group_idx: int,\n      layout: tcgen05.TMEMLayout | None = None,\n  ):\n    return cls(dtypes.dtype(ref.dtype), ref.ref.shape, byte_offset, alias_group_idx, layout)\n\n  def transform_type(self, x):\n    match x:\n      case state_types.AbstractRef():\n        return x.update(inner_aval=self.transform_type(x.inner_aval))\n      case jax_core.ShapedArray():\n        return x.update(shape=self.shape, dtype=self.dtype)\n      case _:\n        raise TypeError(f\"Unsupported type: {x}\")\n\n\n@dataclasses.dataclass(frozen=True)\nclass SwizzleTransform(state_types.Transform):\n  swizzle: int\n\n  def __post_init__(self):\n    if self.swizzle not in {32, 64, 128}:\n      raise ValueError(\n          f\"Swizzle {self.swizzle} is not supported. Only 32, 64 and 128 are\"\n          \" accepted.\"\n      )\n\n  def transform_type(\n      self, x: jax_core.AbstractValue\n  ) -> jax_core.AbstractValue:\n    match x:\n      case jax_core.ShapedArray():","sourceCodeStart":1146,"sourceCodeEnd":1182,"githubUrl":"https://github.com/jax-ml/jax/blob/1e1c6a8fc06dfcd1247076ec5cae4640cea5d7bb/jax/_src/pallas/mosaic_gpu/core.py#L1146-L1182","documentation":"The transform_type of ExtractAliasedRef only supports AbstractRef (recursing into inner_aval) and ShapedArray inputs; any other abstract value type raises TypeError with the offending type name.","triggerScenarios":"Applying an extract-aliased-ref transform to an abstract value that is neither a ShapedArray nor an AbstractRef, e.g. a token or a differently-shaped aval, via get_ref_aval or block mapping conversion.","commonSituations":"Unusual avals flowing through pallas pipelines (tokens, custom avals); version mismatches where new aval kinds reach this transform.","solutions":["Ensure only array-like refs/blocks reach this path","Inspect the aval type (type(x)) in a debugger to find what non-array value is leaking in","Upgrade jax if the aval type is newly introduced and support was added later"],"exampleFix":null,"handlingStrategy":"type-guard","validationCode":"assert isinstance(x, (jax_core.ShapedArray, state_types.AbstractRef))","typeGuard":"def supported_aval(x): return isinstance(x, (jax_core.ShapedArray, state_types.AbstractRef))","tryCatchPattern":null,"preventionTips":["Keep custom avals out of ExtractAliasedRef paths"],"tags":["jax","pallas","mosaic-gpu","aval","type-error"],"backgroundTag":"unsupported-aval-type","analyzedSha":"1e1c6a8fc06dfcd1247076ec5cae4640cea5d7bb","analyzedAt":"2026-08-27T09:53:25.647Z","schemaVersion":2},"datasetVersion":"2026-08-27T13:17:12.746Z"}