-
Notifications
You must be signed in to change notification settings - Fork 760
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
Bugfix: no bids from bidder handling #1252
Merged
SyntaxNode
merged 6 commits into
prebid:master
from
jmaynardxandr:bugfix_no_bids_handling
Apr 16, 2020
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
b3bf8b6
Bugfix: no bids from bidder handling
3b513cf
Fixed unit test json file: 2 bids where one bid returns nil
6e420cb
Fixed the case where we have http calls, but lose it it there are no …
b544eea
Added support of httpCalls to exchange test, added unit test to test …
319d530
Changed test file name
e070505
Minor refactoring
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
227 changes: 227 additions & 0 deletions
227
exchange/exchangetest/request-multi-bidders-debug-info.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,227 @@ | ||
{ | ||
"incomingRequest": { | ||
"ortbRequest": { | ||
"test": 1, | ||
"id": "some-request-id", | ||
"site": { | ||
"page": "test.somepage.com" | ||
}, | ||
"imp": [ | ||
{ | ||
"id": "my-imp-id", | ||
"video": { | ||
"mimes": [ | ||
"video/mp4" | ||
] | ||
}, | ||
"ext": { | ||
"appnexus": { | ||
"placementId": 1 | ||
}, | ||
"audienceNetwork": { | ||
"placementId": "some-placement" | ||
} | ||
} | ||
}, | ||
{ | ||
"id": "imp-id-2", | ||
"video": { | ||
"mimes": [ | ||
"video/mp4" | ||
] | ||
}, | ||
"ext": { | ||
"appnexus": { | ||
"placementId": 2 | ||
}, | ||
"audienceNetwork": { | ||
"placementId": "some-other-placement" | ||
} | ||
} | ||
} | ||
], | ||
"ext": { | ||
"prebid": { | ||
"targeting": { | ||
"durationRangeSec": [ | ||
15, | ||
30 | ||
], | ||
"includebrandcategory": { | ||
"primaryadserver": 1, | ||
"publisher": "", | ||
"withCategory": true, | ||
"translateCategories": true | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"outgoingRequests": { | ||
"appnexus": { | ||
"mockResponse": { | ||
"httpCalls": [ | ||
{ | ||
"uri": "appnexusTest.com", | ||
"requestbody": "appnexusTestRequestBody", | ||
"responsebody": "appnexusTestResponseBody", | ||
"status": 200 | ||
} | ||
], | ||
"pbsSeatBid": { | ||
"pbsBids": [ | ||
{ | ||
"ortbBid": { | ||
"id": "winning-bid", | ||
"impid": "my-imp-id", | ||
"price": 12.00, | ||
"w": 200, | ||
"h": 250, | ||
"crid": "creative-1", | ||
"cat": [ | ||
"IAB1-1" | ||
] | ||
} | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
"audienceNetwork": { | ||
"mockResponse": { | ||
"httpCalls": [ | ||
{ | ||
"uri": "audienceNetworkTest.com", | ||
"requestbody": "audienceNetworkTestRequestBody", | ||
"responsebody": "audienceNetworkTestResponseBody", | ||
"status": 200 | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
"response": { | ||
"bids": { | ||
"id": "some-request-id", | ||
"seatbid": [ | ||
{ | ||
"seat": "appnexus", | ||
"bid": [ | ||
{ | ||
"id": "winning-bid", | ||
"impid": "my-imp-id", | ||
"price": 12.00, | ||
"w": 200, | ||
"h": 250, | ||
"crid": "creative-1", | ||
"cat": [ | ||
"IAB1-1" | ||
], | ||
"ext": { | ||
"prebid": { | ||
"type": "", | ||
"targeting": { | ||
"hb_bidder": "appnexus", | ||
"hb_bidder_appnexus": "appnexus", | ||
"hb_cache_host": "www.pbcserver.com", | ||
"hb_cache_host_appnex": "www.pbcserver.com", | ||
"hb_cache_path": "/pbcache/endpoint", | ||
"hb_cache_path_appnex": "/pbcache/endpoint", | ||
"hb_size": "200x250", | ||
"hb_size_appnexus": "200x250", | ||
"hb_pb": "12.00", | ||
"hb_pb_appnexus": "12.00", | ||
"hb_pb_cat_dur": "12.00_VideoGames_15s", | ||
"hb_pb_cat_dur_appnex": "12.00_VideoGames_15s" | ||
} | ||
} | ||
} | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
"ext": { | ||
"debug": { | ||
"httpcalls": { | ||
"appnexus": [ | ||
{ | ||
"uri": "appnexusTest.com", | ||
"requestbody": "appnexusTestRequestBody", | ||
"responsebody": "appnexusTestResponseBody", | ||
"status": 200 | ||
} | ||
], | ||
"audienceNetwork": [ | ||
{ | ||
"uri": "audienceNetworkTest.com", | ||
"requestbody": "audienceNetworkTestRequestBody", | ||
"responsebody": "audienceNetworkTestResponseBody", | ||
"status": 200 | ||
} | ||
] | ||
}, | ||
"resolvedrequest": { | ||
"id": "some-request-id", | ||
"imp": [ | ||
{ | ||
"id": "my-imp-id", | ||
"video": { | ||
"mimes": [ | ||
"video/mp4" | ||
] | ||
}, | ||
"ext": { | ||
"appnexus": { | ||
"placementId": 1 | ||
}, | ||
"audienceNetwork": { | ||
"placementId": "some-placement" | ||
} | ||
} | ||
}, | ||
{ | ||
"id": "imp-id-2", | ||
"video": { | ||
"mimes": [ | ||
"video/mp4" | ||
] | ||
}, | ||
"ext": { | ||
"appnexus": { | ||
"placementId": 2 | ||
}, | ||
"audienceNetwork": { | ||
"placementId": "some-other-placement" | ||
} | ||
} | ||
} | ||
], | ||
"site": { | ||
"page": "test.somepage.com" | ||
}, | ||
"test": 1, | ||
"ext": { | ||
"prebid": { | ||
"targeting": { | ||
"durationRangeSec": [ | ||
15, | ||
30 | ||
], | ||
"includebrandcategory": { | ||
"primaryadserver": 1, | ||
"publisher": "", | ||
"withCategory": true, | ||
"translateCategories": true | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
|
||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
What are the consequences of removing the adapter bids entirely (do the metrics still record properly?) versus setting the bids to an empty slice?
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.
We don't want to carry bidder data if there are no bids back. For loops will skip empty array iterating and nothing bad will happen. This is just memory and processor time optimization. Hope this makes sense.