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

Improve architecture of composing error messages for each validation error code #4071

Closed
westonruter opened this issue Jan 12, 2020 · 2 comments
Labels
Developer Tools Enhancement New feature or improvement of an existing one Groomed Validation WS:Core Work stream for Plugin core
Projects

Comments

@westonruter
Copy link
Member

westonruter commented Jan 12, 2020

Feature description

Add translatable error messages for each specific error code, removing the logic from \AMP_Validation_Error_Taxonomy::get_error_title_from_code() and into the respective sanitizer that originated the validation error. Improve structure of validation error to make it easier to construct messages. For example, harmonize node_attributes and element_attributes to just element_attributes.

So this is more of an architectural issue rather than providing just providing error message translations, which is already in progress. This involves adding validation error objects.

Related: #3664, #3780, #3817, #1420.


Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

Implementation brief

QA testing instructions

Demo

Changelog entry

@westonruter
Copy link
Member Author

This is going to naturally fall out from #1420.

@westonruter westonruter moved this from Backlog to To Do in Ongoing Feb 6, 2020
@westonruter westonruter changed the title Add translatable error messages for each error code Improve architecture of composing error messages for each validation error code Feb 6, 2020
@westonruter westonruter removed this from the v1.5 milestone Feb 18, 2020
@westonruter westonruter moved this from To Do to Backlog in Ongoing Feb 18, 2020
@amedina amedina added Developer Tools Enhancement New feature or improvement of an existing one Validation and removed Compatibility Tool labels Apr 1, 2020
@kmyram kmyram added the WS:Core Work stream for Plugin core label Aug 5, 2020
@kmyram kmyram added the Groomed label Nov 24, 2020
@westonruter
Copy link
Member Author

This makes sense to address as part of #3875 when extracting sanitization/validation logic to amp-toolbox-php.

@westonruter westonruter closed this as not planned Won't fix, can't repro, duplicate, stale Jul 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Developer Tools Enhancement New feature or improvement of an existing one Groomed Validation WS:Core Work stream for Plugin core
Projects
Ongoing
  
Backlog
Development

No branches or pull requests

3 participants