Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(677)

Issue 2501593003: Implement the new basic card specification. (Closed)

Created:
4 years, 1 month ago by please use gerrit instead
Modified:
3 years, 11 months ago
CC:
Aaron Boodman, abarth-chromium, agrieve+watch_chromium.org, blink-reviews, chromium-reviews, darin (slow to review), qsr+mojo_chromium.org, rouslan+payments_chromium.org, sebsg+paymentswatch_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Implement the new basic card specification. The basic card specification has been updated to include card types (credit, debit, prepaid), which are distinct from card networks (amex, discover, mastercard, visa, etc). This patch adds support for the new format without removing support for the old format. Parsing of the JSON data that encodes the parameters happens in the renderer for safety. Old format (still supported): new PaymentRequest([{ supportedMethods: ['visa'] }], shoppingCartContents); New format (in this patch): new PaymentRequest([{ supportedMethods: ['basic-card'], data: { supportedNetworks: ['visa'], supportedTypes: ['debit'] } }], shoppingCartContents); Basic card spec: https://w3c.github.io/webpayments-methods-card/ Intent to implement and ship: https://groups.google.com/a/chromium.org/d/msg/blink-dev/IYRjdUKxCoM/8B-jp4g9AgAJ BUG=665190 Review-Url: https://codereview.chromium.org/2501593003 Cr-Commit-Position: refs/heads/master@{#442281} Committed: https://chromium.googlesource.com/chromium/src/+/b1be35c4c222d904ae02ea5c5dfdf1972d031f1e

Patch Set 1 #

Patch Set 2 : Rebase #

Total comments: 4

Patch Set 3 : Don't use TrackExceptionState #

Total comments: 4

Patch Set 4 : Address comments #

Patch Set 5 : Hide behind flag #

Total comments: 4

Patch Set 6 : Address review comments for Java #

Total comments: 1

Patch Set 7 : Rebase #

Patch Set 8 : Rebase #

Patch Set 9 : Rebase #

Patch Set 10 : Ignore exception when parsing method-specific data in renderer per issue discussion #

Patch Set 11 : Update the tests to ignore exception when parsing method-specific data in renderer per issue discus… #

Total comments: 2

Patch Set 12 : Parse basic-card method data even if Android Pay method data could not be parsed #

Patch Set 13 : Fix chrome_test_apk compile #

Patch Set 14 : Rebase #

Patch Set 15 : Rebase #

Patch Set 16 : Rebase #

Total comments: 3

Patch Set 17 : Rebase + comment #

Patch Set 18 : Remove last remaining DummyExceptionStateForTesting #

Patch Set 19 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+815 lines, -103 lines) Patch
M chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 5 chunks +85 lines, -24 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentInstrument.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 6 chunks +12 lines, -5 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/payments/CardEditor.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 6 chunks +50 lines, -10 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentApp.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestImpl.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +2 lines, -1 line 0 comments Download
M chrome/android/java_sources.gni View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +1 line, -0 lines 0 comments Download
A chrome/android/javatests/src/org/chromium/chrome/browser/payments/PaymentRequestBasicCardTest.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +166 lines, -0 lines 0 comments Download
A chrome/test/data/android/payments/basic_card.js View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +274 lines, -0 lines 0 comments Download
A chrome/test/data/android/payments/payment_request_basic_card_test.html View 1 chunk +26 lines, -0 lines 0 comments Download
M components/payments/payment_request.mojom View 1 2 3 4 5 6 7 8 3 chunks +43 lines, -23 lines 0 comments Download
M third_party/WebKit/LayoutTests/payments/payment-request-interface.html View 1 2 3 4 5 6 7 8 9 10 1 chunk +22 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/modules/modules_idl_files.gni View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 2 chunks +3 lines, -0 lines 0 comments Download
A third_party/WebKit/Source/modules/payments/BasicCardRequest.idl View 1 chunk +16 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/modules/payments/PaymentRequest.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 11 chunks +112 lines, -36 lines 0 comments Download
M third_party/WebKit/Source/platform/RuntimeEnabledFeatures.in View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +1 line, -0 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 150 (102 generated)
please use gerrit instead
Marijn, ptal WebKit. Does this change need an intent to ship on blink-dev. I'm thinking ...
4 years, 1 month ago (2016-11-18 19:44:16 UTC) #22
please use gerrit instead
Elliott, ptal third_party/WebKit/Source/modules/modules_idl_files.gni
4 years, 1 month ago (2016-11-18 19:46:08 UTC) #24
Tom Sepez
mojom LGTM
4 years, 1 month ago (2016-11-18 19:54:25 UTC) #26
gone
Is there any way to make break this patch up?
4 years, 1 month ago (2016-11-18 20:05:26 UTC) #27
please use gerrit instead
On 2016/11/18 20:05:26, dfalcantara (check my queue) wrote: > Is there any way to make ...
4 years, 1 month ago (2016-11-18 20:06:35 UTC) #28
please use gerrit instead
Breaking up in process. Please stand by for a rebase on top of other parts. ...
4 years, 1 month ago (2016-11-18 21:06:05 UTC) #29
please use gerrit instead
Dan, ptal patch 2. I've split out and separately landed several parts of this CL: ...
4 years, 1 month ago (2016-11-22 00:37:17 UTC) #33
please use gerrit instead
On 2016/11/22 00:37:17, rouslan wrote: > Dan, ptal patch 2. I've split out and separately ...
4 years, 1 month ago (2016-11-22 00:37:45 UTC) #34
please use gerrit instead
On 2016/11/22 00:37:45, rouslan wrote: > landed and reviewed. Not in that order.
4 years, 1 month ago (2016-11-22 00:38:04 UTC) #35
haraken
https://codereview.chromium.org/2501593003/diff/150001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): https://codereview.chromium.org/2501593003/diff/150001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode453 third_party/WebKit/Source/modules/payments/PaymentRequest.cpp:453: TrackExceptionState exceptionState; It looks strange to use TrackExceptionState in ...
4 years, 1 month ago (2016-11-22 01:18:59 UTC) #37
please use gerrit instead
https://codereview.chromium.org/2501593003/diff/150001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): https://codereview.chromium.org/2501593003/diff/150001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode453 third_party/WebKit/Source/modules/payments/PaymentRequest.cpp:453: TrackExceptionState exceptionState; On 2016/11/22 01:18:59, haraken wrote: > > ...
4 years, 1 month ago (2016-11-22 03:10:55 UTC) #38
haraken
https://codereview.chromium.org/2501593003/diff/150001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): https://codereview.chromium.org/2501593003/diff/150001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode453 third_party/WebKit/Source/modules/payments/PaymentRequest.cpp:453: TrackExceptionState exceptionState; On 2016/11/22 03:10:55, rouslan wrote: > On ...
4 years, 1 month ago (2016-11-22 04:26:03 UTC) #39
please use gerrit instead
ptal patch 3 https://codereview.chromium.org/2501593003/diff/150001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): https://codereview.chromium.org/2501593003/diff/150001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode453 third_party/WebKit/Source/modules/payments/PaymentRequest.cpp:453: TrackExceptionState exceptionState; Done. I'm deferring to ...
4 years ago (2016-11-22 15:20:03 UTC) #42
haraken
LGTM On 2016/11/22 15:20:03, rouslan wrote: > ptal patch 3 > > https://codereview.chromium.org/2501593003/diff/150001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp > File ...
4 years ago (2016-11-22 15:24:24 UTC) #43
esprehn
Why do you want to ignore this exceptions? That's very unusual and sounds like a ...
4 years ago (2016-11-22 20:34:58 UTC) #46
please use gerrit instead
On 2016/11/22 20:34:58, esprehn wrote: > Why do you want to ignore this exceptions? That's ...
4 years ago (2016-11-22 20:52:54 UTC) #47
gone
https://codereview.chromium.org/2501593003/diff/170001/chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java File chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java (right): https://codereview.chromium.org/2501593003/diff/170001/chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java#newcode110 chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java:110: types.add(BasicCardType.CREDIT); Are you basically making sure that supportedTypes has ...
4 years ago (2016-11-22 21:28:48 UTC) #48
esprehn
On 2016/11/22 at 20:52:54, rouslan wrote: > On 2016/11/22 20:34:58, esprehn wrote: > > Why ...
4 years ago (2016-11-22 21:42:46 UTC) #49
Rick Byers
On 2016/11/22 21:42:46, esprehn wrote: > On 2016/11/22 at 20:52:54, rouslan wrote: > > On ...
4 years ago (2016-11-22 22:35:17 UTC) #50
haraken
On 2016/11/22 22:35:17, Rick Byers wrote: > On 2016/11/22 21:42:46, esprehn wrote: > > On ...
4 years ago (2016-11-22 23:31:59 UTC) #51
esprehn
On 2016/11/22 at 23:31:59, haraken wrote: > ... > > So IMHO this is not ...
4 years ago (2016-11-22 23:46:32 UTC) #52
please use gerrit instead
It's stable on Android and experimental on all other platforms.
4 years ago (2016-11-22 23:47:41 UTC) #53
please use gerrit instead
Intent to ship sent out: https://groups.google.com/a/chromium.org/d/msg/blink-dev/IYRjdUKxCoM/8B-jp4g9AgAJ We can continue reviewing while waiting for approval. Worst ...
4 years ago (2016-11-23 01:01:42 UTC) #54
please use gerrit instead
Elliot, ptal patch 4. I've found a compromise: throw an exception only if "basic-card" is ...
4 years ago (2016-11-23 01:12:00 UTC) #58
please use gerrit instead
On 2016/11/23 01:12:00, rouslan wrote: > Throw an exception only if > "basic-card" is the ...
4 years ago (2016-11-23 14:32:41 UTC) #61
Rick Byers
On 2016/11/23 01:01:42, rouslan wrote: > Intent to ship sent out: > > https://groups.google.com/a/chromium.org/d/msg/blink-dev/IYRjdUKxCoM/8B-jp4g9AgAJ > ...
4 years ago (2016-11-23 14:33:55 UTC) #62
Rick Byers
On 2016/11/22 23:31:59, haraken wrote: > On 2016/11/22 22:35:17, Rick Byers wrote: > > On ...
4 years ago (2016-11-23 14:37:37 UTC) #63
please use gerrit instead
PTAL patch 5. Rick: I've placed the feature behind a runtime flag, so it should ...
4 years ago (2016-11-28 18:58:11 UTC) #72
gone
Java bits lgtm https://codereview.chromium.org/2501593003/diff/230001/chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java File chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java (right): https://codereview.chromium.org/2501593003/diff/230001/chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java#newcode48 chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java:48: public void getInstruments(Map<String, PaymentMethodData> methodData, nit: ...
4 years ago (2016-11-28 21:58:30 UTC) #73
please use gerrit instead
https://codereview.chromium.org/2501593003/diff/230001/chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java File chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java (right): https://codereview.chromium.org/2501593003/diff/230001/chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java#newcode48 chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentApp.java:48: public void getInstruments(Map<String, PaymentMethodData> methodData, On 2016/11/28 21:58:29, dfalcantara ...
4 years ago (2016-11-28 22:29:45 UTC) #78
Marijn Kruisselbrink
https://codereview.chromium.org/2501593003/diff/250001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): https://codereview.chromium.org/2501593003/diff/250001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode545 third_party/WebKit/Source/modules/payments/PaymentRequest.cpp:545: if (exceptionState.hadException()) So after this change the PaymentRequest constructor ...
4 years ago (2016-11-29 21:09:53 UTC) #82
please use gerrit instead
On 2016/11/29 21:09:53, Marijn Kruisselbrink wrote: > https://codereview.chromium.org/2501593003/diff/250001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp > File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): > > https://codereview.chromium.org/2501593003/diff/250001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode545 ...
4 years ago (2016-11-29 21:43:56 UTC) #83
please use gerrit instead
On 2016/11/29 21:43:56, rouslan-intermittent-holidays wrote: > I've opened https://github.com/w3c/webpayments-methods-card/issues/20 to seek > opinions from the ...
3 years, 12 months ago (2016-12-22 20:40:09 UTC) #92
Rick Byers
On 2016/11/28 18:58:11, rouslan-intermittent-holidays wrote: > PTAL patch 5. > > Rick: I've placed the ...
3 years, 12 months ago (2016-12-22 20:51:30 UTC) #93
please use gerrit instead
Elliot and Marijn: PTAL patch 10. I'm not rethrowing exception state when parsing method-specific data ...
3 years, 12 months ago (2016-12-22 21:11:01 UTC) #98
Marijn Kruisselbrink
https://codereview.chromium.org/2501593003/diff/350001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): https://codereview.chromium.org/2501593003/diff/350001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode393 third_party/WebKit/Source/modules/payments/PaymentRequest.cpp:393: return; is return here really the right thing? I'm ...
3 years, 12 months ago (2016-12-22 21:58:20 UTC) #103
please use gerrit instead
https://codereview.chromium.org/2501593003/diff/350001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): https://codereview.chromium.org/2501593003/diff/350001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode393 third_party/WebKit/Source/modules/payments/PaymentRequest.cpp:393: return; On 2016/12/22 21:58:20, Marijn Kruisselbrink wrote: > is ...
3 years, 12 months ago (2016-12-22 22:56:08 UTC) #108
please use gerrit instead
Marijn & Elliot, ptal patch 16.
3 years, 11 months ago (2017-01-05 19:50:30 UTC) #127
Marijn Kruisselbrink
lgtm https://codereview.chromium.org/2501593003/diff/450001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): https://codereview.chromium.org/2501593003/diff/450001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode391 third_party/WebKit/Source/modules/payments/PaymentRequest.cpp:391: if (exceptionState.hadException()) I recently came across Source/bindings/core/v8/ExceptionStatePlaceholder.h which ...
3 years, 11 months ago (2017-01-05 22:38:03 UTC) #128
haraken
https://codereview.chromium.org/2501593003/diff/450001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): https://codereview.chromium.org/2501593003/diff/450001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode391 third_party/WebKit/Source/modules/payments/PaymentRequest.cpp:391: if (exceptionState.hadException()) On 2017/01/05 22:38:03, Marijn Kruisselbrink wrote: > ...
3 years, 11 months ago (2017-01-06 00:04:17 UTC) #129
Marijn Kruisselbrink
https://codereview.chromium.org/2501593003/diff/450001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): https://codereview.chromium.org/2501593003/diff/450001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode391 third_party/WebKit/Source/modules/payments/PaymentRequest.cpp:391: if (exceptionState.hadException()) On 2017/01/06 at 00:04:17, haraken wrote: > ...
3 years, 11 months ago (2017-01-06 00:16:07 UTC) #130
haraken
On 2017/01/06 00:16:07, Marijn Kruisselbrink wrote: > https://codereview.chromium.org/2501593003/diff/450001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp > File third_party/WebKit/Source/modules/payments/PaymentRequest.cpp (right): > > https://codereview.chromium.org/2501593003/diff/450001/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp#newcode391 ...
3 years, 11 months ago (2017-01-06 00:38:08 UTC) #131
haraken
LGTM % adding a comment why you want to clear the exception.
3 years, 11 months ago (2017-01-06 00:39:06 UTC) #132
please use gerrit instead
Added a comment about the reason for clearing an exception and removed the last remaining ...
3 years, 11 months ago (2017-01-06 18:28:30 UTC) #138
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2501593003/490001
3 years, 11 months ago (2017-01-06 18:37:29 UTC) #142
commit-bot: I haz the power
Failed to apply patch for chrome/android/java/src/org/chromium/chrome/browser/payments/CardEditor.java: While running git apply --index -p1; error: patch failed: ...
3 years, 11 months ago (2017-01-06 20:52:39 UTC) #144
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2501593003/510001
3 years, 11 months ago (2017-01-09 15:26:02 UTC) #147
commit-bot: I haz the power
3 years, 11 months ago (2017-01-09 17:23:13 UTC) #150
Message was sent while issue was closed.
Committed patchset #19 (id:510001) as
https://chromium.googlesource.com/chromium/src/+/b1be35c4c222d904ae02ea5c5dfd...

Powered by Google App Engine
This is Rietveld 408576698