<!--
{
  "availability" : [
    "iOS: 14.0.0 -",
    "iPadOS: 14.0.0 -",
    "macCatalyst: 14.0.0 -",
    "macOS: 11.0.0 -",
    "tvOS: 14.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Metal",
  "identifier" : "/documentation/Metal/MTLCommandBufferEncoderInfoErrorKey",
  "metadataVersion" : "0.1.0",
  "role" : "Global Variable",
  "symbol" : {
    "kind" : "Global Variable",
    "modules" : [
      "Metal"
    ],
    "preciseIdentifier" : "c:@MTLCommandBufferEncoderInfoErrorKey"
  },
  "title" : "MTLCommandBufferEncoderInfoErrorKey"
}
-->

# MTLCommandBufferEncoderInfoErrorKey

A key to a command buffer error’s user information dictionary that retrieves additional information about a GPU’s runtime error.

```
let MTLCommandBufferEncoderInfoErrorKey: String
```

## Discussion

You can retrieve an [`MTLCommandBufferEncoderInfo`](/documentation/Metal/MTLCommandBufferEncoderInfo) instance from the <doc://com.apple.documentation/documentation/Foundation/NSError/userInfo> dictionary of a command buffer’s [`error`](/documentation/Metal/MTLCommandBuffer/error) property.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)