-
Notifications
You must be signed in to change notification settings - Fork 886
Refactor (DRY) workspace TTL/Schedule validation logic #2119
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
Comments
Validation is complicated. I like to do it as close to the user as possible. To avoid repeating yourself typically means your validation is against rules sent from the server to the client, which works for many though not all cases (e.g. valid IDs or very complex data). I mention this because I'd like to make it possible to avoid at least some of the server round trips during data entry. |
The current validation was just the TTL duration to be within some constants iirc. |
Right, and with the current "all-in-one" approach we can just have the validation be a shared library. However, this means it's more important for folks to have a matching CLI <-> server version. |
Yeah I've done the shared library thing and would prefer to skip it altogether. It's a dead end. |
Gonna close this for now |
What
We currently duplicate some validations of workspace TTL / autostart schedule. We should refactor these and put them all in one place.
Originally posted by @Emyrk in #2018 (comment)
Why
Don't make me Repeat mYself.
The text was updated successfully, but these errors were encountered: