Skip to content

Conversation

@jesusmgg
Copy link

@jesusmgg jesusmgg commented Dec 12, 2025

Overview

Restores custom functionality from v0.x that was lost during the v1.x refactor.

Related: https://github.com/datacoves/datacoves-power-user/pull/62

Changes

SQLFluff Templater Fix

  • Override _apply_dbt_builtins to return False, preventing SQLFluff from wrapping dbt builtins in FunctionWrapper objects (which lack .get() method)
  • This restores the behavior from v0.2.x using a different approach

Snapshot Support

Query Execution

  • Wrap compiled code in subquery to safely apply user LIMIT clause
  • Don't apply default limit if an in-script LIMIT clause is already present

Logging Fix

  • Removed hardcoded DEBUG log level
  • Now uses LOG_LEVEL env variable with INFO as default

⚠️ Deployment Note

The production entrypoint in datacoves/src/code-server/dbt-core-interface/src/bin/entrypoint.sh needs to be updated:

- python -m dbt_core_interface.project --host 0.0.0.0 --port 8581
+ python -m dbt_core_interface.server --host 0.0.0.0 --port 8581

@jesusmgg jesusmgg changed the title [DCV-3454] Fix SQLFluff FunctionWrapper error and add snapshot tag stripping [DCV-3454] Restore custom functionality of old v0.x Dec 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants