> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cognite.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Cognite Data Fusion (CDF) is an industrial DataOps platform. Prefer English docs unless the user asks for another locale.
> Follow /_llms/ index links recursively until you reach page URLs ending in .md. Fetch those Markdown twins instead of HTML.
> For REST APIs, default to calendar version 20230101 (stable). Use 20230101-beta or 20230101-alpha only if the user is on a preview API. Cite paths under /api-reference/concepts/<version>/ and the Cdf-Version header. Prefer the Python SDK (cognite-sdk) unless the user is in JavaScript/TypeScript.
> Start here by task: platform overview /cdf/index.md; data modeling /cdf/dm/index.md; data integration /cdf/integration/index.md; access /cdf/access/index.md; CDF Toolkit /cdf/deploy/cdf_toolkit/index.md; REST quickstart /dev/quickstart.md; Python SDK https://cognite-sdk-python.readthedocs-hosted.com/en/stable/; Atlas AI /cdf/atlas_ai/index.md; plan an Atlas AI agent /cdf/atlas_ai/concepts/atlas_ai_agent_planning.md; Flows apps /cdf/flows/index.md; MCP and IDE setup /dev/guides/ide_ai_integration.md.
> For implementation work, also load /skill.md.

# Rules library

> Look up the insight codes that the Cognite Toolkit reports when you build, deploy, or check Cognite Data Fusion (CDF), including the resource types they apply to, when they run, and how to fix them.

> [!NOTE]
>
> Alpha flags are experimental and can change or be removed without notice. Rules marked **alpha** need the [`alpha-rules`](https://docs.cognite.com/cdf/deploy/cdf_toolkit/api/alpha_flags#alpha-flag-alpha-rules) flag. `cdf check` needs [`check`](https://docs.cognite.com/cdf/deploy/cdf_toolkit/api/alpha_flags#alpha-flag-check), and `cdf build --validate` needs [`build-validate`](https://docs.cognite.com/cdf/deploy/cdf_toolkit/api/alpha_flags#alpha-flag-build-validate).The rules library lists the insight codes that the Cognite Toolkit reports. An insight is a finding in your configuration or your Cognite Data Fusion (CDF) project, such as a missing reference, a change that CDF can't apply, or a recommendation. The Cognite Toolkit prints each insight with its code in brackets, for example `[MISSING-REFERENCED-RESOURCE]`, and writes all insights to `build/insights.csv`.Use the code to look up the rule on this page, or to [ignore the rule](#ignore-or-enforce-rules).## How rules are describedThe same code can apply to several resource types, with a different trigger for each. For example, `INVALID-RESOURCE-CHANGE` applies to containers, views, and data models. Each rule lists the code, the resource type, the severity, the context, and whether the rule is alpha. When one code has more than one trigger, the table also says when the Cognite Toolkit reports it.### CodeCodes use the pattern PROBLEM-SUBJECT, such as `MISSING-REFERENCED-RESOURCE`. The first word tells you how certain the finding is:- `MISSING-*`, `INVALID-*`, and `EXCEEDED-*`: the Cognite Toolkit confirmed the problem.
- `UNVERIFIED-*` and `UNRECOGNIZED-*`: the Cognite Toolkit couldn't confirm the problem. These codes are always warnings.### Severity| Severity | Meaning |
| - | - |
| Error | A confirmed problem. The resource can't be built or deployed as configured. |
| Warning | A potential problem that couldn't be confirmed, or a problem that doesn't block the build. |
| Recommendation | A suggestion that improves governance, performance, or future compatibility. |
| Skipped | `cdf deploy` didn't create, update, or delete the resource, and reports the code as the reason. |### ContextThe context tells you which command reports the rule, and whether the rule needs access to CDF.| Context | When the rule runs |
| - | - |
| Build | Every time you run `cdf build`. The rule only reads your local modules. |
| Build with CDF | When `cdf build` has CDF credentials. Without credentials, the rule doesn't run, or the Cognite Toolkit reports an `UNVERIFIED-*` code instead. |
| Build capacity | When you run `cdf build --validate capacity`. The Cognite Toolkit does a dry-run deployment to count what the deployment would create and delete. |
| Deploy | When `cdf deploy` or `cdf clean` calls the CDF API. |
| Check | When you run `cdf check` against a CDF project. These rules look at resources in CDF, not at your modules. |## Ignore or enforce rulesTo skip a code in one file, add a comment like this to the file:```yaml theme={"languages":{"custom":["/_languages/kuiper.json"]}}
# rules: ignore[UNGOVERNED-RESOURCE, MISSING-REFERENCED-RESOURCE]
```To skip a code in every file, or to make `cdf build` fail when any insight remains, use the `[rules]` section in `cdf.toml`. See [the `rules` section](https://docs.cognite.com/cdf/deploy/cdf_toolkit/api/cdf_toml#the-rules-section) for the options and the comment syntax.## Find a ruleFilter the rules by code, severity, context, or resource type. Select a code to go to its description.

Search codes, resource types, and descriptions

        
        
    Severity
    
  
        
    Context
    
  
        
    Resource type
    
  
        

Include alpha rules

          
Reset filters



      

Showing  of  rules



      

\<table><thead><tr><th scope="col">Code</th>
              \<th scope="col">Resource type</th>
              \<th scope="col">Severity</th>
              \<th scope="col">Context</th>
              \<th scope="col">Reported when</th></tr></thead>
          \<tbody /></table>

## Codes### ANTI-PATTERNA view has a `hasData` filter on another view. CDF resolves a `hasData` filter on a view through the containers of that view, and rejects the filter if that view refers back to the first view.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| View | Warning | Build | Yes |To fix it, use `hasData` on the containers of the referenced view instead of on the view itself.### DEGRADED-PERFORMANCEThe configuration is valid, but queries against it are slow.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| View | Recommendation | Build | Yes | None of the containers of the view require the containers mapped by the views it implements. |
| View | Recommendation | Build | Yes | The view has a nested filter. Nested filters follow a direct relation for every queried instance. |
| View, Container | Recommendation | Build | Yes | A reverse direct relation goes through a direct relation that has no cursorable B-tree index. |To fix it, follow the suggestion in the insight: replace a nested filter with a `hasData` or node type filter, add a `requires` constraint, or add a B-tree index with `cursorable: true` on the direct relation property.### DEPRECATED-FEATUREThe configuration uses a feature or API that is deprecated. See [deprecated and retired features](https://docs.cognite.com/cdf/deprecated.md) for replacements and retirement dates.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Container | Warning | Build | Yes | A property has the type `timeseries`, `file`, or `sequence`, which references an asset-centric API. |
| Sequence row | Warning | Build | No | The `SequenceRow` resource type is deprecated in the Cognite Toolkit. |
| Asset, event, time series, file, sequence, sequence row, data set, label, relationship, security category | Recommendation | Build | Yes | The resource type uses an asset-centric API that retires on December 31, 2027. |
| Group | Warning | Build with CDF | Yes | The group grants an ACL for a deprecated API, and the project is `DATA_MODELING_ONLY`. |
| Group | Recommendation | Build with CDF | Yes | The group grants an ACL for a deprecated API, and the project is hybrid. |To fix it, move to the replacement named in the insight. For example, replace a `timeseries` property with a direct relation to a `CogniteTimeSeries` instance. For sequence rows, use `cdf data download sequences` and `cdf data upload dir`.### DUPLICATED-IDENTIFIERTwo or more resources have the same identifier.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| All | Warning | Build | Yes | The same identifier is defined in more than one file. |
| Group | Warning | Deploy | No | Several groups in CDF share a name. The Cognite Toolkit deletes all of them. |
| Transformation schedule | Warning | Deploy | No | The schedule already exists in CDF. |To fix it, remove the duplicate definition or give it a unique identifier.### EXCEEDED-LIMITThe configuration, or the deployment, goes over a CDF limit.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Container | Warning | Build | Yes | A B-tree index allows values larger than the index size limit, which makes ingestion or the index build fail. |
| Agent | Error | Build with CDF | No | The agent has more tools than the project allows per agent. |
| Container, view, data model | Error | Build with CDF | No | The container or view has more properties, or the data model has more views, than the project allows. |
| Function | Error | Build with CDF | No | CPU or memory is outside the limits of the project. |
| Space, container, view, data model, instance | Error | Build capacity | No | The deployment would take the project total over its limit, including the limit for soft-deleted instances. |
| Stream | Error | Build capacity | No | The deployment would take the number of active streams, in total or for a stream template, over the project limit. |
| Container, view | Warning | Deploy | No | A large set of resources depend on each other, and the deployment might fail because of API batch size limits. |
| Data model | Warning | Deploy | No | The description is longer than the limit, and the Cognite Toolkit truncates it. |To fix it, reduce the number or size of what the insight names, so it stays within the limit shown in the message.### FAILED-REQUESTA request to the CDF API failed during deployment.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Group | Warning | Deploy | No | Creating or deleting a group failed. Delete the remaining groups manually. |
| Transformation | Warning | Deploy | No | Creating a batch of transformations failed with a nonce binding error. The Cognite Toolkit retries them one by one. |To fix it, read the error in the insight, fix the cause, and run the command again.### FAILING-JOBA job in the CDF project failed within the lookback period. By default, `cdf check` looks back 3 days. Change the period with `--lookback-period`.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| Workflow, function, hosted extractor job, transformation | Error | Check | No |To fix it, follow the suggested fix in the insight, and open the link to see the failed run in CDF.### INVALID-FIELDA field in the YAML file is invalid.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| All | Error | Build | No | The YAML doesn't match the resource schema. For example, a required field is missing, or a field has the wrong type. |
| Agent | Error | Build with CDF | No | The agent runtime version doesn't support a field the agent uses. |To fix it, compare the YAML with the [resource library](https://docs.cognite.com/cdf/deploy/cdf_toolkit/references/resource_library.md). For agents, use a runtime version that supports the field, or remove the field.### INVALID-FILE-CONTENTA file has content the Cognite Toolkit can't use.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Agent, app, skill, Streamlit app | Error | Build | No | A referenced file is invalid, for example, an agent tools file, an app `manifest.json`, or a skill Markdown file. |
| All | Error | Build | No | The YAML file is empty, or the Cognite Toolkit can't parse it. |To fix it, correct the file at the line and column shown in the insight. Remove empty YAML files.### INVALID-FILE-SUFFIXThe resource type in the filename isn't a known type for the resource folder. For example, a file named `my_view.Viw.yaml` in the `data_modeling` folder.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| All | Error | Build | No |To fix it, rename the file with a resource type from the [resource library](https://docs.cognite.com/cdf/deploy/cdf_toolkit/references/resource_library.md).### INVALID-REFERENCED-PROPERTYA reverse direct relation in a view goes through a property that isn't a direct relation.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| View | Error | Build | No |To fix it, point the reverse direct relation at a property of type `direct`.### INVALID-REFERENCED-RESOURCEA view that an InField location configuration uses for a card is missing properties that the card requires.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| InField location config | Error | Build with CDF | No |To fix it, add the properties listed in the insight to the view, or use a different view.### INVALID-REQUIREMENTSThe `requirements.txt` file for a function fails validation, so the function can't be installed.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| Function | Error | Build | No |To fix it, correct the package names and versions in `requirements.txt`.### INVALID-RESOURCE-CHANGEThe local configuration changes a deployed resource in a way CDF doesn't support. If you deploy, CDF doesn't apply the change. See [impact of changes to views and data models](https://docs.cognite.com/cdf/dm/dm_concepts/dm_containers_views_datamodels.md#impact-of-changes-to-views-and-data-models).| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Container | Error | Build with CDF | No | A deployed property is changed in a way CDF doesn't support, or `usedFor` is changed. |
| Data model | Error | Build with CDF | No | The version of a view in the data model is changed without a new data model version. |
| View | Error | Build with CDF | No | Properties or `implements` are changed without a new view version. |
| Container | Warning | Deploy | No | CDF doesn't apply a container change during deployment. |To fix it, revert the change, or bump the view or data model version. To make your local files match CDF, run `cdf modules pull`. This overwrites your local YAML files.### INVALID-VALUEA value in the configuration isn't valid for the CDF project or the resource.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Catalog data set, data model spreadsheet | Error | Build | No | The Cognite Toolkit can't convert or parse a value. |
| View | Error | Build | Yes | Views implement each other in a cycle. |
| Stream | Warning | Build | No | The stream template isn't an officially supported template. Ignore the warning if you use a custom template. |
| Agent | Error | Build with CDF | No | The model or runtime version isn't available in the project. |
| Function | Error | Build with CDF | No | The runtime isn't available in the project, or Cognite Functions isn't activated. |
| InField location config | Error | Build with CDF | No | `dataStorage.appInstanceSpace` is already used by legacy InField (`APM_Config`). |
| Function, InField location config, sequence, view | Warning | Deploy | No | CDF rejects or adjusts a value during deployment, for example, while Cognite Functions is being activated. |To fix it, use one of the values listed in the insight. For InField, use a new instance space for `dataStorage.appInstanceSpace`.### INVALID-VARIABLE-PATHA variable path in the config file doesn't match the folder structure in the `modules` directory.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| Config file | Error | Build | No |To fix it, place the variable under the path of the module or folder where you use it.### INVALID-VARIABLE-TYPEA list variable in the config file contains items of different or unsupported types.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| Config file | Error | Build | No |To fix it, make every item in the list the same type: string, integer, float, Boolean, or dictionary.### MISSING-FILE-SUFFIXThe filename has no resource-type suffix, so the Cognite Toolkit skips the file. For example, `my_view.yaml` instead of `my_view.View.yaml`.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| All | Warning | Build | No |To fix it, rename the file so the resource type is the suffix, as in `my_view.View.yaml`.### MISSING-READ-ACCESSThe credentials the Cognite Toolkit uses don't have READ access to a resource type.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Function | Error | Build with CDF | No | The Cognite Toolkit can't read the function limits, because it lacks Functions READ access. |
| All | Skipped | Deploy | No | The Cognite Toolkit can't compare the resources with CDF, so it skips them. |To fix it, give the service account READ access to the resource type.### MISSING-REFERENCED-DIRECTORYA directory that the resource needs doesn't exist.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| App | Error | Build | No | The app directory is missing, or the app is a web project that isn't built. |
| Function | Error | Build | No | The function code directory is missing. |
| Streamlit app | Error | Build | No | The Streamlit app code directory is missing. |To fix it, add the directory at the path shown in the insight. For web apps, run `npm run build` before you deploy.### MISSING-REFERENCED-FILEA file that the resource references doesn't exist.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Agent | Error | Build | No | The instructions file, tools file, or Python code file is missing. |
| App | Error | Build | No | The entry point, `package.json`, or `package-lock.json` is missing. |
| Data model | Error | Build | No | The GraphQL file for the data model is missing. |
| Extraction pipeline | Error | Build | No | The documentation file is missing. |
| File | Error | Build | No | The file content path doesn't exist. |
| Rule set, skill | Error | Build | No | Neither the inline field nor the expected `.ttl` or `.md` file exists. |To fix it, add the file at the path shown in the insight, or correct the reference.### MISSING-REFERENCED-PROPERTYA property that the configuration references doesn't exist in your modules or in CDF.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| InField location config | Error | Build with CDF | No | A field configuration references properties that the view doesn't have. |
| View | Error | Build with CDF | No | A view maps a container property, or a reverse direct relation goes through a direct relation, that doesn't exist. |To fix it, create the property, or remove or correct the reference. Without CDF credentials, the Cognite Toolkit reports [`UNVERIFIED-REFERENCED-PROPERTY`](#unverified-referenced-property) instead.### MISSING-REFERENCED-RESOURCEA resource that the configuration references doesn't exist.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Data model spreadsheet | Error | Build | No | A property references a view or container that isn't in the spreadsheet. |
| All | Error | Build with CDF | No | The referenced resource isn't in the build and doesn't exist in CDF. |
| All | Skipped | Deploy | No | The resource to delete doesn't exist in CDF. |To fix it, add the resource to your modules, deploy it first, or remove the reference. Without CDF credentials, the Cognite Toolkit reports [`UNVERIFIED-REFERENCED-RESOURCE`](#unverified-referenced-resource) instead.### MISSING-VALUEA value that the resource needs is missing.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Container | Warning | Build | Yes | A list property in a B-tree index has no `maxListSize`, or a text property has no `maxTextSize`. |
| Data model | Recommendation | Build | Yes | The data model doesn't include views that its views implement, so its GraphQL schema is invalid. |
| Transformation | Warning | Deploy | No | The transformation has no query, inline or in a separate `.sql` file. |To fix it, add the value named in the insight.### NONEMPTY-RESOURCEThe resource contains data, so `cdf deploy` or `cdf clean` doesn't delete or update it.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| All | Skipped | Deploy | No |To fix it, delete the data first, or run the command with `--drop-data` if you want to delete the data with the resource.### REDUNDANT-PROPERTYA field has no effect.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Group | Recommendation | Build | Yes | Another capability in the group already grants the same actions. |
| Function schedule | Warning | Deploy | No | The schedule sets `functionId`, which the Cognite Toolkit ignores. |To fix it, remove the redundant capability or field.### UNGOVERNED-RESOURCEThe resource isn't assigned to a data set, or to a space for resources that support spaces. Without a data set, you can't control access to the resource.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| All | Recommendation | Build | No |To fix it, set `dataSetExternalId`, or `space` where the resource type supports it.### UNREADABLE-FILEThe Cognite Toolkit can't read the file, or can't read the identifier of a resource in the file after a validation error.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| All | Error | Build | No |To fix it, check the file encoding and permissions, and make sure each resource has its identifier fields.### UNRECOGNIZED-FIELDA field isn't part of the resource schema. The Cognite Toolkit deploys the field unchanged, and CDF may reject it.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| All | Warning | Build | No |To fix it, check the field name for typos against the [resource library](https://docs.cognite.com/cdf/deploy/cdf_toolkit/references/resource_library.md).### UNRECOGNIZED-VALUEA value isn't a known option, for example, an unknown capability name in a group. The Cognite Toolkit deploys the value unchanged, and CDF may reject it.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| All, group | Warning | Build | No |To fix it, compare the value with the [resource library](https://docs.cognite.com/cdf/deploy/cdf_toolkit/references/resource_library.md).### UNRESOLVED-VARIABLEA variable placeholder, such as `{{ my_variable }}`, has no value.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| All | Error | Build | No |To fix it, define the variable in the config file for that environment, such as `config.dev.yaml`, under the `variables` path that matches the module.### UNSUPPORTED-RESOURCE-CREATIONThe Cognite Toolkit doesn't create MQTT broker sources, because the CDF response includes authentication information that would be lost.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| Hosted extractor source | Warning | Deploy | No |To fix it, create the source through the CDF API. The Cognite Toolkit can update the source after it exists.### UNSUPPORTED-RESOURCE-REMOVALSomething you removed from the local configuration can't be removed from CDF.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| Container | Warning | Build with CDF | No | Properties, or enum values of a property, that are deployed are missing from the local file. |
| Data model | Warning | Build with CDF | No | Views that are deployed for the same data model version are missing from the local file. |
| View | Warning | Build with CDF | No | Properties that are deployed for the same view version are missing from the local file. |
| Group | Warning | Deploy | No | The group is used by the current service account, so the Cognite Toolkit doesn't delete it. |
| Space | Warning | Deploy | No | The space is global and can't be deleted. |
| All | Skipped | Deploy | No | The resource type doesn't support deletion. |To fix it, add the removed items back, or bump the view or data model version. To make your local files match CDF, run `cdf modules pull`.### UNUSED-RESOURCEA resource in the CDF project is older than the minimum age and isn't used. For example, a transformation that has never run, or a space without instances. By default, the minimum age is 14 days.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| Workflow, function, hosted extractor job, hosted extractor source, hosted extractor destination, hosted extractor mapping, transformation, space, view, data model, extraction pipeline, RAW database, RAW table | Recommendation | Check | No |To fix it, delete the resources listed in the insight, or start using them.### UNVERIFIED-CREDENTIALSThe Cognite Toolkit can't compare the credentials of an external data source with CDF, so it treats the source as changed and recreates it on every deployment.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| External data source | Warning | Deploy | No |No fix is needed. The warning tells you why the source is recreated.### UNVERIFIED-REFERENCED-PROPERTYA view references a container property or a direct relation that isn't in your modules, and the Cognite Toolkit didn't check CDF.| Resource type | Severity | Context | Alpha |
| - | - | - | - |
| View | Warning | Build | No |To fix it, run `cdf build` with CDF credentials so the Cognite Toolkit can check CDF, or add the property to your modules.### UNVERIFIED-REFERENCED-RESOURCEA resource that the configuration references isn't in your modules, and the Cognite Toolkit couldn't check CDF.| Resource type | Severity | Context | Alpha | Reported when |
| - | - | - | - | - |
| All | Warning | Build | No | The Cognite Toolkit has no CDF credentials, so it didn't check CDF. |
| Container, view | Warning | Deploy | No | The referenced containers or views weren't found, or you lack access to them. |To fix it, run `cdf build` with CDF credentials, add the resource to your modules, or give the service account access to the resource.## Reserved codesThe Cognite Toolkit defines these codes, but doesn't report them yet: `BLOCKED-RESOURCE`, `INVALID-CREDENTIALS`, `MISSING-CREDENTIALS`, and `UNTRIGGERED-RESOURCE`.If a rule set fails while it runs, the Cognite Toolkit reports `INTERNAL-VALIDATOR-EXCEPTION`. This means the rule set has a problem, not necessarily your configuration. The build continues.
