Make app, group, and tag descriptions requirable #350
+113
−61
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview of Changes
Descriptions are important for usability and auditability--let's let Access deployers make them required! This PR adds support for an environment variable
REQUIRE_DESCRIPTIONSwhich, if set toTrue, will make descriptions required when creating/editing apps, groups, and tags.Front end environment loading
I made another change (the second commit) to how Vite loads environment so that it will pull variables set in
.envfiles, but will still use the process env as the final source of truth. This was necessary to be able to test the frontend conditional form field requirements locally (or other config-based behavior like the web app name).Before: Only read from shell/system environment
Now: Read from both .env files AND shell environment, with shell taking precedence
Partial updates for apps, groups, and tags
To more consistently support Marshmallow's default loading without clearing properties omitted in a PUT request, I've updated the schema loading to apply partial updates.
Testing
With

REQUIRE_DESCRIPTIONS=True:With
REQUIRE_DESCRIPTIONS=Falseor omitting the variable altogether, the original behavior is preserved.