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

[BUG] 'str' object has no attribute 'get' with externalbrowser authentication #1249

Open
2 tasks done
javierpe27 opened this issue Nov 14, 2024 · 9 comments
Open
2 tasks done
Labels
bug Something isn't working

Comments

@javierpe27
Copy link

Is this a new bug in dbt-snowflake?

  • I believe this is a new bug in dbt-snowflake
  • I have searched the existing issues, and I could not find an existing issue for this bug

Current Behavior

Hello, I am facing an issue, all of a sudden i cannot run my dbt models on snowflake using dbt-snowflake 1.8.3 I keep getting this error. I first thought that the profiles file was the issue but i have been using the same profile for months so it cannot be, I use externalbrowser authentication with sso but it never gets to even open the browser, the profiles file is also being read from the right path when doing dbt debug any idea?

Dbt run:

16:41:59 Running with dbt=1.8.8

16:41:59 Registered adapter: snowflake=1.8.3

16:42:00 Unable to do partial parsing because profile has changed

16:42:02 Found 26 models, 1 seed, 10 sources, 749 macros

16:42:02

16:42:02

16:42:02 Finished running in 0 hours 0 minutes and 0.02 seconds (0.02s).

16:42:02 Encountered an error:

Runtime Error

Database error while listing schemas in database "T"

Database Error

'str' object has no attribute 'get'

Expected Behavior

Open the browser and login, however the browser is not being opened

Steps To Reproduce

OS: windows 10 with Wsl
dbt=1.8.8
adapter: snowflake=1.8.3
Python:3.10

Relevant log output

No response

Environment

- OS:
- Python:
- dbt-core:
- dbt-snowflake:

Additional Context

No response

@javierpe27 javierpe27 added bug Something isn't working triage labels Nov 14, 2024
@javierpe27 javierpe27 changed the title [BUG] [BUG] 'str' object has no attribute 'get' with externalbrowser authentication Nov 14, 2024
@amychen1776
Copy link

@javierpe27 did you make any code changes before this started to fail?

@javierpe27
Copy link
Author

javierpe27 commented Nov 19, 2024

Hi @amychen1776 No change, I pull the code directly from the repo and it works for my colleagues, so it seems it is a dbt specific error in my machine. I tried uninstalling and installing again but it didn't solve it.

@amychen1776
Copy link

@javierpe27 Could you try creating a new valid profiles.yml and pointing dbt to it? Just in case there is something related because your error message also calls out that the profiles.yml might have changed.

Also are you on the same version of Windows as your coworker?

@colin-rogers-dbt
Copy link
Contributor

@javierpe27 can you run the following command and share the output:
dbt debug --connection log-level debug

@michael-urrutia
Copy link

Have you tried upgrading to the latest version of dbt-snowflake, 1.8.4 to try and reproduce?

@AmiriMc
Copy link

AmiriMc commented Nov 21, 2024

Have you tried upgrading to the latest version of dbt-snowflake, 1.8.4 to try and reproduce?

Me and my co-worker are using 1.8.4 and we're having the same issue when trying to connect via SSO.

@javierpe27
Copy link
Author

Hi @michael-urrutia yes i just updated to 1.8.4 and i get the same error

@AmiriMc
Copy link

AmiriMc commented Nov 22, 2024

Hey @javierpe27, what version of WSL are you using? Can you post it for us?

My setup:

  • OS: WSL running in Windows 10
  • From dbt debug:
  • os info: Linux-5.15.167.4-microsoft-standard-WSL2-x86_64-with-glibc2.35
  • dbt version: 1.8.9
  • python version: 3.10.12
  • snowflake adapter version: 1.8.4

@javierpe27
Copy link
Author

Hi @colin-rogers-dbt
This is the output

08:29:46 Registered adapter: snowflake=1.8.3

08:29:46 Acquiring new snowflake connection 'debug'

08:29:46 Using snowflake connection "debug"

08:29:46 On debug: select 1 as id

08:29:46 Opening a new connection, currently in state init

08:29:46 Snowflake adapter: Error running SQL: select 1 as id

08:29:46 Snowflake adapter: Rolling back transaction.

08:29:46 On debug: No close available on handle

08:29:46 Connection test: [ERROR]

08:29:46 1 check failed:

08:29:46 dbt was unable to connect to the specified database.

The database returned the following error:

Database Error

'str' object has no attribute 'get'

Check your database credentials and try again. For more information, visit:

https://docs.getdbt.com/docs/configure-your-profile

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