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: properties gets argument in a strange form with a curvy brace } at the end and fails #3

Closed
Gregory108 opened this issue Aug 5, 2021 · 7 comments

Comments

@Gregory108
Copy link

Gregory108 commented Aug 5, 2021

Execution of:
dbt-invoke properties --models model_name

Gives error:

Command: 'dbt run-operation --project-dir D:\Osome\Analytics\analytics_dbt _log_columns_list --
args '{"resource_name": "model_name"}''

Exit code: 2

...
dbt: error: unrecognized arguments: model_name}'

No idea, how to debug it!)

Setup:

  • Python 3.7.*
  • dbt 3.19.*
@Gregory108 Gregory108 changed the title Bug: Bug: properties gets argument in a strange form with a curvy brace } at the end and fails Aug 5, 2021
@robastel
Copy link
Member

robastel commented Aug 5, 2021

Thanks for reporting this @Gregory108. I'm looking into it. At first glance, I'm thinking the issue may stem from us not correctly handling Windows paths. I'll update here once I have more information.

@jcopr
Copy link

jcopr commented Aug 12, 2021

Hi,

Having the same problem. I found the problem at least but not sure of the solution:

dbt-invoke properties generates this:
dbt run-operation --project-dir C:\\Users\\my_user\\projects\\dbt _log_columns_list --args \'{"resource_name": "model_name_specified"}\'

when it should be this:

dbt run-operation --project-dir C:\\Users\\my_user\\projects\\dbt _log_columns_list --args '{"resource_name": "model_name_specified"}'

So for some reason the script generates those \ also around the args, hmmh...

Setup:

  • Python 3.8.10
  • dbt 0.20.0
  • Windows

@robastel
Copy link
Member

@jcopr thanks for posting that information! I also, simultaneously to you, narrowed it down to the quoting of the args. I see that you found the Pull Request #4 which is now merged. A new release has been created (dbt-invoke==0.1.1).

Are you (or @Gregory108) able to update to the latest version of dbt-invoke and confirm whether the changes alleviate this issue for you?

@jcopr
Copy link

jcopr commented Aug 12, 2021

I'll test tomorrow, will comment back here then. And thanks @robastel this seems like an excellent package, we have been using dbt now for 3 years or so 👍

@robastel
Copy link
Member

@jcopr I'm just checking in to see if you had a chance to test. If you are busy, no worries, I'll close for now and reopen the issue if it pops up again.

And thanks for the compliment!

@Gregory108
Copy link
Author

@robastel It works! Thank you so much!
This automation of properties update goes straight into my workflow now! (And, hopefully, my teammates as well!=)

@robastel
Copy link
Member

@Gregory108 Excellent, I'm glad to hear about the workflow! And thanks for confirming that it's working for you now.

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

3 participants