-
Notifications
You must be signed in to change notification settings - Fork 2.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
PBjs Core : fix creation of per-bidder syncOptions #12615
Conversation
Update master branch of grupawp/Prebid.js
Update tests for sspBC adapter: - change userSync test (due to tcf param appended in v4.6) - add tests for onBidWon and onTimeout
Update master branch of grupawp/Prebid.js
Update remote repo
Update grupawp fork
Update remote repository
Update remote repository
Update remote repository
Update remote repository
… matching response to request)
… to banner creative
…esent in bid response
Update grupawp fork
Update fork grupawp
Update remote repository
Update remote fork
Update grupawp fork
Update remote fork
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.
Thank you!
I pushed an updated version of this to https://github.com/prebid/Prebid.js/tree/fix-syncoptions, but I don't think I have the right permissions to update this PR. It fixes the failing tests (that incidentally, were already broken before this change) and adds some new cases for this bug.
src/adapters/bidderFactory.js
Outdated
let syncs = spec.getUserSyncs({ | ||
iframeEnabled: !!(filterConfig && (filterConfig.iframe || filterConfig.all)), | ||
pixelEnabled: !!(filterConfig && (filterConfig.image || filterConfig.all)), | ||
iframeEnabled: isActivityAllowed(ACTIVITY_SYNC_USER, activityParams(MODULE_TYPE_BIDDER, spec.code, { syncType: 'iframe' })), |
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.
this would log a warning when denied, but the bidder is not necessarily trying to use the wrong type of sync - we are just telling them whether image or iframes are allowed. Internally the activity is checked using canBidderRegisterSync
, which on its own does not generate warnings.
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.
HI @dgirardi - I'll update source branch (https://github.com/grupawp/Prebid.js/tree/fix-syncoptions) with Your changes
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.
Aaaand done - could You take a look?
EDIT:
I have also updated https://bdr.wpcdn.pl/tests/usersyncs/sspbc-6.10-mixed_sync_3.html
& https://bdr.wpcdn.pl/tests/usersyncs/sspbc-6.10-mixed_sync_4.html test with the new version of Prebid.js and as You've said - Activity control warnings that were being generated by registerSyncInner are now gone.
Update grupawp fork with changes made by @dgirardi
* Update tests for sspBC adapter Update tests for sspBC adapter: - change userSync test (due to tcf param appended in v4.6) - add tests for onBidWon and onTimeout * [sspbc-adapter] 5.3 updates: content-type for notifications * [sspbc-adapter] pass CTA to native bid * [sspbc-5.3] keep pbsize for detected adunits * [maintenance] - remove old test for sspBc bid adaptor * [sspbc-5.3] increment adaptor ver * [sspbc-adapter] maintenance update to sspBCBidAdapter * remove yarn.lock * Delete package-lock.json * remove package-lock.jsonfrom pull request * [sspbc-adapter] send pageViewId in request * [sspbc-adapter] update pageViewId test * [sspbc-adapter] add viewabiility tracker to native ads * [sspbc-adapter] add support for bid.admNative property * [sspbc-adapter] ensure that placement id length is always 3 (improves matching response to request) * [sspbc-adapter] read publisher id and custom ad label, then send them to banner creative * [sspbc-adapter] adlabel and pubid are set as empty strings, if not present in bid response * [sspbc-adapter] jstracker data fix * [sspbc-adapter] jstracker data fix * [sspbc-adapter] send tagid in notifications * [sspbc-adapter] add gvlid to spec; prepare getUserSyncs for iframe + image sync * update remote repo * cleanup of grupawp/prebid master branch * update sspBC adapter to v 5.9 * update tests for sspBC bid adapter * [sspbc-adapter] add support for topicsFPD module * [sspbc-adapter] change topic segment ids to int * sspbc adapter -> update to v6 * bugfix proposal - using isActivityAllowed to build per-bidder syncOptions * Fix preexisting tests * Use canBidderRegisterSync --------- Co-authored-by: Wojciech Biały <[email protected]> Co-authored-by: decemberWP <[email protected]> Co-authored-by: Demetrio Girardi <[email protected]>
Type of change
Description of change
This PR relates to issue #12613 and alters the way syncOptions are sent to bidder by registerSyncInner method.
Instead of checking filterConfig properties, ACTIVITY_SYNC_USER is checked for each bidder, and for both sync types (iframe and image). This are the same permissions that are later verified by the publicApi.registerSync method.