Solved

Purchases.getProducts() not returning on Android

  • 30 April 2024
  • 2 replies
  • 53 views

Badge +1

On latest Expo and react-native-purchases, as far as I can tell everything’s still active and I had a purchase back in February so this used to work. Works fine on iOS

const productIds = Object.values(Constants.expoConfig.extra.products[Platform.OS]);

console.log('productIds', productIds); // Array of products output correctly

// No console.log() or console.error() gets fired
try {
const products = await Purchases.getProducts(productIds);
console.log('products', products); // Never outputs
setProducts(products);
} catch (error) {
console.error('Failed to get products', error);
Sentry.captureException(error);
}

 

icon

Best answer by ian-ccb416 4 May 2024, 18:03

View original

2 replies

Badge +2

Hey @ian-ccb416 ,

 

Thanks for reporting it!


It looks like there's an active GitHub issue where we're working through this issue - it's best to keep information in one spot, so let's continue working through the issue there.

Badge +1

For anyone else, still no update on what’s going on with getProducts(), but getOfferings() does work. Seems like getProducts() is just buggy

Reply