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

[ADAP-1080] [Bug] Break in Dev build due to https://github.com/dbt-labs/dbt-core/pull/8906/files #874

Closed
2 tasks done
HRusby opened this issue Dec 26, 2023 · 1 comment

Comments

@HRusby
Copy link

HRusby commented Dec 26, 2023

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

In attempting to create a development environment to investigate #870
It appears that in dbt-labs/dbt-core#8906 many references have been moved around resulting in many imports of dbt-snowflake not being able to run.

I appreciate this is a bug with the bleeding edge of dbt-snowflake so apologies if this shouldn't be raised as a bug.

Expected Behavior

Running dbt debug should successfully connect to the configured Snowflake Environment

Steps To Reproduce

  1. On a fresh clone of Main
  2. Follow the Contributing Guide https://github.com/dbt-labs/dbt-snowflake/blob/main/CONTRIBUTING.md
  3. Create a new Dbt Profile (I verified mine against the latest versioned release)
  4. On Completion attempt to run dbt debug

Relevant log output

$ dbt debug
13:50:42  Running with dbt=1.8.0-a1
13:50:42  dbt version: 1.8.0-a1
13:50:42  python version: 3.11.5
13:50:42  python path: /home/usr/Development/dbt-snowflake/venv/bin/python
13:50:42  os info: Linux-6.6.1-arch1-1-x86_64-with-glibc2.38
13:50:42  Encountered an error:
No module named 'dbt.clients.agate_helper'
13:50:42  Traceback (most recent call last):
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/cli/requires.py", line 101, in wrapper
    result, success = func(*args, **kwargs)
                      ^^^^^^^^^^^^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/cli/requires.py", line 86, in wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/cli/main.py", line 445, in debug
    results = task.run()
              ^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/task/debug.py", line 126, in run
    load_profile_status: SubtaskStatus = self._load_profile()
                                         ^^^^^^^^^^^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/task/debug.py", line 217, in _load_profile
    profile: Profile = Profile.render(
                       ^^^^^^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/config/profile.py", line 440, in render
    return cls.from_raw_profiles(
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/config/profile.py", line 405, in from_raw_profiles
    return cls.from_raw_profile_info(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/config/profile.py", line 359, in from_raw_profile_info
    credentials: Credentials = cls._credentials_from_profile(
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/config/profile.py", line 169, in _credentials_from_profile
    cls = load_plugin(typename)
          ^^^^^^^^^^^^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/adapters/factory.py", line 214, in load_plugin
    return FACTORY.load_plugin(name)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/venv/lib/python3.11/site-packages/dbt/adapters/factory.py", line 60, in load_plugin
    mod: Any = import_module("." + name, "dbt.adapters")
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 940, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/home/usr/Development/dbt-snowflake/dbt/adapters/snowflake/__init__.py", line 2, in <module>
    from dbt.adapters.snowflake.connections import SnowflakeConnectionManager  # noqa
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/usr/Development/dbt-snowflake/dbt/adapters/snowflake/connections.py", line 14, in <module>
    import dbt.clients.agate_helper
ModuleNotFoundError: No module named 'dbt.clients.agate_helper'

Environment

- OS: Arch-Linux
- Python: 3.11.5
- dbt-core: 1.8.0-a1
- dbt-snowflake: HEAD of Main

Additional Context

No response

@HRusby HRusby added bug Something isn't working triage labels Dec 26, 2023
@github-actions github-actions bot changed the title [Bug] Break in Dev build due to https://github.com/dbt-labs/dbt-core/pull/8906/files [ADAP-1080] [Bug] Break in Dev build due to https://github.com/dbt-labs/dbt-core/pull/8906/files Dec 26, 2023
@McKnight-42 McKnight-42 removed bug Something isn't working triage labels Jan 16, 2024
@McKnight-42
Copy link
Contributor

McKnight-42 commented Jan 16, 2024

Hi, @HRusby thank you for raising this, and sorry for the inconvenience, it is as you say this is an issue with our bleeding edge case and this is in the works of being wrapped up snowflake corresponding pr is #865. there is a sub pr of this one as well and we hope to have this all in line again sometime this week I believe.

to be the most unblocked till its all in I would suggest possibly pointing to 1.7.latest as a branch as it should be in parity among core and the adapters. or if you need to stay on the most recent try using the linked pr as your base for dbt-snowflake.

I'm going to go ahead and close out this issue for now if you have anymore questions please feel free to continue the conversation on here.

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

No branches or pull requests

2 participants