Skip to content

Fix clear targeting#415

Merged
protonate merged 2 commits intomasterfrom
fix_clear_targeting
Jun 16, 2016
Merged

Fix clear targeting#415
protonate merged 2 commits intomasterfrom
fix_clear_targeting

Conversation

@mkendall07
Copy link
Contributor

@matthewlane & @protonate to review

@protonate
Copy link
Collaborator

Looks good, thanks for the fix, reviewed.

@protonate protonate merged commit 4b14c3d into master Jun 16, 2016
@protonate protonate deleted the fix_clear_targeting branch June 16, 2016 22:56
@mkendall07 mkendall07 mentioned this pull request Jun 16, 2016
@nanek
Copy link
Contributor

nanek commented Jun 20, 2016

slot.clearTargeting(); is still being called, just at a different time. Due to the async nature of these calls how do you guarantee that targeting set by others is not lost?

Can you clarify the reason clearTargeting is required? Any reason not to only clear prebid specific keys?

@mkendall07
Copy link
Contributor Author

mkendall07 commented Jun 20, 2016

@nanek
The current implementation reads the current keys, stores them, clears the slot, and reapply the keys. This works because JS is single threaded and we are guaranteed atomicity within our function.

The reason we don't clear a single key? Google's API doesn't support it.

@aurelienjoneau
Copy link
Contributor

Hi @mkendall07
This new feature seems to break the targeting setting we use on our websites : when reapplying the keys, each value is reapplied to each ad slot. With version 0.10, every ad slot now has the targetting values of the last ad slot declared, after a lot of overwrite.
This will become a major problem for us with future versions of prebid, as we can't change our targetting implantation system.

  • is it possible to have a config option to keep the previous clearing system? something like pbjs.useLegacyClearTargetting ? Or do you see a fix for that problem ? thanks in advance

@dahjah
Copy link

dahjah commented Jul 26, 2016

I'm experiencing the same issue as aurelienjoneau. The targeting specific to the last tag in the array is applied to every tag. Perhaps there's an array traversing issue somewhere?

@mkendall07
Copy link
Contributor Author

@dahjah
This is resolved in 0.11.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants

Comments