Skip to content

Comments

Add client registry validations when set via config#1969

Merged
neel-astro merged 2 commits intomainfrom
add-client-registry-validation
Oct 23, 2025
Merged

Add client registry validations when set via config#1969
neel-astro merged 2 commits intomainfrom
add-client-registry-validation

Conversation

@neel-astro
Copy link
Contributor

Description

Changes:

  • Add a generic concept of validation for CLI configs
  • Add validation for client registry config

🎟 Issue(s)

Inconsistent validation for client registry when set via astro dev init vs astro config set

🧪 Functional Testing

❯ ../astro config set remote.client_registry test
Error: invalid value for remote.client_registry: registry endpoint must be in format 'registry/repository' (e.g. quay.io/acme/my-deployment-image)
❯ ../astro dev init --remote-execution-enabled --remote-image-repository test
Error: unable to get registry endpoint: invalid registry endpoint format: registry endpoint must be in format 'registry/repository' (e.g. quay.io/acme/my-deployment-image)
❯ ../astro dev init --remote-execution-enabled
Enter the remote Docker repository for the client image (leave blank if not known but you will not be able to use the Astro CLI to deploy the client image until configured)
Remote client image repository endpoint (e.g. quay.io/acme/my-deployment-image): test
Error: unable to get registry endpoint: invalid registry endpoint format: registry endpoint must be in format 'registry/repository' (e.g. quay.io/acme/my-deployment-image)

📸 Screenshots

Add screenshots to illustrate the validity of these changes.

📋 Checklist

  • Rebased from the main (or release if patching) branch (before testing)
  • Ran make test before taking out of draft
  • Ran make lint before taking out of draft
  • Added/updated applicable tests
  • Tested against Astro-API (if necessary).
  • Tested against Houston-API and Astronomer (if necessary).
  • Communicated to/tagged owners of respective clients potentially impacted by these changes.
  • Updated any related documentation

@coveralls-official
Copy link

Pull Request Test Coverage Report for Build b2267f80-3cc9-4fef-9b89-51aa9dce2e88

Details

  • 34 of 41 (82.93%) changed or added relevant lines in 5 files are covered.
  • 2 unchanged lines in 1 file lost coverage.
  • Overall coverage increased (+0.01%) to 38.524%

Changes Missing Coverage Covered Lines Changed/Added Lines %
cmd/config.go 2 4 50.0%
config/types.go 7 12 58.33%
Files with Coverage Reduction New Missed Lines %
docker/docker.go 2 46.81%
Totals Coverage Status
Change from base Build b5ee00e2-48df-4673-8d27-6c8383bedbad: 0.01%
Covered Lines: 24151
Relevant Lines: 62691

💛 - Coveralls

@neel-astro neel-astro requested a review from a team October 23, 2025 10:02
Copy link
Contributor

@ianbuss ianbuss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks legit

@neel-astro neel-astro merged commit 2d99a42 into main Oct 23, 2025
8 checks passed
@neel-astro neel-astro deleted the add-client-registry-validation branch October 23, 2025 11:48
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

Successfully merging this pull request may close these issues.

2 participants