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

sizeConfig and multiformat #3894

Closed
jsnellbaker opened this issue Jun 10, 2019 · 3 comments
Closed

sizeConfig and multiformat #3894

jsnellbaker opened this issue Jun 10, 2019 · 3 comments
Labels

Comments

@jsnellbaker
Copy link
Collaborator

jsnellbaker commented Jun 10, 2019

Type of issue

Bug or Feature Request

Description

note - made some updates based on further review and testing out potential fixes

The sizeConfig logic is currently configured to allow bids of either a video or a native mediaType effectively a free-pass through its checks/filters. This makes sense to a degree, as these bid types don't generally rely on size dimensions being a key part the delivery decision and rendering process.

However, this logic has allowed certain issues to be possible that should be addressed in some manner. When a multi-format bid (eg banner + native) goes through the sizeConfig, the following could/does occur:

  • if the sizes of the banner were completely filtered out per the sizeConfig, the banner is still passed along as a valid mediaType in the bidRequest object while the sizes field is empty.
  • any labels on the adunit/bid are just flat out ignored. This results in bids/adUnits that should be excluded per the labels to be included in the bidRequest.

Per the current docs on the sizeConfig, it's not exactly clear what is meant to happen when using multi-format type bids. Neither is it clear that sizeConfig exempts video or native type requests. So this behavior is in a bit of a gray area since it falls between both sets of logic.

Proposed Fixes

Fix should adhere to the following points...

In the case of a multi-format bid that includes banner:

  • if the label check passes but the sizes are entirely filtered out > the request should drop the banner part of the request only (ie the native part would still go through)
  • Open Question if the label check fails - should we allow the other mediaType for that bid/adUnit to proceed into the request? Or should we reject the adUnit/bid entirely to prevent a partial bid?

I believe the latter option would lead to cleaner logic and avoid more edge scenarios; such as when different labels are set to different bids under the same bidder within the same adUnit.

In the case of a multi-format bid that doesn't include banner:

  • then the sizeConfig/label logic could be skipped

In the case of single format bids:

  • if the bid is a banner, the existing logic with the sizeConfig filtering/labels should be used
  • if the bid is either video or native, then the sizeConfig/label logic could be skipped as its done today; we should update the prebid.org docs to clarify this point better.

Sample configs


var adUnits = [
  {
    "code": "test_multi_banner_native",
    "mediaTypes": {
      "native": {
        "title": {
          "required": true,
          "len": 80
        }
      },
      "banner": {
        "sizes": [[300, 250], [300, 600]]
      }
    },
    "bids": [
      {
        "params": {
          "placementId": "111"
        },
        "labelAll": ["home", "desktop"],
        "bidder": "appnexus"
      }
    ]
  }
]

[
  {
    "mediaQuery": "(min-width: 1000px)",
    "sizesSupported": [[300, 250], [300, 600], [300, 900], [300, 1000], [300, 1050], [728, 90], [970, 90], [970, 250], [1000, 90], [1000, 200], [1000, 300], [1000, 350]],
    "labels": ["desktop"]
  },
  {
    "mediaQuery": "(min-width: 768px) and (max-width: 999px)",
    "sizesSupported": [[300, 250], [300, 600], [320, 50], [320, 100], [728, 90]],
    "labels": ["tablet"]
  },
  {
    "mediaQuery": "(min-width: 0px) and (max-width: 767px)",
    "sizesSupported": [[320, 50], [320, 100], [300, 250], [300, 100]],
    "labels": ["mobile"]
  }
]

Note - it was intended the home label wasn't defined in the sizeConfig. This came from a test where it was meant to show the labelAll logic working only when both labels were in use.

@jsnellbaker jsnellbaker added the pinned won't be closed by stalebot label Jun 10, 2019
@AntoineJac
Copy link
Contributor

@jsnellbaker , I have tested and confirmed the issue.
When using several mediaTypes with labelAll or LabelAny, the sizes will always be the intersection of banner.sizes and sizeConfig.sizesSupported. The label name and condition is not taking into account.

@bretg
Copy link
Collaborator

bretg commented Jun 17, 2019

Am ok with this feature @jsnellbaker . Thanks for expanding the requirements to make the feature work for multi-size.

if the label check fails - should we allow the other mediaType for that bid/adUnit to proceed into the request? Or should we reject the adUnit/bid entirely to prevent a partial bid?

I don't think we can change the behavior of the labels without becoming quite confusing. A label check failing means the adunit/bid is rejected.

Do you have cycles to update the prebid.org docs?

http://prebid.org/dev-docs/publisher-api-reference.html#setConfig-Configure-Responsive-Ads
http://prebid.org/dev-docs/show-multi-format-ads.html

@jsnellbaker
Copy link
Collaborator Author

Thanks for the feedback @bretg
I'll start putting the changes together, as well as the docs changes.

@jsnellbaker jsnellbaker added bug and removed pinned won't be closed by stalebot labels Jun 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants