Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dbt 1.6.14 breaks with ImportError: cannot import name 'read_user_config' from 'dbt.config' #5851

Closed
3 tasks done
anshjain18 opened this issue May 6, 2024 · 7 comments
Closed
3 tasks done
Labels
bug Something isn't working

Comments

@anshjain18
Copy link

Search before asking

  • I searched the issues and found no similar issues.

What Happened

Started getting the error
ImportError: cannot import name 'read_user_config' from 'dbt.config'
while running sqlfluff on the dbt project.
Important thing to note is: we haven't done any version upgrade in both dbt and sqlfluff.
Other similar issues have been reported in dbt 1.7X only while we are still using dbt 1.6X

Expected Behaviour

sqlfluff should work properly

Observed Behaviour

ImportError is being thrown

How to reproduce

Use the following versions:
dbt-core: 1.6.14
sqlfluff: 2.3.0
python: 3.11

Dialect

ansi

Version

sqlfluff-templater-dbt = 2.3.0
dbt = 1.6.14
python = 3.11

Configuration

NA

Are you willing to work on and submit a PR to address the issue?

  • Yes I am willing to submit a PR!

Code of Conduct

@anshjain18 anshjain18 added the bug Something isn't working label May 6, 2024
@kzajaczkowski
Copy link

I am experiencing exactly the same error with dbt-core in version 1.7.14. It seems the same breaking changes (from sqlfluff perspective) were released in both 1.6.14 and 1.7.14.

@yuriidudar
Copy link

I am experiencing the same issue with dbt-core in version 1.7.14
To resolve this you need temporarily roll back dbt-core to 1.7.13 version

@anshjain18
Copy link
Author

@greg-finley I think the issue is that the new version of sqlfluff where this bug is fixed hasn't been published yet.
The latest version, 3.0.5 was released 2 weeks ago which doesn't seem like it has the fix included

@kzajaczkowski
Copy link

kzajaczkowski commented May 6, 2024

Seems to be a dupe of #5841

@anshjain18
Copy link
Author

@kzajaczkowski Yes, but that issue was closed and I don't think the problem is resolved yet

@WittierDinosaur
Copy link
Contributor

This is resolved in main - closing as duplicate. I'll create a release candidate now, and we'll try to publish in the next 24 hours

@lydialimlh
Copy link

@anshjain18 Upgrading to v3.0.6 fixed the bug for me. Have a go at it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants