-
Notifications
You must be signed in to change notification settings - Fork 0
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
Increase flexibility of ForageElement hierarchy #248
Increase flexibility of ForageElement hierarchy #248
Conversation
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. Join @devinmorgan and the rest of your teammates on Graphite |
forage-android/src/main/java/com/joinforage/forage/android/core/ui/element/ForagePanElement.kt
Dismissed
Show dismissed
Hide dismissed
forage-android/src/main/java/com/joinforage/forage/android/core/ui/element/ForagePanElement.kt
Dismissed
Show dismissed
Hide dismissed
forage-android/src/main/java/com/joinforage/forage/android/core/ui/element/ForagePanElement.kt
Dismissed
Show dismissed
Hide dismissed
forage-android/src/main/java/com/joinforage/forage/android/core/ui/element/ForagePinElement.kt
Dismissed
Show dismissed
Hide dismissed
forage-android/src/main/java/com/joinforage/forage/android/core/ui/element/ForagePinElement.kt
Dismissed
Show dismissed
Hide dismissed
forage-android/src/main/java/com/joinforage/forage/android/core/ui/element/ForagePinElement.kt
Dismissed
Show resolved
Hide resolved
6458699
to
1772e21
Compare
08b79c4
to
bc613e2
Compare
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.
Great stuff @devinmorgan ! Left a few comments. Open to discussing them sync/async!
forage-android/src/main/java/com/joinforage/forage/android/core/ForageSDKInterface.kt
Show resolved
Hide resolved
if (vaultResponse.isSuccess) return null | ||
val resRegExp = BtResponseRegExp(vaultResponse) | ||
return try { | ||
// TODO: add DD metric to track frequency of proxy errors |
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.
The caller captures proxy errors using the vault monitor/measurer [VaultProxyResponseMonitor]
. Can remove or update this comment to include the context from this comment
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.
Ah nice! OK I'll modify the comment to capture this. Thanks!
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.
Updated the comment!
...droid/src/main/java/com/joinforage/forage/android/ecom/services/vault/bt/BTResponseParser.kt
Show resolved
Hide resolved
...rc/main/java/com/joinforage/forage/android/ecom/services/vault/bt/BasisTheoryPinSubmitter.kt
Show resolved
Hide resolved
...droid/src/main/java/com/joinforage/forage/android/ecom/services/vault/bt/BtResponseRegExp.kt
Outdated
Show resolved
Hide resolved
...oid/src/main/java/com/joinforage/forage/android/ecom/services/vault/vgs/VGSResponseParser.kt
Show resolved
Hide resolved
forage-android/src/main/java/com/joinforage/forage/android/core/ui/element/ForagePinElement.kt
Outdated
Show resolved
Hide resolved
We want the private pos repo and the public ecom repo to have the ability to evolve separately accordingly their unique needs while still sharing common code. The first step in this journey is to make the public ecom repo completely unaware of the existence of the private pos repo. We do that by deleting all of the pos code Signed-off-by: Devin Morgan <[email protected]>
The second step in the public ecommerce repo that needs to take place in order to make sharing code between the private pos repo and this repo pain free; all while allowing for both repos to evolve independently Signed-off-by: Devin Morgan <[email protected]>
This is the third step in the public ecommerce repo that needs to take place in order to make sharing code between the private pos repo and this repo pain free; all while allowing for both repos to evolve independently. This hierarchy will make it easy to keep ecom things in the ecom-ForagePinEditText and pos things in the pos-ForagePINEditText Signed-off-by: Devin Morgan <[email protected]>
Previously `vaultToForageResponse` relied on generics to because VGS and BT responses differ. However, generics in Kotlin do not support the union ("|") types, which means that using generics will require the parent `AbstractVaultSubmitter` class to be aware of all classes that implement it. This is a problem because `AbstractVaultSubmitter` houses the common template for of submitting requests to vaults and ought to live in `/core`. But `/core` cannot be aware of any vault specific details if it is to be reusable by the pos repo. So, this commit, replaces the usage of generics with a common interface that all VaultSubmitter may _privately_ implement. The ability for VaultSubmitters to _privately_ implement the details by which they interpret vault response and ForageApiResponse.Success or ForageApiResponse.Failures makes it possible to move `AbstractVaultSubmitter` to `/core` and still house the common logic for submitting requests to vaults Signed-off-by: Devin Morgan <[email protected]>
Signed-off-by: Devin Morgan <[email protected]>
1772e21
to
ee43184
Compare
baf176a
to
09cfb94
Compare
Signed-off-by: Devin Morgan <[email protected]>
What
Step 3 of Part 1.. This is the top of the stack.
Why
See here
Test Plan
Demo
N/A - no new functionality
How
This PR is the top-of-the-stack is that will get merged into
main.
Once folks have approved the stack. I will change the base of this PR to point tomain
and merge that in. I then will close #246 and #247. See here for more detail.