New issue
Advanced search Search tips

Issue 739967 link

Starred by 3 users

Issue metadata

Status: WontFix
Owner:
Closed: Jan 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Chrome , Mac
Pri: 2
Type: Bug



Sign in to add a comment

[Budget-API] getBudget returns duplicate zero entries when current budget is 0

Project Member Reported by aluo@chromium.org, Jul 7 2017

Issue description

When current budget is 0, the getBudget will return 2 entries 4 days apart with 0 budgets.

Device:
Nexus 6P, MDB08O, Chrome Beta 60.0.3112.50

Steps:
1) Enable exp web plat features in chrome://flags
2) Visit aluochromium.github.io
3) Set site-engagement to 4 in chrome://site-engagement
4) In page, press "Get Current Budget", allow notifications.
5) Press "Spend Budget" until all budget is gone

Expected:
When budget is 0, getBudget should return 1 BudgetState with 0 budgetat.

Actual:
It is returning 2 with 0, presumably calculating an extra time due to the 4 day expiry.

I've also hit this:

40 at Thu Jul 06 2017 16:45:59 GMT-0700 (PDT)
0 at Mon Jul 10 2017 15:35:42 GMT-0700 (PDT)
-1 at Mon Jul 10 2017 16:45:59 GMT-0700 (PDT)

but have no idea how it got to this state, could be related to this duplicate entry problem though since it looks like an extra round of calculation was made even past 0 budget.
 

Comment 1 by aluo@chromium.org, Jul 7 2017

Components: Blink>PushAPI

Comment 2 by joh...@chromium.org, Jul 18 2017

Labels: -Pri-1 -M-60 Pri-2
Status: Available (was: Untriaged)
Slightly lowering priority since getBudget is only available behind an origin trial and these don't seem fatal, but it does sound like there are some bugs to fix here :-o

Comment 3 by peter@chromium.org, Jan 5 2018

Status: WontFix (was: Available)
We're planning to deprecate and remove the Budget API, so marking related bugs as WontFix.

Sign in to add a comment