From 78b8bef62518a8209644ef1bb5567bc1572a61f5 Mon Sep 17 00:00:00 2001 From: Ishaq Hassan Date: Mon, 4 May 2026 19:58:18 +0000 Subject: [PATCH 1/2] [in_app_purchase] Fix broken dartdoc references in completePurchase --- .../in_app_purchase/in_app_purchase/CHANGELOG.md | 3 +++ .../in_app_purchase/lib/in_app_purchase.dart | 14 +++++++------- .../CHANGELOG.md | 3 +++ .../lib/src/in_app_purchase_platform.dart | 15 ++++++++------- 4 files changed, 21 insertions(+), 14 deletions(-) diff --git a/packages/in_app_purchase/in_app_purchase/CHANGELOG.md b/packages/in_app_purchase/in_app_purchase/CHANGELOG.md index 08bebbb568d7..715bab19e7df 100644 --- a/packages/in_app_purchase/in_app_purchase/CHANGELOG.md +++ b/packages/in_app_purchase/in_app_purchase/CHANGELOG.md @@ -1,5 +1,8 @@ ## NEXT +* Fixes broken dartdoc references in `completePurchase` to point to + `InAppPurchaseException` and `InAppPurchaseException.code` instead of the + non-existent `PurchaseException` and `PurchaseException.errorCode`. * Updates minimum supported SDK version to Flutter 3.38/Dart 3.10. * Updates README to reflect currently supported OS versions for the latest versions of the endorsed platform implementations. diff --git a/packages/in_app_purchase/in_app_purchase/lib/in_app_purchase.dart b/packages/in_app_purchase/in_app_purchase/lib/in_app_purchase.dart index 4bc5f9142200..5aa6a0c964d4 100644 --- a/packages/in_app_purchase/in_app_purchase/lib/in_app_purchase.dart +++ b/packages/in_app_purchase/in_app_purchase/lib/in_app_purchase.dart @@ -173,15 +173,15 @@ class InAppPurchase implements InAppPurchasePlatformAdditionProvider { /// For convenience, [PurchaseDetails.pendingCompletePurchase] indicates if a /// purchase is pending for completion. /// - /// The method will throw a [PurchaseException] when the purchase could not be - /// finished. Depending on the [PurchaseException.errorCode] the developer - /// should try to complete the purchase via this method again, or retry the - /// [completePurchase] method at a later time. If the - /// [PurchaseException.errorCode] indicates you should not retry there might + /// The method will throw an [InAppPurchaseException] when the purchase + /// could not be finished. Depending on the [InAppPurchaseException.code] the + /// developer should try to complete the purchase via this method again, or + /// retry the [completePurchase] method at a later time. If the + /// [InAppPurchaseException.code] indicates you should not retry there might /// be some issue with the app's code or the configuration of the app in the /// respective store. The developer is responsible to fix this issue. The - /// [PurchaseException.message] field might provide more information on what - /// went wrong. + /// [InAppPurchaseException.message] field might provide more information on + /// what went wrong. Future completePurchase(PurchaseDetails purchase) => InAppPurchasePlatform.instance.completePurchase(purchase); diff --git a/packages/in_app_purchase/in_app_purchase_platform_interface/CHANGELOG.md b/packages/in_app_purchase/in_app_purchase_platform_interface/CHANGELOG.md index ab6aa348efdd..860278bb51a6 100644 --- a/packages/in_app_purchase/in_app_purchase_platform_interface/CHANGELOG.md +++ b/packages/in_app_purchase/in_app_purchase_platform_interface/CHANGELOG.md @@ -1,5 +1,8 @@ ## NEXT +* Fixes broken dartdoc references in `completePurchase` to point to + `InAppPurchaseException` and `InAppPurchaseException.code` instead of the + non-existent `PurchaseException` and `PurchaseException.errorCode`. * Updates minimum supported SDK version to Flutter 3.38/Dart 3.10. ## 1.4.0 diff --git a/packages/in_app_purchase/in_app_purchase_platform_interface/lib/src/in_app_purchase_platform.dart b/packages/in_app_purchase/in_app_purchase_platform_interface/lib/src/in_app_purchase_platform.dart index eac2a80e214f..188db9c0beb1 100644 --- a/packages/in_app_purchase/in_app_purchase_platform_interface/lib/src/in_app_purchase_platform.dart +++ b/packages/in_app_purchase/in_app_purchase_platform_interface/lib/src/in_app_purchase_platform.dart @@ -6,6 +6,7 @@ import 'dart:async'; import 'package:plugin_platform_interface/plugin_platform_interface.dart'; +import 'errors/errors.dart'; import 'types/types.dart'; /// The interface that implementations of in_app_purchase must implement. @@ -161,15 +162,15 @@ abstract class InAppPurchasePlatform extends PlatformInterface { /// For convenience, [PurchaseDetails.pendingCompletePurchase] indicates if a /// purchase is pending for completion. /// - /// The method will throw a [PurchaseException] when the purchase could not be - /// finished. Depending on the [PurchaseException.errorCode] the developer - /// should try to complete the purchase via this method again, or retry the - /// [completePurchase] method at a later time. If the - /// [PurchaseException.errorCode] indicates you should not retry there might + /// The method will throw an [InAppPurchaseException] when the purchase + /// could not be finished. Depending on the [InAppPurchaseException.code] the + /// developer should try to complete the purchase via this method again, or + /// retry the [completePurchase] method at a later time. If the + /// [InAppPurchaseException.code] indicates you should not retry there might /// be some issue with the app's code or the configuration of the app in the /// respective store. The developer is responsible to fix this issue. The - /// [PurchaseException.message] field might provide more information on what - /// went wrong. + /// [InAppPurchaseException.message] field might provide more information on + /// what went wrong. Future completePurchase(PurchaseDetails purchase) => throw UnimplementedError('completePurchase() has not been implemented.'); From c338f1f760379fbe339a450c91c6acf509407688 Mon Sep 17 00:00:00 2001 From: Ishaq Hassan Date: Fri, 22 May 2026 20:15:08 +0500 Subject: [PATCH 2/2] Bump versions and rename CHANGELOG NEXT headers in_app_purchase: 3.2.3 -> 3.2.4 in_app_purchase_platform_interface: 1.4.0 -> 1.4.1 CHANGELOG ## NEXT entries renamed to the new versions in both packages. --- packages/in_app_purchase/in_app_purchase/CHANGELOG.md | 2 +- packages/in_app_purchase/in_app_purchase/pubspec.yaml | 2 +- .../in_app_purchase_platform_interface/CHANGELOG.md | 2 +- .../in_app_purchase_platform_interface/pubspec.yaml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/in_app_purchase/in_app_purchase/CHANGELOG.md b/packages/in_app_purchase/in_app_purchase/CHANGELOG.md index 715bab19e7df..ba5d045e8244 100644 --- a/packages/in_app_purchase/in_app_purchase/CHANGELOG.md +++ b/packages/in_app_purchase/in_app_purchase/CHANGELOG.md @@ -1,4 +1,4 @@ -## NEXT +## 3.2.4 * Fixes broken dartdoc references in `completePurchase` to point to `InAppPurchaseException` and `InAppPurchaseException.code` instead of the diff --git a/packages/in_app_purchase/in_app_purchase/pubspec.yaml b/packages/in_app_purchase/in_app_purchase/pubspec.yaml index 5d57ad2db40a..ec2acd810b74 100644 --- a/packages/in_app_purchase/in_app_purchase/pubspec.yaml +++ b/packages/in_app_purchase/in_app_purchase/pubspec.yaml @@ -2,7 +2,7 @@ name: in_app_purchase description: A Flutter plugin for in-app purchases. Exposes APIs for making in-app purchases through the App Store and Google Play. repository: https://github.com/flutter/packages/tree/main/packages/in_app_purchase/in_app_purchase issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+in_app_purchase%22 -version: 3.2.3 +version: 3.2.4 environment: sdk: ^3.10.0 diff --git a/packages/in_app_purchase/in_app_purchase_platform_interface/CHANGELOG.md b/packages/in_app_purchase/in_app_purchase_platform_interface/CHANGELOG.md index 860278bb51a6..465e7bdda939 100644 --- a/packages/in_app_purchase/in_app_purchase_platform_interface/CHANGELOG.md +++ b/packages/in_app_purchase/in_app_purchase_platform_interface/CHANGELOG.md @@ -1,4 +1,4 @@ -## NEXT +## 1.4.1 * Fixes broken dartdoc references in `completePurchase` to point to `InAppPurchaseException` and `InAppPurchaseException.code` instead of the diff --git a/packages/in_app_purchase/in_app_purchase_platform_interface/pubspec.yaml b/packages/in_app_purchase/in_app_purchase_platform_interface/pubspec.yaml index 4980c9baf954..6784e5c70d3c 100644 --- a/packages/in_app_purchase/in_app_purchase_platform_interface/pubspec.yaml +++ b/packages/in_app_purchase/in_app_purchase_platform_interface/pubspec.yaml @@ -4,7 +4,7 @@ repository: https://github.com/flutter/packages/tree/main/packages/in_app_purcha issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+in_app_purchase%22 # NOTE: We strongly prefer non-breaking changes, even at the expense of a # less-clean API. See https://flutter.dev/go/platform-interface-breaking-changes -version: 1.4.0 +version: 1.4.1 environment: sdk: ^3.10.0