Skip to content

fix: Fix missing params being propagated to vast-resolving event#503

Merged
clementFrancon merged 1 commit intomasterfrom
fix-missing-vast-resolving-data
Mar 17, 2026
Merged

fix: Fix missing params being propagated to vast-resolving event#503
clementFrancon merged 1 commit intomasterfrom
fix-missing-vast-resolving-data

Conversation

@clementFrancon
Copy link
Copy Markdown
Contributor

Description

This pull request enhances the handling and testing of VAST wrapper ads by introducing additional parameters to the parsing logic and updating the related test cases. The main improvements focus on passing more context when parsing wrappers, which helps with debugging and data merging.

Enhancements to VAST wrapper parsing:

  • Added wrapperDepth, previousUrl, and wrapperAd parameters to the call to fetchVastXml in the VASTParser class to provide more context during wrapper parsing.

Test coverage improvements:

  • Updated test cases in spec/vast_parser.spec.js to expect the new parameters (wrapperDepth, previousUrl, wrapperAd) when verifying calls to fetchVastXml, ensuring tests accurately reflect the enhanced parsing logic. [1] [2]

@clementFrancon clementFrancon self-assigned this Mar 16, 2026
@dm-ad-sdk dm-ad-sdk Bot requested a review from ZacharieTFR March 16, 2026 11:34
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR improves VAST wrapper resolution telemetry by propagating additional wrapper context into the fetch layer (so VAST-resolving has richer debugging information) and aligns the unit tests with the updated fetch parameters.

Changes:

  • Pass wrapperDepth, previousUrl, and wrapperAd into fetchVAST during wrapper unwrapping.
  • Update spec/vast_parser.spec.js expectations to assert the new parameters are provided to fetchVAST.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
src/parser/vast_parser.js Propagates wrapper context (wrapperDepth, previousUrl, wrapperAd) to fetchVAST when resolving wrappers.
spec/vast_parser.spec.js Updates wrapper-resolution tests to expect the additional fetchVAST call parameters.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Comment thread src/parser/vast_parser.js
Comment on lines +401 to +403
wrapperDepth,
previousUrl,
wrapperAd: ad,
@clementFrancon clementFrancon merged commit 4591084 into master Mar 17, 2026
5 checks passed
@clementFrancon clementFrancon deleted the fix-missing-vast-resolving-data branch March 17, 2026 13:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

3 participants