-
Notifications
You must be signed in to change notification settings - Fork 1k
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 invalid characters for project, featureset, entity and features creation #976
Fix invalid characters for project, featureset, entity and features creation #976
Conversation
d4faf1e
to
07ffd6b
Compare
07ffd6b
to
e478d39
Compare
checkValidCharacters(featureSet.getSpec().getProject(), "project"); | ||
checkValidCharacters(featureSet.getSpec().getName(), "name"); | ||
checkValidCharacters(featureSet.getSpec().getProject(), "project::name"); | ||
checkValidCharacters(featureSet.getSpec().getName(), "featureset::name"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it make more sense to have a new argument like resource
and field
instead of ::
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added resource. I think it's clearer to show what they inputted as well, so I replaced field with the actual input itself in the error message.
/retest |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: pyalex, terryyylim The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/lgtm |
What this PR does / why we need it:
Currently - in names is being replaced to _. This is hacky solution that need to be implemented in many places. It also creates potential bug since project-1 and project_1 (feature-set and feature_set) will be using the same bq table.
It's better to validate this (and not allow such characters) on feature set creation. This PR addresses the above issue for project, featureset, features and entities.
Which issue(s) this PR fixes:
Fixes #
Does this PR introduce a user-facing change?: