Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
682e314
feat: Add dbt integration for importing models as FeatureViews (#3335)
YassinNouh21 Jan 10, 2026
d20962d
fix: Address mypy and ruff lint errors in dbt integration
YassinNouh21 Jan 10, 2026
354f921
fix: Address ruff lint errors in dbt unit tests
YassinNouh21 Jan 10, 2026
5ca317c
style: Format dbt files with ruff
YassinNouh21 Jan 10, 2026
a301f83
fix: Remove unused dbt-artifacts-parser import and fix enum import
YassinNouh21 Jan 10, 2026
460810c
feat: Use dbt-artifacts-parser for typed manifest parsing
YassinNouh21 Jan 10, 2026
b398368
fix: Add graceful fallback for dbt-artifacts-parser validation errors
YassinNouh21 Jan 10, 2026
2f777ff
fix: Skip dbt tests when dbt-artifacts-parser is not installed
YassinNouh21 Jan 10, 2026
86fb951
refactor: Simplify parser to rely solely on dbt-artifacts-parser
YassinNouh21 Jan 10, 2026
a17b50c
ci: Add dbt-artifacts-parser to unit test dependencies
YassinNouh21 Jan 10, 2026
55174a5
fix: Address Copilot code review comments for dbt integration
YassinNouh21 Jan 10, 2026
e4ba00a
fix: Only add ellipsis to truncated descriptions
YassinNouh21 Jan 10, 2026
01730a8
style: Format dbt files with ruff
YassinNouh21 Jan 10, 2026
8a06b83
fix: Convert doctest examples to code blocks to avoid CI failures
YassinNouh21 Jan 10, 2026
fb40e93
fix: Add dbt-artifacts-parser to feast[ci] and update requirements
YassinNouh21 Jan 11, 2026
53932ff
docs: Add dbt integration documentation
YassinNouh21 Jan 11, 2026
972fc96
docs: Add alpha warning to dbt integration documentation
YassinNouh21 Jan 14, 2026
b2901f4
fix: Add dbt-artifacts-parser to CI_REQUIRED dependencies
YassinNouh21 Jan 14, 2026
fe253c1
fix: Add defensive Array.base_type handling with logging
YassinNouh21 Jan 14, 2026
ed2c291
docs: Add comment explaining ImageBytes/PdfBytes exclusion
YassinNouh21 Jan 14, 2026
7a50c73
fix: Move imports to top of file to resolve linter errors
YassinNouh21 Jan 16, 2026
c4ad283
Merge branch 'master' into feat/dbt-feast-integration-3335-clean
franciscojavierarceo Jan 16, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix: Address mypy and ruff lint errors in dbt integration
Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>
  • Loading branch information
YassinNouh21 committed Jan 10, 2026
commit d20962d0b4592cf59cf430d6facce0348e2f7e00
12 changes: 6 additions & 6 deletions sdk/python/feast/cli/dbt_import.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
dbt models with Feast feature stores.
"""

from typing import List, Optional
from typing import Any, Dict, List, Optional

import click
from colorama import Fore, Style
Expand Down Expand Up @@ -119,8 +119,8 @@ def import_command(
# Generate Python file instead of applying to registry
feast dbt import -m target/manifest.json -e driver_id --tag feast --output features.py
"""
from feast.dbt.parser import DbtManifestParser
from feast.dbt.mapper import DbtToFeastMapper
from feast.dbt.parser import DbtManifestParser

# Parse manifest
click.echo(f"{Fore.CYAN}Parsing dbt manifest: {manifest_path}{Style.RESET_ALL}")
Expand Down Expand Up @@ -177,8 +177,8 @@ def import_command(
# Generate Feast objects
click.echo(f"\n{Fore.CYAN}Generating Feast objects...{Style.RESET_ALL}")

all_objects = []
entities_created = {}
all_objects: List[Any] = []
entities_created: Dict[str, Any] = {}

for model in models:
# Validate timestamp field exists
Expand All @@ -202,7 +202,7 @@ def import_command(
if entity_column not in entities_created:
entity = mapper.create_entity(
name=entity_column,
description=f"Entity key for dbt models",
description="Entity key for dbt models",
)
entities_created[entity_column] = entity
all_objects.append(entity)
Expand Down Expand Up @@ -274,7 +274,7 @@ def import_command(
click.echo(
f"\n{Fore.GREEN}✓ Generated Feast definitions: {output}{Style.RESET_ALL}"
)
click.echo(f" You can now import this file in your feature_store.yaml repo.")
click.echo(" You can now import this file in your feature_store.yaml repo.")
return

if dry_run:
Expand Down
4 changes: 2 additions & 2 deletions sdk/python/feast/dbt/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
... feature_view = mapper.create_feature_view(model, data_source, "driver_id")
"""

from feast.dbt.parser import DbtManifestParser, DbtModel, DbtColumn
from feast.dbt.mapper import DbtToFeastMapper
from feast.dbt.codegen import DbtCodeGenerator, generate_feast_code
from feast.dbt.mapper import DbtToFeastMapper
from feast.dbt.parser import DbtColumn, DbtManifestParser, DbtModel

__all__ = [
"DbtManifestParser",
Expand Down
7 changes: 3 additions & 4 deletions sdk/python/feast/dbt/codegen.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@

from typing import Any, List, Optional, Set

from jinja2 import Environment, BaseLoader
from jinja2 import BaseLoader, Environment

from feast.dbt.parser import DbtModel
from feast.dbt.mapper import map_dbt_type_to_feast_type
from feast.dbt.parser import DbtModel
from feast.types import (
Array,
Bool,
Expand All @@ -23,7 +23,6 @@
UnixTimestamp,
)


# Template for generating a complete Feast definitions file
FEAST_FILE_TEMPLATE = '''"""
Feast feature definitions generated from dbt models.
Expand Down Expand Up @@ -239,7 +238,7 @@ def generate(
"var_name": entity_var,
"name": entity_column,
"join_key": entity_column,
"description": f"Entity key for dbt models",
"description": "Entity key for dbt models",
"tags": {"source": "dbt"},
})

Expand Down
5 changes: 2 additions & 3 deletions sdk/python/feast/dbt/mapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,19 @@
from feast.entity import Entity
from feast.feature_view import FeatureView
from feast.field import Field
from feast.value_type import ValueType
from feast.types import (
Array,
Bool,
Bytes,
FeastType,
Float32,
Float64,
Int32,
Int64,
String,
UnixTimestamp,
FeastType,
)

from feast.value_type import ValueType

# Comprehensive mapping from dbt/warehouse types to Feast types
# Covers BigQuery, Snowflake, Redshift, PostgreSQL, and common SQL types
Expand Down
5 changes: 4 additions & 1 deletion sdk/python/feast/dbt/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
"""

import json
from dataclasses import dataclass, field
from enum import property
from pathlib import Path
from typing import Any, Dict, List, Optional
from dataclasses import dataclass, field


@dataclass
Expand Down Expand Up @@ -134,6 +134,9 @@ def get_models(
if self._raw_manifest is None:
self.parse()

if self._raw_manifest is None:
return []

models = []
nodes = self._raw_manifest.get("nodes", {})

Expand Down