pulumi/pkg/util/validation
Ian Wahbe ea7c3e4d5d Improve the stack validation error message
Previously, the error message was:

```
error: a stack name may only contain alphanumeric, hyphens, underscores, or periods
```

This wasn't great because it lacked specificity, but was especially bad if candidate stack
name was >100 characters or empty.

The new error messages are as follows:

1. If empty: "a stack name may not be empty"
2. If >100 chars: "a stack name cannot exceed 100 characters"
3. If it contains invalid characters: "a stack name may only contain alphanumeric,
   hyphens, underscores, or periods: invalid character %q at position %d" (with the
   appropriate values filled in).

Add tests

Add changelog

Fix lint

Respond to feedback
2023-06-28 00:48:19 +02:00
..
stack.go Improve the stack validation error message 2023-06-28 00:48:19 +02:00
stack_test.go Improve the stack validation error message 2023-06-28 00:48:19 +02:00