3.0.0-rc.10
0.59.9
Android
Buy subscription
Play Store error: DF-DFERH-01
Nexus 5X Android 8.1.0
Emulator x86 Android 9
I was having similar issue. Doc says you should call "requestSubscription" which was failing for me so just give requestPurchase a try with subscription SKU and it worked like a treat. Hope this help. Thanks
@sameerjain This isnβt a good idea since billingFlow will distinguish the sub or inapp.
DF-DFERH-01 error is matter of cache in android device. Please figure this out by solution and try again.
@hyochan Well, In that case I think there is a bug in the library itself. I tried all the solutions. I am working on this from last 3 days, well almost. At the end this is the only thing worked. I am really not sure how it works internally but if I look at the logcat it seems the flow is correct and I get correct json. Google billing also show this is a subscription with all correct info like billing period, trial period with localized price and warning that it will be recurring. As soon I use requestSubscription it show me that error again. I am attaching images for both api method
requestSubscription

requestPurchase

Hope this help in.
Thanks
I'm concerned that this may happen due to the migration of billing library in android from 1.x ==> 2.0.1.
Another question, have you guys fetched product by getSubscriptions(skus) instead getProducts?
@hyochan @sameerjain I didn't solve the DF-DFERH-01 error sadly π
I just solved the getSubscriptions part...
@hyochan I think @sameerjain is right, it works with requestPurchase and yes I used getSubscriptions(skus)
Ok. Let me go over this issue on the weekend.
For me both work fine and responses I am getting from both are correct. I get consumable in getProduct and subscription in getSubscription.
Sent from my iPhone
On 17-Jun-2019, at 11:11 PM, Hyo Chan Jang notifications@github.com wrote:
Another question have you guys fetched product by getSubscriptions(skus) instead getProducts?
β
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
@hyochan just one more thing - for me await RNIap.getAvailablePurchases(); doesn't seem to return anything anymore, it just stays there. I was using it to validate the receipt.
I think I can workaround using getPurchaseHistory but it's missing some data from the receipt.
Confirm the problem with 3.0.0.rc-10 on real device.
const itemSkus = [
'android.test.purchased',
'android.test.canceled',
'android.test.item_unavailable'
]
await RNIap.getProducts(itemSkus)
RNIap.requestPurchase('android.test.purchased')
Works perfect (except getAvailablePurchases freeze).
While
const itemSubs = [
'android.test.purchased',
'android.test.canceled',
'android.test.item_unavailable'
]
await RNIap.getSubscriptions(itemSubs)
RNIap.requestSubscription('android.test.purchased')
returns Error DF-DFERH-01. However, getSubscriptions returns an array of correct subscriptions (including static test subscriptions and subscriptions really existing in Play Console). But none of them work when calling requestSubscription.
RNIap.getAvailablePurchases() doesn't return anything at all (not even empty array, just freezes) in both cases.
@hyochan just one more thing - for me
await RNIap.getAvailablePurchases();doesn't seem to return anything anymore, it just stays there. I was using it to validate the receipt.
I think I can workaround usinggetPurchaseHistorybut it's missing some data from the receipt.
Sorry for this. This is resolved in 3.0.0-rc.12.
Let's focus on Error DF-DFERH-01 for now and I can't generate this in my env.
Please try 3.0.0-rc.13. I think this will fix the issue. Feel free to reopen when it doesn't.
@hyochan I will test in ~1h and report back β€οΈ
@hyochan did you upgrade to android X ? I have this now (just installed rc14)
Task :app:processDebugManifest FAILED
/Work/clients/current/emjoy/app/emjoy/android/app/src/debug/AndroidManifest.xml:22:18-91 Error:
Attribute application@appComponentFactory value=(android.support.v4.app.CoreComponentFactory) from [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91
is also present at [androidx.core:core:1.0.0] AndroidManifest.xml:22:18-86 value=(androidx.core.app.CoreComponentFactory).
Suggestion: add 'tools:replace="android:appComponentFactory"' to <application> element at AndroidManifest.xml:7:5-138 to override.
Ok, updated to RNIap to rc 14, updated RN to 0.59.9, some other module and managed to get over the androidX issue.
However there are 2 problems, is not compiling (I'll make a PR for that ) and then the DF-DFERH-01 is still there π
How can I get more logs for you? (I don't see anything in logcat)
@hyochan I can confirm that DF-DFERH-01 still exists in 3.0.0-rc.14 (with #535 update).
As I mentioned above - requestPurchase works correctly (after calling getProducts of course), but requestSubscription shows DF-DFERH-01 error (after calling getSubscriptions)
Sorry guys π₯I was rushing late at night so I couldn't be better. I've just released 3.0.0-rc.16 and I think this must fix DF-DFERH-01.
Please confirm this since I'm planning to release 3.0.0 this week.
@hyochan no need to be sorry, you are doing a great job β€οΈ
I ran a very quick test (is too early for me π
) and it seems that requestSubscription works this time.
Let me please run a more extensive test and I'll report during the day
Thanks a lot π€
Great job @hyochan
I finally got subscriptions ready to test
Most helpful comment
Ok. Let me go over this issue on the weekend.