54 diagnostic codes

Every code Lineward reports, free in the editor and reported as you type; each can be set to another severity or switched off.

Which checks matter most to you?

Each code is scored from 1 to 5 on four criteria, seen from the developer’s chair. Sort by one criterion, or weight them your way, and the table re-orders.

What the four criteria measure

Debugging time saved
Once something looks wrong, how long finding the cause would take without the diagnostic.
Impact
What it costs if it ships: 5 is wrong numbers in production, 3 a failed pipeline, 1 cosmetic.
Time to detection
How long before anything reveals the problem: 5 is nothing ever signals it; 3, Snowflake refuses it at run time, sometimes late in a full run; 1, dbt™ parse fails in seconds.
Complexity
How much non-obvious dbt™ or Snowflake knowledge it takes to spot it by eye.

These scores are our own estimates, not measurements: Lineward collects no usage data. Use them to explore, not as a promise.

54 of 54 shown
CodeDiagnosticScore
LW038Comparison decided by the session’s time zoneA DATE or TIMESTAMP_NTZ is compared with a TIMESTAMP_LTZ or TIMESTAMP_TZ — a JOIN key included — so Snowflake converts it in the session’s TIMEZONE, and the result depends on who runs the model.Warning · Time zones taken from the session
LW039Timestamp conversion that loses or invents its time zoneA cast, TO_TIMESTAMP_*, TO_DATE or TO_TIME drops a TIMESTAMP_TZ offset or takes the zone from the session, a two-argument CONVERT_TIMEZONE reads a TIMESTAMP_NTZ or DATE in the session’s zone, a three-argument CONVERT_TIMEZONE converts a TIMESTAMP_LTZ, whose wallclock time it reads in the session’s zone, or a TIMESTAMP_LTZ_FROM_PARTS or TIMESTAMP_TZ_FROM_PARTS is called without its time_zone. A TIMESTAMP_TZ known to hold UTC may be cast to TIMESTAMP_NTZ.Warning · Time zones taken from the session
LW049Alias ignored by a clauseAn output alias read in GROUP BY, WHERE, HAVING, QUALIFY or a JOIN where a column of the same name wins — Snowflake reads the column, not the alias, and says nothing.Warning · SQL errors before dbt™ run
LW047Set-operation branches out of orderA UNION, INTERSECT or MINUS branch whose columns trade places with the first branch’s — Snowflake matches them by position, so values land in the wrong columns without an error.Warning · SQL errors before dbt™ run
LW044Declared time zone differs from the SQL’sA column whose meta time_zone in schema.yml is not the zone its SQL shows — the YAML says UTC, the SQL converts to another zone, or the reverse.Warning · Time zones taken from the session
LW040Key repeated in a YAML mappingA key written twice in one mapping of a schema file or dbt_project.yml — dbt™ silently keeps the last value; reported on the later occurrence, with the line of the first.Warning · YAML validity
LW055CTE read by readers whose filters differA CTE over a model or a source that several readers filter differently — Snowflake computes it once for all of them, so their filters cannot reduce what it scans.Warning · Dead and recomputed CTEs
LW028Hardcoded table referenceFROM or JOIN reads schema.table or db.schema.table directly, bypassing ref() and source().Warning · Project graph problems
LW032Declared type differs from SQL typeA column’s data_type in schema.yml is of another type family than the one the model’s SQL produces, with types followed through ref() and source().Warning · Type checks between YAML and SQL
LW033Argument matches no signatureA Snowflake built-in — aggregates included — is called with arguments whose types match none of its signatures, such as SUM over text.Warning · Type checks between YAML and SQL
LW035Arithmetic on a non-numeric operandArithmetic is applied to an operand that cannot convert to a number.Warning · Type checks between YAML and SQL
LW008GROUP BY errorA column neither grouped on nor aggregated is read in the select list, HAVING, QUALIFY or ORDER BY, in a window call’s arguments or window, or in a query that aggregates without GROUP BY — in every CTE, subquery and set operation, with CUBE, ROLLUP, GROUPING SETS and GROUP BY ALL understood. A wildcard (*, t.*) counts for the columns it brings: under a GROUP BY it is reported only when they are all known and one is ungrouped, and always in a query that aggregates without GROUP BY.Error · SQL errors before dbt™ run
LW034Comparison between types that never convertA comparison or JOIN key compares types Snowflake never converts implicitly, such as a DATE and a NUMBER.Warning · Type checks between YAML and SQL
LW036Set operation branches that cannot unifyThe branches of a UNION or another set operation give one column types that cannot unify.Warning · Type checks between YAML and SQL
LW037CASE results that cannot unifyThe results of a CASE expression have types that cannot unify.Warning · Type checks between YAML and SQL
LW051Secret environment variable outside profiles.ymlAn env_var() of a DBT_ENV_SECRET_ variable in a model, a macro, dbt_project.yml or a schema file — dbt™ refuses to render a secret there.Error · Environment variables dbt™ refuses
LW010Invalid column referenceA column the upstream ref() model does not output is read — through its alias, or unqualified in a SELECT whose FROM is that one model.Warning · SQL errors before dbt™ run
LW042Model only disabled models readA model dbt™ builds whose every reader is disabled — it is built for nothing.Info · Disabled models
LW007SQL syntax errorThe compiled SQL of a model fails to parse; Snowflake clauses are understood.Error · SQL errors before dbt™ run
LW009Function call errorA Snowflake built-in is called with fewer or more arguments than it accepts, by Snowflake’s own function listing or, for a function it does not name, by its documented forms — or a window function is called without OVER, or without the ORDER BY its documented forms require.Warning · SQL errors before dbt™ run
LW014Column in YAML but not in SQLA column declared in schema.yml is absent from the model’s SELECT output.Warning · Schema drift between SQL and YAML
LW041Reference to a disabled modelA model or an exposure ref()s a model, seed or snapshot that enabled: false leaves out — dbt™ refuses to compile the model (or to parse the project, for an exposure).Error · Disabled models
LW011Unused modelA staging or intermediate model has no downstream ref() consumers.Warning · Project graph problems
LW017Duplicate column nameThe same column name appears twice under one model or one source table in schema.yml.Warning · YAML validity
LW020Fixture column not in schemaA header of tests/samples/<model>.csv or tests/expects/<model>.csv is not declared in schema.yml — flagged on the exact header cell.Warning · Fixture headers checked against the schema
LW021Schema column not in fixtureA column declared in schema.yml is missing from the model’s CSV fixture.Warning · Fixture headers checked against the schema
LW031Settings driftlineward.toml and .vscode/settings.json give one setting different values; reported on the key’s line in lineward.toml, which wins.Warning · Settings drift
LW005Circular dependencyA ref() chain creates a cycle (A → B → A), reported at each ref() of the cycle; the rest of the project keeps working.Error · Project graph problems
LW027Undefined macro callA macro is called that neither dbt™, the project nor the calling package defines — a package’s macro called without its package prefix included — or a method dbt™’s adapter does not have. An error in a project read as dbt™ 2.x, whose two distributions, dbt™ OSS and dbt™, both refuse to parse it.Warning · Broken references
LW046Ambiguous column referenceAn unqualified column that two relations of a SELECT both have — Snowflake refuses the query as ambiguous.Error · SQL errors before dbt™ run
LW048Duplicate output column nameA table, view, incremental or dynamic-table model, or a snapshot, that outputs two columns of one name — Snowflake refuses to create it.Error · SQL errors before dbt™ run
LW013No testsA model has no dbt™ column tests in schema.yml.Info · Documentation and test coverage
LW024Undeclared output columnAn output column is absent from schema.yml when the model already declares at least one column.Warning · Schema drift between SQL and YAML
LW029Unused sourceA declared source table that no model, snapshot, singular test, analysis or exposure reads, and no relationships test names.Warning · Project graph problems
LW006YAML syntax errorA schema file or dbt_project.yml fails to parse.Error · YAML validity
LW050Profile or target not foundThe profiles.yml dbt™ reads has no profile the project selects, or no output for the selected target — dbt™ fails before it runs anything.Warning · Missing profiles.yml, profile or target
LW012Undocumented modelA model has no description in schema.yml.Info · Documentation and test coverage
LW015Column in SQL but not in YAMLAn output column is absent from the model’s schema.yml entry.Hint · Schema drift between SQL and YAML
LW022Missing sample fixtureA model with no ref() inputs has no tests/samples/<model>.csv.Info · Missing fixture files
LW023Missing expect fixtureA model nothing dbt™ builds consumes has no tests/expects/<model>.csv.Info · Missing fixture files
LW026Schema model with no SQL fileA model declared in schema.yml has no .sql file.Warning · Broken references
LW053Unused CTE columnA column a CTE outputs that nothing later in the model reads, in any clause — dead code: removing it changes neither the rows nor another column.Info · Dead and recomputed CTEs
LW054Unused CTEA CTE of the model’s WITH clause that nothing in the model reads — dead code.Info · Dead and recomputed CTEs
LW001Invalid ref()ref() names a model, seed or snapshot that neither the project nor its installed packages define.Error · Broken references
LW002Invalid source()source() names a declared source but a table it does not have.Error · Broken references
LW016Duplicate model nameThe same model name appears twice in a schema.yml file.Error · YAML validity
LW018Missing name: fieldA models: or columns: entry in schema.yml has no name: key.Error · YAML validity
LW019Unknown source()source() names a source no _sources.yml declares.Warning · Broken references
LW030Self-referencing modelA model ref()s itself; {{ this }} is allowed.Error · Broken references
LW045Model or source table defined or described twiceTwo SQL files of one model name, two schema files describing one model, a source table declared twice, in one schema file or in two, or a package’s source that two schema files override — dbt™ refuses to parse the project.Error · Project graph problems
LW025Missing profiles.ymlNo profiles.yml where dbt™ reads it — the project, --profiles-dir, DBT_PROFILES_DIR or ~/.dbt/ — before a dbt™ command fails on it.Warning · Missing profiles.yml, profile or target
LW052Environment variable not set, no defaultAn env_var() with no default whose variable neither your environment nor the project’s .env sets — dbt™ fails to compile. In the editor only, since CI’s environment may differ.Warning · Environment variables this machine lacks
LW056dbt™ version outside the supported rangeThe dbt™ versions the project requires in dbt_project.yml include none Lineward supports: dbt™ Core 1.10 to 1.12, and dbt™ 2.0 in either of its distributions, dbt™ OSS or dbt™. The project is still analysed, and the analysis may differ from what that dbt™ does.Info · A dbt™ version Lineward does not read
LW043SQL checks skipped: the render needs the warehouseA model whose render needs the warehouse (run_query, a relation’s columns) — says which SQL checks it skipped, and which it could still run, instead of guessing.Info · Diagnostics on the compiled SQL