Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(dump+reset): Check if workspace exists #167

Merged
merged 1 commit into from Jun 8, 2020

Conversation

cwurm
Copy link
Contributor

@cwurm cwurm commented Jun 5, 2020

In dump and reset commands, checks if a specified workspace exists before trying to work with it. This makes sure the error message accurately reflects what the problem is.

E.g. right now:

$ deck dump -w Demo
Error: reading configuration from Kong: snis: Not found

After this PR:

$ deck dump -w Demo
Error: checking workspace 'Demo' in Kong: Not found

Uses the same code as is already in place for sync and diff.

Copy link
Member

@hbagdi hbagdi left a comment

Choose a reason for hiding this comment

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

We need to DRY some code out in cmd package to avoid such things from happening but that's another topic.
The error message that is thrown is incorrect but that should not be in scope for this PR. I've opened up #169 to track.

@hbagdi hbagdi merged commit 358248c into Kong:master Jun 8, 2020
@cwurm cwurm deleted the check_for_workspace branch June 9, 2020 16:00
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.

None yet

2 participants