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

Error starting workbench #11

Closed
ghost opened this issue Jun 24, 2022 · 2 comments
Closed

Error starting workbench #11

ghost opened this issue Jun 24, 2022 · 2 comments

Comments

@ghost
Copy link

ghost commented Jun 24, 2022

Encountering below page output (and on CLI as well) when executing dbt-osmosis workbench -m unique_model_name. Seems it's getting a none value for a file path, but I'm not sure where or how exactly. This is my first run of dbt-osmosis workbench.

AttributeError: 'NoneType' object has no attribute 'patch_path'
Traceback:
File "C:\Users\myusername\AppData\Local\Programs\Python\Python310\lib\site-packages\streamlit\scriptrunner\script_runner.py", line 554, in _run_script
    exec(code, module.__dict__)
File "C:\Users\myusername\AppData\Local\Programs\Python\Python310\lib\site-packages\dbt_osmosis\app.py", line 345, in <module>
    Path(ctx.project_root) / ctx.get_patch_path(st.session_state[BASE_NODE]),
File "C:\Users\myusername\AppData\Local\Programs\Python\Python310\lib\site-packages\dbt_osmosis\core\osmosis.py", line 179, in get_patch_path
    return Path(node.patch_path.split(FILE_ADAPTER_POSTFIX)[-1])
@z3z1ma
Copy link
Owner

z3z1ma commented Jun 24, 2022

I noticed that too. The patch_path is not populated if you don't have a yaml file with the model in it.

I will release a hot fix for this in a few hours. In the meantime you can do a dbt-osmosis run command to automatically generate the file if you have added the dbt-osmosis: config key to your dbt_project.yml as documented in the readme. Thanks for the issue raise 🙏

@z3z1ma
Copy link
Owner

z3z1ma commented Jun 24, 2022

Issue fixed in last push/release. Available on github + pypi

@z3z1ma z3z1ma closed this as completed Jun 24, 2022
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

1 participant