astronomer / astro-cli

CLI that makes it easy to create, test and deploy Airflow DAGs to Astronomer
https://www.astronomer.io
Other
350 stars 70 forks source link

DEV - Deploying dags using cli gives workspace not found error #1671

Closed shri-astro closed 3 months ago

shri-astro commented 3 months ago

Describe the bug

Deploying dags using astro deploy --dags in dev environment issues the error that says "Workspace not found".

CLI command history:

shrividyahegde@Hegde test_dag % astro context list
 NAME                                        
 astronomer-dev.io                           
 astronomer.io                               
 astronomer-stage.io                         
shrividyahegde@Hegde test_dag % astro organization list
 NAME                                           ID                            
 Alerting E2E Test DEV                          clx3h3vm7006w01ny1vd89xy0     
 Test_Org_Shri                                  clx331wfr006801o0fyjn08gu     
 Astronomer                                     ckmzjm22937931d35puw3tcdo     
 Alert Migration Test Organization              clx0s7koz002z01t4on8p1xwc     
 test shri                                      clid7wipk006u01n7ec45yrlj     
 Test Hybrid                                    clwklzkp6009u01iw37912f2y     
 delete me pls                                  cls8jv7rv005n01nwea4m87p5     
 sreenu hosted organization                     clfy9065w001201lpfsxaivtv     
 Hybrid automation test organization            clriwfqkf004m01jqewm4uihh     
 QA-Shared                                      clfsyttup000701jrmwugi2u7     
 E2E_autumn-sound-clfc2nl47000228w336nckk1k     clfc2nlm9003n01j9r9d49yks     
shrividyahegde@Hegde test_dag % astro workspace list
 NAME     ID                            
 test     clx332o3a006101kbsbamjylu     
shrividyahegde@Hegde test_dag % astro deploy --dags
Authenticated to astronomer-dev.io 

Error: no Workspace with id (cl0cpgejc48581fy1je3pqv07) found

What CLI Version did you experience this bug? Astro CLI Version: 1.27.1

This CLI bug is related to which Astronomer Platform?

What Operating System is the above CLI installed on? Mac M1 Pro

🪜 Steps To Reproduce

shri-astro commented 3 months ago

Unable to reproduce this anymore.

shrividyahegde@Hegde ~ % vi ~/.astro/config.yaml
shrividyahegde@Hegde ~ % cd Documents 
shrividyahegde@Hegde Documents % cd test_dag 
shrividyahegde@Hegde test_dag % astro deploy --dags
Authenticated to astronomer-dev.io 

Current Workspace: test

Please specify a name for your Deployment

Deployment name: test

Please select a Region for your Deployment:
 #     REGION           
 1     us-central1      
 2     europe-west4     
 3     us-east4         

> 3
 NAME     NAMESPACE                    CLUSTER     CLOUD PROVIDER     REGION       DEPLOYMENT ID                 RUNTIME VERSION                     DAG DEPLOY ENABLED     CI-CD ENFORCEMENT     DEPLOYMENT TYPE     
 test     modem-constellation-3704     N/A         GCP                us-east4     clxz31krl003k01mkycfyr7ac     11.6.0 (based on Airflow 2.9.2)     true                   false                 STANDARD            

 Successfully created Deployment: test
 Deployment can be accessed at the following URLs 

 Deployment Dashboard: cloud.astronomer-dev.io/clx332o3a006101kbsbamjylu/deployments/clxz31krl003k01mkycfyr7ac/overview
 Airflow Dashboard: clx331wfr006801o0fyjn08gu.astronomer-dev.run/dcfyr7ac?orgId=org_SXUnLJwmzPkufRMI
Select which Deployment you want to update
 #     DEPLOYMENT NAME     RELEASE NAME                 DEPLOYMENT ID                 DAG DEPLOY ENABLED     
 1     test                modem-constellation-3704     clxz31krl003k01mkycfyr7ac     true                   

> 1
Initiating DAG deploy for: clxz31krl003k01mkycfyr7ac
Deployed DAG bundle:  2024-06-28T19:25:05.2920669Z
Deployed Image Tag:  11.6.0

Successfully uploaded DAGs with version 2024-06-28T19:25:05.2920669Z to Astro. Navigate to the Airflow UI to confirm that your deploy was successful. The Airflow UI takes about 1 minute to update.

 Access your Deployment:

 Deployment View: cloud.astronomer-dev.io/clx332o3a006101kbsbamjylu/deployments/clxz31krl003k01mkycfyr7ac/overview
 Airflow UI: clx331wfr006801o0fyjn08gu.astronomer-dev.run/dcfyr7ac?orgId=org_SXUnLJwmzPkufRMI

shrividyahegde@Hegde test_dag %