<!--
{
  "documentType" : "article",
  "framework" : "SceneKit",
  "identifier" : "/documentation/SceneKit/1573761-scene-file-consistency-check-err",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "Scene File Consistency Check Error Codes"
}
-->

# Scene File Consistency Check Error Codes

Error codes that identify errors found during a scene-file-format consistency check.

## Discussion

If you specify <doc://com.apple.documentation/documentation/Swift/true> for the [`checkConsistency`](/documentation/SceneKit/SCNSceneSource/LoadingOption/checkConsistency) when creating or loading from a scene source, SceneKit verifies the scene file against the specification for its file format. SceneKit reports any format verification issues in an <doc://com.apple.documentation/documentation/Foundation/NSError> object whose <doc://com.apple.documentation/documentation/Foundation/NSError/code> property is one of these values.

For more details about the location and nature of any format validation errors, see the [`SCNDetailedErrorsKey`](/documentation/SceneKit/SCNDetailedErrorsKey) key in the error’s <doc://com.apple.documentation/documentation/Foundation/NSError/userInfo> dictionary, and the keys listed in [Scene File Consistency Error Keys](/documentation/SceneKit/scene-file-consistency-error-keys).

## Topics

### Constants

[`var SCNConsistencyInvalidURIError: Int`](/documentation/SceneKit/SCNConsistencyInvalidURIError)

The scene file contains an invalid URI (or URL).

[`var SCNConsistencyInvalidCountError: Int`](/documentation/SceneKit/SCNConsistencyInvalidCountError)

The scene file contains an invalid number of scenes.

[`var SCNConsistencyInvalidArgumentError: Int`](/documentation/SceneKit/SCNConsistencyInvalidArgumentError)

An element in the scene file contains an invalid option for one of its attributes.

[`var SCNConsistencyMissingElementError: Int`](/documentation/SceneKit/SCNConsistencyMissingElementError)

A required element in the scene file is missing.

[`var SCNConsistencyMissingAttributeError: Int`](/documentation/SceneKit/SCNConsistencyMissingAttributeError)

An element in the scene file is missing a required attribute.

[`var SCNConsistencyXMLSchemaValidationError: Int`](/documentation/SceneKit/SCNConsistencyXMLSchemaValidationError)

The format of the scene file does not match its XML schema definition.



---

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)