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

Ad conversions fail after a creative has expired #10240

Closed
tmancey opened this issue Jun 12, 2020 · 1 comment · Fixed by brave/brave-core#5834
Closed

Ad conversions fail after a creative has expired #10240

tmancey opened this issue Jun 12, 2020 · 1 comment · Fixed by brave/brave-core#5834

Comments

@tmancey
Copy link
Contributor

tmancey commented Jun 12, 2020

Description

Steps to Reproduce

  1. View an ad (which has a conversion)
  2. Close the browser
  3. Remove the campaign from the catalog

Actual result:

Ad can no longer be converted when visiting the landing page

Expected result:

Ad should be converted when visiting the landing page

Reproduces how often:

Easily reproduced

Brave version (brave://version info)

Version/Channel Information:

  • Can you reproduce this issue with the current release? Yes
  • Can you reproduce this issue with the beta channel? Yes
  • Can you reproduce this issue with the dev channel? Yes
  • Can you reproduce this issue with the nightly channel? Yes

Other Additional Information:

  • Does the issue resolve itself when disabling Brave Shields? N/A
  • Does the issue resolve itself when disabling Brave Rewards? N/A
  • Is the issue reproducible on the latest version of Chrome? N/A

Miscellaneous Information:

@tmancey tmancey added bug priority/P1 A very extremely bad problem. We might push a hotfix for it. release-notes/include feature/ads OS/Desktop labels Jun 12, 2020
@tmancey tmancey self-assigned this Jun 12, 2020
@tmancey tmancey added the QA/Yes label Jun 12, 2020
@tmancey tmancey changed the title Ad conversions are lost after a creative expires Ad conversions fail after a creative has expired Jun 13, 2020
@tmancey tmancey added this to the 1.12.x - Nightly milestone Jun 14, 2020
@btlechowski
Copy link

btlechowski commented Jul 6, 2020

Verification passed on

Brave 1.11.89 Chromium: 83.0.4103.116 (Official Build) dev (64-bit)
Revision 8f0c18b4dca9b6699eb629be0f51810c24fb6428-refs/branch-heads/4103@{#716}
OS Ubuntu 18.04 LTS

Verified test plan below.

Removed from catalog

  1. Run Brave that points to ads staging server
  2. Load ad catalog on staging: 10240.txt
  3. Open brave.com and show the ad
  4. Close the browser
  5. Load catalog with removed campaign: 10240 empty.txt
  6. Run Brave
  7. Open https://www.interia.pl/ to trigger conversion

Verified that conversion was triggered:

[3800:3800:0706/152246.697681:VERBOSE1:ad_conversions.cc(135)] Ad conversion for creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 and postview
[3800:3800:0706/152246.700771:VERBOSE1:ad_conversions.cc(298)] Started ad conversion timer for creative instance id 36c84fcb-6388-45d8-81ed-5a5d986cd7ef and creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 which will trigger in 1 hour, 48 minutes, 21 seconds at 5:11 PM

Verified that conversion was finished.

[4779:4779:0706/174320.896212:VERBOSE1:ad_conversions.cc(258)] Successfully converted ad with creative instance id 36c84fcb-6388-45d8-81ed-5a5d986cd7ef and creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 in 0 hours, -32 minutes, -13 seconds at 5:11 PM
[4779:4779:0706/174320.897893:VERBOSE3:ads_impl.cc(1455)] Event log: {"data":{"type":"confirmation","timestamp":"0 hours, 0 minutes, 0 seconds at 5:43 PM","creativeInstanceId":"36c84fcb-6388-45d8-81ed-5a5d986cd7ef","confirmationType":"conversion"}}
[4779:4779:0706/174320.898020:VERBOSE3:ad_conversions.cc(306)] Saving ad conversions state
[4779:4779:0706/174320.898139:VERBOSE1:ad_conversions.cc(84)] Ad conversion queue is empty
[4779:4779:0706/174320.900565:VERBOSE1:confirmations_impl.cc(1179)] Confirm action:
  creativeInstanceId: 36c84fcb-6388-45d8-81ed-5a5d986cd7ef
  creativeSetId: de5a82e1-17d6-47e0-a368-17f8f56dfeb3
  confirmationType: conversion

Catalog expired
Trigger conversion when catalog expired, but conversion did not expire(expiry_timestamp in Default/ads_service/bundfle_state sqlite ad_conversions table)

  1. Run Brave that points to ads staging server
  2. Download catalog 10240 expire.txt](https://github.com/brave/brave-browser/files/4885111/10240.expire.txt)
  3. In the catalog change endAt to now()+2hours. This is catalog's expire date.
  4. Load the ad catalog
  5. Open brave.com and show the ad
  6. Close the browser
  7. Make the catalog expire
  8. Run Brave
  9. Open https://www.interia.pl/ to trigger conversion

Verified conversion was triggered:

[23124:23124:0707/230714.298323:VERBOSE1:ad_conversions.cc(298)] Started ad conversion timer for creative instance id 36c84fcb-6388-45d8-81ed-5a5d986cd7ef and creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 which will trigger in 6 hours, 7 minutes, 46 seconds at 5:15 AM

Conversion expired
Trigger conversion when catalog expired and conversion expired

  1. Run Brave that points to ads staging server
  2. Download catalog 10240 expire.txt](https://github.com/brave/brave-browser/files/4885111/10240.expire.txt)
  3. In the catalog change endAt to now()+4hours. the conversion's expire date will be endAt+24h
  4. Load the ad catalog
  5. Open brave.com and show the ad
  6. Close the browser
  7. Make the conversion expire
  8. Run Brave
  9. Open https://www.interia.pl/ to trigger conversion

Verified, it is impossible to convert the ad after it expired.

The entry in the database(Default/ads_service/bundfle_state sqlite ad_conversions) was not deleted:
image

Logged #10590


Verified passed with

Brave	1.11.90 Chromium: 83.0.4103.116 (Official Build) dev (64-bit)
Revision	8f0c18b4dca9b6699eb629be0f51810c24fb6428-refs/branch-heads/4103@{#716}
OS	macOS Version 10.14.6 (Build 18G3020)

Verified test plans from above.

Scenario 1 - Removed from catalog

  • ran steps as above

Verified that conversion was triggered:

[1531:775:0707/153201.222444:VERBOSE1:ad_conversions.cc(135)] Ad conversion for creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 and postview
[1531:775:0707/153201.222516:VERBOSE3:client.cc(580)] Saving client state
[1531:775:0707/153201.222599:VERBOSE3:ad_conversions.cc(306)] Saving ad conversions state
[1531:775:0707/153201.222803:VERBOSE1:ad_conversions.cc(298)] Started ad conversion timer for creative instance id 36c84fcb-6388-45d8-81ed-5a5d986cd7ef and creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 which will trigger in 0 hours, 2 minutes, 30 seconds at 3:34 PM

Verified that conversion was finished.

[1531:775:0707/153431.228713:VERBOSE1:ad_conversions.cc(258)] Successfully converted ad with creative instance id 36c84fcb-6388-45d8-81ed-5a5d986cd7ef and creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 in 0 hours, 0 minutes, 0 seconds at 3:34 PM
[1531:775:0707/153431.228901:VERBOSE3:ads_impl.cc(1455)] Event log: {"data":{"type":"confirmation","timestamp":"0 hours, 0 minutes, 0 seconds at 3:34 PM","creativeInstanceId":"36c84fcb-6388-45d8-81ed-5a5d986cd7ef","confirmationType":"conversion"}}
[1531:775:0707/153431.229051:VERBOSE3:ad_conversions.cc(306)] Saving ad conversions state
[1531:775:0707/153431.229157:VERBOSE1:ad_conversions.cc(84)] Ad conversion queue is empty
[1531:775:0707/153431.229241:VERBOSE1:confirmations_impl.cc(1179)] Confirm action:
  creativeInstanceId: 36c84fcb-6388-45d8-81ed-5a5d986cd7ef
  creativeSetId: de5a82e1-17d6-47e0-a368-17f8f56dfeb3
  confirmationType: conversion

Scenario 2 - Catalog expired
Trigger conversion when catalog expired, but conversion did not expire(expiry_timestamp in Default/ads_service/bundle_state sqlite ad_conversions table)

  • ran steps as above

Verified conversion was triggered:

[1700:775:0707/175528.215114:VERBOSE1:ad_conversions.cc(298)] Started ad conversion timer for creative instance id 36c84fcb-6388-45d8-81ed-5a5d986cd7ef and creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 which will trigger in 0 hours, 2 minutes, 39 seconds at 5:58 PM

Verified that conversion was finished

[1700:775:0707/175807.221392:VERBOSE1:ad_conversions.cc(258)] Successfully converted ad with creative instance id 36c84fcb-6388-45d8-81ed-5a5d986cd7ef and creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 in 0 hours, 0 minutes, 0 seconds at 5:58 PM
[1700:775:0707/175807.221614:VERBOSE3:ads_impl.cc(1455)] Event log: {"data":{"type":"confirmation","timestamp":"0 hours, 0 minutes, 0 seconds at 5:58 PM","creativeInstanceId":"36c84fcb-6388-45d8-81ed-5a5d986cd7ef","confirmationType":"conversion"}}
[1700:775:0707/175807.221763:VERBOSE3:ad_conversions.cc(306)] Saving ad conversions state
[1700:775:0707/175807.221852:VERBOSE1:ad_conversions.cc(84)] Ad conversion queue is empty
[1700:775:0707/175807.222018:VERBOSE1:confirmations_impl.cc(1179)] Confirm action:
  creativeInstanceId: 36c84fcb-6388-45d8-81ed-5a5d986cd7ef
  creativeSetId: de5a82e1-17d6-47e0-a368-17f8f56dfeb3
  confirmationType: conversion

Scenario 3 - Conversion expired
Trigger conversion when catalog expired and conversion expired

  • ran steps as above
  • Confirmed unable to convert the ad after it had expired.

The entry in the database(Default/ads_service/bundfle_state sqlite ad_conversions) was not deleted, encountered #10590:
Screen Shot 2020-07-08 at 8 14 36 PM

Verification passed on


Brave | 1.11.94 Chromium: 84.0.4147.85 (Official Build) (64-bit)
-- | --
Revision | e20c13e958edc3707db3d26d513780a7f6331a4b-refs/branch-heads/4147@{#837}
OS | Windows 10 OS Version 1903 (Build 18362.900)

Removed from catalog

  • Followed steps mentioned above
  • Verified that conversion was triggered and the conversion was finished.
[17984:2524:0713/200112.530:VERBOSE1:ad_conversions.cc(298)] Started ad conversion timer for creative instance id 36c84fcb-6388-45d8-81ed-5a5d986cd7ef and creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 which will trigger in 0 hours, 11 minutes, 45 seconds at 8:12 PM
[17984:2524:0713/201257.530:VERBOSE1:ad_conversions.cc(258)] Successfully converted ad with creative instance id 36c84fcb-6388-45d8-81ed-5a5d986cd7ef and creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 in 0 hours, 0 minutes, 0 seconds at 8:12 PM
[17984:2524:0713/201257.531:VERBOSE3:ads_impl.cc(1455)] Event log: {"data":{"type":"confirmation","timestamp":"0 hours, 0 minutes, 0 seconds at 8:12 PM","creativeInstanceId":"36c84fcb-6388-45d8-81ed-5a5d986cd7ef","confirmationType":"conversion"}}
[17984:2524:0713/201257.531:VERBOSE3:ad_conversions.cc(306)] Saving ad conversions state
[17984:2524:0713/201257.531:VERBOSE1:ad_conversions.cc(84)] Ad conversion queue is empty
[17984:2524:0713/201257.531:VERBOSE1:confirmations_impl.cc(1179)] Confirm action:
  creativeInstanceId: 36c84fcb-6388-45d8-81ed-5a5d986cd7ef
  creativeSetId: de5a82e1-17d6-47e0-a368-17f8f56dfeb3
  confirmationType: conversion

Catalog expired

  • Followed steps mentioned above
  • Verified conversion was triggered:
[13824:18244:0714/000409.035:VERBOSE1:ad_conversions.cc(298)] Started ad conversion timer for creative instance id 36c84fcb-6388-45d8-81ed-5a5d986cd7ef and creative set id de5a82e1-17d6-47e0-a368-17f8f56dfeb3 which will trigger in 2 hours, 56 minutes, 41 seconds at 3:00 AM

Conversion expired

Verified, it is impossible to convert the ad after it expired.

The entry in the database(Default/ads_service/bundfle_state sqlite ad_conversions) was not deleted:
image

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

Successfully merging a pull request may close this issue.

5 participants