• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

astronomer / astro-cli / 39046451526
45%

Build:
DEFAULT BRANCH: main
Ran 17 Oct 2026 03:49PM UTC
Jobs 1
Files 218
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

17 Oct 2026 03:45PM UTC coverage: 45.055% (+0.01%) from 45.042%
39046451526

push

github

web-flow
fix(deploy): exit non-zero if uncommitted changes are present (#2004)

* fix(deploy: exit non-zero if uncommitted changes are present

* Refuse uncommitted changes without a usage block, in APC deploy too, with tests

- The refusal sets SilenceUsage before returning: it was set only after
  the check, so cobra printed the whole astro deploy usage under the
  error as if the command had been typed wrong.
- APC's astro deploy had the same print-and-exit-0, and now returns the
  error too; its message's "uncommmited" is spelled right.
- Both commands read the git state through hasUncommittedChanges, a
  variable as in v2's APC deploy, so a test does not depend on the
  checkout it runs in. The existing deploy tests that run without -f
  see a clean checkout; they would otherwise fail now in a dirty one.
- TestDeployRefusesUncommittedChanges, for each: without -f, the error,
  no deploy and no usage block; with -f, the deploy.

Co-Authored-By: Claude <noreply@anthropic.com>

* Refuse before --save, report conflicting flags first, and restore test stubs

From a code review of this PR:

- The refusal of uncommitted changes comes before --save, in cloud and
  APC alike: `astro deploy other-id --save` in a dirty checkout exited
  1 but still saved other-id as the default, so the next
  `astro deploy -f` went there.
- APC reports --dags with --image before the git state, so --force is
  never the first fix asked for a command that will not run either
  way. The conflict still prints no usage block, as before.
- The tests restore what they replace: the cloud test puts back
  hasUncommittedChanges, EnsureProjectDir and DeployImage and calls the
  os.Args restore it was discarding, and the APC suite resets
  EnsureProjectDir and DeployAirflowImage in SetupTest and
  TearDownSuite. Both now check that a refused --save saves nothing,
  and APC that a flag conflict is reported first.
  TestDeployReturnsErrorWhenSaveConfigFails, which runs without -f,
  sees a clean ... (continued)

14 of 15 new or added lines in 3 files covered. (93.33%)

27193 of 60355 relevant lines covered (45.06%)

9.81 hits per line

Uncovered Changes

Lines Coverage ∆ File
1
0.0
0.0% pkg/testing/testing.go
Jobs
ID Job ID Ran Files Coverage
1 39046451526.1 17 Oct 2026 03:49PM UTC 218
45.06
GitHub Action Run
Source Files on build 39046451526
  • Tree
  • List 218
  • Changed 3
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #39046451526
  • e74f8417 on github
  • Prev Build on main (#38993389548)
  • Next Build on main (#39047738235)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc