astronomer / astro-cli

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

BUG: upgrade messing output in deployment files #1622

Closed chomipi88 closed 2 months ago

chomipi88 commented 3 months ago

Describe the bug

When inspecting a deployment and saving the output to a file, the CLI is including the upgrade message. With the included upgrade message, deployment updates using the deployment file error out.

A newer version of Astro CLI is available: 1.25.0
Please update to the latest version using 'brew upgrade astro'

If you don't want to see this message again run 'astro config set -g upgrade_message false'

When trying to update a deployment, the below error is returned:

Error: error converting YAML to JSON: yaml: line 5: could not find expected ':'

What CLI Version did you experience this bug? 1.24.1

This CLI bug is related to which Astronomer Platform?

What Operating System is the above CLI installed on? MAC

🪜 Steps To Reproduce

astro deployment inspect > depl.yaml

astro deployment update --deployment-file depl.yaml

📸 Screenshots

sunkickr commented 3 months ago

we need to make sure this message is not shown when a user is logged in with an API key or token. It would also be nice if this message was not shown when the --clean-output flag is used

kushalmalani commented 2 months ago

@chomipi88 I merged the PR with this fix. Fix will be released next week as part of 1.27.0