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

[client] Send warning event on missing required fields #307

Merged
merged 11 commits into from
Sep 26, 2019

Conversation

ZacharieTFR
Copy link
Contributor

@ZacharieTFR ZacharieTFR commented Sep 12, 2019

Description

Trigger a "VAST-warning" if any required attributes or subelements are missing in any element.
According to https://iabtechlab.com/wp-content/uploads/2018/11/VAST4.1-final-Nov-8-2018.pdf

Type

  • Breaking change
  • Enhancement
  • Fix
  • Documentation
  • Tooling

Copy link
Contributor

@kobawan kobawan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job! Let me know what you think about my comments :)

src/parser/ad_parser.js Outdated Show resolved Hide resolved
src/parser/creative_companion_parser.js Outdated Show resolved Hide resolved
src/parser/parser_utils.js Outdated Show resolved Hide resolved
src/parser/parser_utils.js Outdated Show resolved Hide resolved
src/parser/parser_utils.js Outdated Show resolved Hide resolved
src/parser/parser_utils.js Outdated Show resolved Hide resolved
src/util/requiredValues.js Outdated Show resolved Hide resolved
src/parser/creative_companion_parser.js Outdated Show resolved Hide resolved
src/parser/ad_parser.js Outdated Show resolved Hide resolved
src/parser/ad_parser.js Outdated Show resolved Hide resolved
src/parser/ad_parser.js Outdated Show resolved Hide resolved
src/parser/creative_companion_parser.js Outdated Show resolved Hide resolved
src/parser/creative_linear_parser.js Outdated Show resolved Hide resolved
src/util/requiredValues.js Outdated Show resolved Hide resolved
src/parser/parser_verification.js Show resolved Hide resolved
src/parser/parser_verification.js Outdated Show resolved Hide resolved
src/parser/parser_verification.js Outdated Show resolved Hide resolved
src/parser/parser_verification.js Outdated Show resolved Hide resolved
src/parser/ad_parser.js Outdated Show resolved Hide resolved
src/parser/ad_parser.js Show resolved Hide resolved
src/parser/ad_parser.js Outdated Show resolved Hide resolved
src/parser/ad_parser.js Outdated Show resolved Hide resolved
src/parser/parser_verification.js Outdated Show resolved Hide resolved
src/parser/parser_verification.js Outdated Show resolved Hide resolved
src/parser/parser_verification.js Outdated Show resolved Hide resolved
src/parser/parser_verification.js Outdated Show resolved Hide resolved
src/parser/parser_verification.js Show resolved Hide resolved
src/parser/ad_parser.js Outdated Show resolved Hide resolved
src/parser/parser_verification.js Outdated Show resolved Hide resolved
* @return {Ad}
*/
export function parseAd(adElement) {
export function parseAd(adElement, emit) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because of the new parameter this PR should be flagged as Breaking change as it changes api

spec/vast_verification.spec.js Outdated Show resolved Hide resolved
spec/vast_verification.spec.js Show resolved Hide resolved
spec/vast_verification.spec.js Show resolved Hide resolved
spec/vast_verification.spec.js Outdated Show resolved Hide resolved
src/parser/parser_verification.js Outdated Show resolved Hide resolved
Copy link
Contributor

@kobawan kobawan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 🎉
Lets wait for @rumesh to take a look as well before merging :)

@kobawan kobawan mentioned this pull request Sep 23, 2019
{ name, parentName, attributes, subElements, oneOfResources },
emit
) {
let message = `Element `;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be better to put the name here already and use else if, and else for the last statement, if we can only have one kind of error per message.

Copy link
Contributor

@clementFrancon clementFrancon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one smol comment otherwise it's all good for me ;)

@ZacharieTFR ZacharieTFR merged commit 1e1dbba into 3.0-version Sep 26, 2019
@ZacharieTFR ZacharieTFR deleted the vast-verification branch September 26, 2019 08:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

None yet

4 participants