Cloning a Managed Repo to Local in order to use Cloud CLI

The problem I’m having

I’m trying to clone my dbt Cloud managed repo to my local machine, in order to run commands with the cloud CLI.

The context of why I’m trying to do this

I have written a Python model, but I can’t preview the model in the cloud IDE.
" Preview is not available for python models. We suggest that you execute dbt build -s python_model and preview the results by using select * from {{ ref('python_model') }} from a scratchpad instead."

Therefore, I am trying to clone my managed repo, and run dbt build locally.

What I’ve already tried

I’ve tried cloning with git clone git clone git@github.com:dbt-cloud-managed-repositories/dbt-cloud-PROJECT-ID-data-transformation.git

As expected, this doesn’t worked as I don’t have the SSH private key available.

Please can someone suggest how I am supposed to use the Cloud CLI, if I am using a managed repository.

It’s not possible to work on managed repos locally. As you’ve now levelled up and attempting to do things locally - I suggest just moving to your own repo on github or something. The time is now :blush:

Note: @Jeremy Yeo originally posted this reply in Slack. It might not have transferred perfectly.

Thanks a lot for your reply Jeremy!
Is there any way that I can do this stuff

dbt build -s python_model and preview the results by using select * from {{ ref('python_model') }} from a scratchpad instead.
While still using a managed repo? Basically I want to test out a python model before deploying it

Note: @isaacsultan1 originally posted this reply in Slack. It might not have transferred perfectly.

You can do that right in dbt cloud ide

Note: @Jeremy Yeo originally posted this reply in Slack. It might not have transferred perfectly.

No matter what you’re trying to do here - it is simply not possible to use a managed repo locally- no ifs no buts.

Note: @Jeremy Yeo originally posted this reply in Slack. It might not have transferred perfectly.