You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After updating to dbt version: dbt=1.8.6, the dbt2looker script started to fail:
The error message I received was: ImportError: cannot import name 'PydanticValueError' from 'pydantic'
We are using dbt-core and dbt2looker==0.11.0.
I identified the issue being in the dbt2looker/models.py file where indeed an import is done of deprecated Pydantic functionality:
from pydantic import BaseModel, Field, PydanticValueError, validator. As far as I understand this is Pydantic V1 functionality which got deprecated by upgrading to Pydantic V2: here for example is stated that PydanticValueError is being deprecated.
I made already some changes in the dbt2looker/models.py to update it again to PydanticV2 compliant functionality - although not sure on the total impact - but by doing this I got the script running again.
Edit: apologies: I saw it was already filed once here.
However, just reverting Pydantic in our virtual env is not really an option since dbt-semantic-layer is also relying on Pydantic v2.
The text was updated successfully, but these errors were encountered:
PaddyAlton
added a commit
to PaddyAlton/dbt2looker
that referenced
this issue
Oct 7, 2024
Hey!
After updating to dbt version:
dbt=1.8.6
, the dbt2looker script started to fail:The error message I received was:
ImportError: cannot import name 'PydanticValueError' from 'pydantic'
We are using dbt-core and
dbt2looker==0.11.0
.I identified the issue being in the
dbt2looker/models.py
file where indeed an import is done of deprecated Pydantic functionality:from pydantic import BaseModel, Field, PydanticValueError, validator
. As far as I understand this is Pydantic V1 functionality which got deprecated by upgrading to Pydantic V2: here for example is stated that PydanticValueError is being deprecated.I made already some changes in the dbt2looker/models.py to update it again to PydanticV2 compliant functionality - although not sure on the total impact - but by doing this I got the script running again.
Edit: apologies: I saw it was already filed once here.
However, just reverting Pydantic in our virtual env is not really an option since dbt-semantic-layer is also relying on Pydantic v2.
The text was updated successfully, but these errors were encountered: