Skip to content
This repository has been archived by the owner on Feb 22, 2023. It is now read-only.

Commit

Permalink
Update all plugins that use verifyToken to use verify instead (#4643
Browse files Browse the repository at this point in the history
)
  • Loading branch information
collinjackson authored Jan 7, 2022
1 parent dc9a20f commit 87adc2a
Show file tree
Hide file tree
Showing 30 changed files with 64 additions and 33 deletions.
4 changes: 4 additions & 0 deletions packages/camera/camera_platform_interface/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 2.1.3

* Update to use the `verify` method introduced in platform_plugin_interface 2.1.0.

## 2.1.2

* Adopts new analysis options and fixes all violations.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ abstract class CameraPlatform extends PlatformInterface {
/// Platform-specific plugins should set this with their own platform-specific
/// class that extends [CameraPlatform] when they register themselves.
static set instance(CameraPlatform instance) {
PlatformInterface.verifyToken(instance, _token);
PlatformInterface.verify(instance, _token);
_instance = instance;
}

Expand Down
4 changes: 2 additions & 2 deletions packages/camera/camera_platform_interface/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repository: https://github.com/flutter/plugins/tree/master/packages/camera/camer
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+camera%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: 2.1.2
version: 2.1.3

environment:
sdk: '>=2.12.0 <3.0.0'
Expand All @@ -15,7 +15,7 @@ dependencies:
flutter:
sdk: flutter
meta: ^1.3.0
plugin_platform_interface: ^2.0.0
plugin_platform_interface: ^2.1.0
stream_transform: ^2.0.0

dev_dependencies:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
## NEXT
## 2.0.3

* Minor code cleanup for new analysis rules.
* Update to use the `verify` method introduced in plugin_platform_interface 2.1.0.

## 2.0.2

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ abstract class FileSelectorPlatform extends PlatformInterface {
/// Platform-specific plugins should set this with their own platform-specific
/// class that extends [FileSelectorPlatform] when they register themselves.
static set instance(FileSelectorPlatform instance) {
PlatformInterface.verifyToken(instance, _token);
PlatformInterface.verify(instance, _token);
_instance = instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repository: https://github.com/flutter/plugins/tree/master/packages/file_selecto
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+file_selector%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: 2.0.2
version: 2.0.3

environment:
sdk: ">=2.12.0 <3.0.0"
Expand All @@ -16,7 +16,7 @@ dependencies:
sdk: flutter
http: ^0.13.0
meta: ^1.3.0
plugin_platform_interface: ^2.0.0
plugin_platform_interface: ^2.1.0

dev_dependencies:
flutter_test:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 2.1.4

* Update to use the `verify` method introduced in plugin_platform_interface 2.1.0.

## 2.1.3

* `LatLng` constructor maintains longitude precision when given within
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ abstract class GoogleMapsFlutterPlatform extends PlatformInterface {
/// Platform-specific plugins should set this with their own platform-specific
/// class that extends [GoogleMapsFlutterPlatform] when they register themselves.
static set instance(GoogleMapsFlutterPlatform instance) {
PlatformInterface.verifyToken(instance, _token);
PlatformInterface.verify(instance, _token);
_instance = instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repository: https://github.com/flutter/plugins/tree/master/packages/google_maps_
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+maps%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: 2.1.3
version: 2.1.4

environment:
sdk: '>=2.12.0 <3.0.0'
Expand All @@ -15,7 +15,7 @@ dependencies:
flutter:
sdk: flutter
meta: ^1.3.0
plugin_platform_interface: ^2.0.0
plugin_platform_interface: ^2.1.0
stream_transform: ^2.0.0

dev_dependencies:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 2.4.2

* Update to use the `verify` method introduced in plugin_platform_interface 2.1.0.

## 2.4.1

* Reverts the changes from 2.4.0, which was a breaking change that
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ abstract class ImagePickerPlatform extends PlatformInterface {
// TODO(amirh): Extract common platform interface logic.
// https://github.com/flutter/flutter/issues/43368
static set instance(ImagePickerPlatform instance) {
PlatformInterface.verifyToken(instance, _token);
PlatformInterface.verify(instance, _token);
_instance = instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repository: https://github.com/flutter/plugins/tree/master/packages/image_picker
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+image_picker%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: 2.4.1
version: 2.4.2

environment:
sdk: ">=2.12.0 <3.0.0"
Expand All @@ -15,7 +15,7 @@ dependencies:
sdk: flutter
http: ^0.13.0
meta: ^1.3.0
plugin_platform_interface: ^2.0.0
plugin_platform_interface: ^2.1.0
cross_file: ^0.3.1+1

dev_dependencies:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 1.3.1

* Update to use the `verify` method introduced in plugin_platform_interface 2.1.0.

## 1.3.0

* Added new `PurchaseStatus` named `canceled` to distinguish between an error and user cancellation.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ abstract class InAppPurchasePlatform extends PlatformInterface {
// TODO(amirh): Extract common platform interface logic.
// https://github.com/flutter/flutter/issues/43368
static set instance(InAppPurchasePlatform instance) {
PlatformInterface.verifyToken(instance, _token);
PlatformInterface.verify(instance, _token);
_instance = instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repository: https://github.com/flutter/plugins/tree/master/packages/in_app_purch
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.3.0
version: 1.3.1

environment:
sdk: ">=2.12.0 <3.0.0"
Expand All @@ -13,7 +13,7 @@ environment:
dependencies:
flutter:
sdk: flutter
plugin_platform_interface: ^2.0.0
plugin_platform_interface: ^2.1.0

dev_dependencies:
flutter_test:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 2.0.2

* Update to use the `verify` method introduced in plugin_platform_interface 2.1.0.

## 2.0.1

* Update platform_plugin_interface version requirement.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ abstract class PathProviderPlatform extends PlatformInterface {
/// Platform-specific plugins should set this with their own platform-specific
/// class that extends [PathProviderPlatform] when they register themselves.
static set instance(PathProviderPlatform instance) {
PlatformInterface.verifyToken(instance, _token);
PlatformInterface.verify(instance, _token);
_instance = instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repository: https://github.com/flutter/plugins/tree/master/packages/path_provide
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+path_provider%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: 2.0.1
version: 2.0.2

environment:
sdk: ">=2.12.0 <3.0.0"
Expand All @@ -15,7 +15,7 @@ dependencies:
sdk: flutter
meta: ^1.3.0
platform: ^3.0.0
plugin_platform_interface: ^2.0.0
plugin_platform_interface: ^2.1.0

dev_dependencies:
flutter_test:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
## NEXT
## 1.0.1

* Updates code for analyzer changes.
* Update to use the `verify` method introduced in plugin_platform_interface 2.1.0.

## 1.0.0

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ abstract class QuickActionsPlatform extends PlatformInterface {
// TODO(amirh): Extract common platform interface logic.
// https://github.com/flutter/flutter/issues/43368
static set instance(QuickActionsPlatform instance) {
PlatformInterface.verifyToken(instance, _token);
PlatformInterface.verify(instance, _token);
_instance = instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repository: https://github.com/flutter/plugins/tree/master/packages/quick_action
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+quick_actions%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.0.0
version: 1.0.1

environment:
sdk: ">=2.12.0 <3.0.0"
Expand All @@ -14,7 +14,7 @@ dependencies:
flutter:
sdk: flutter
meta: ^1.3.0
plugin_platform_interface: ^2.0.0
plugin_platform_interface: ^2.1.0

dev_dependencies:
flutter_test:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
## NEXT
## 2.0.5

* Updates code for new analysis options.
* Update to use the `verify` method introduced in platform_plugin_interface 2.1.0.

## 2.0.4

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ abstract class UrlLauncherPlatform extends PlatformInterface {
// TODO(amirh): Extract common platform interface logic.
// https://github.com/flutter/flutter/issues/43368
static set instance(UrlLauncherPlatform instance) {
PlatformInterface.verifyToken(instance, _token);
PlatformInterface.verify(instance, _token);
_instance = instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repository: https://github.com/flutter/plugins/tree/master/packages/url_launcher
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+url_launcher%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: 2.0.4
version: 2.0.5

environment:
sdk: ">=2.12.0 <3.0.0"
Expand All @@ -13,7 +13,7 @@ environment:
dependencies:
flutter:
sdk: flutter
plugin_platform_interface: ^2.0.0
plugin_platform_interface: ^2.1.0

dev_dependencies:
flutter_test:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 5.0.1

* Update to use the `verify` method introduced in platform_plugin_interface 2.1.0.

## 5.0.0

* **BREAKING CHANGES**:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ abstract class VideoPlayerPlatform extends PlatformInterface {
/// platform-specific class that extends [VideoPlayerPlatform] when they
/// register themselves.
static set instance(VideoPlayerPlatform instance) {
PlatformInterface.verifyToken(instance, _token);
PlatformInterface.verify(instance, _token);
_instance = instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repository: https://github.com/flutter/plugins/tree/master/packages/video_player
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+video_player%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: 5.0.0
version: 5.0.1

environment:
sdk: ">=2.12.0 <3.0.0"
Expand All @@ -13,7 +13,7 @@ environment:
dependencies:
flutter:
sdk: flutter
plugin_platform_interface: ^2.0.0
plugin_platform_interface: ^2.1.0

dev_dependencies:
flutter_test:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 1.8.1

* Update to use the `verify` method introduced in platform_plugin_interface 2.1.0.

## 1.8.0

* Adds the `loadFlutterAsset` method to the platform interface.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ abstract class WebViewCookieManagerPlatform extends PlatformInterface {
throw AssertionError(
'Platform interfaces can only be set to a non-null instance');
}
PlatformInterface.verifyToken(instance, _token);
PlatformInterface.verify(instance, _token);
_instance = instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repository: https://github.com/flutter/plugins/tree/master/packages/webview_flut
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+webview_flutter%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.8.0
version: 1.8.1

environment:
sdk: ">=2.12.0 <3.0.0"
Expand All @@ -13,7 +13,7 @@ environment:
dependencies:
flutter:
sdk: flutter
plugin_platform_interface: ^2.0.0
plugin_platform_interface: ^2.1.0

dev_dependencies:
flutter_test:
Expand Down

1 comment on commit 87adc2a

@francisnnumbi
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These changes have created an issue with google_maps_flutter on Android side only. Creating GoogleMap widget does not initialize GoogleMapController. The map loads, but freezes. All operations done on the controller fail.

Here is the exception it raises :
E/flutter (18576): [ERROR:flutter/lib/ui/ui_dart_state.cc(209)] Unhandled Exception: MissingPluginException(No implementation found for method map#waitForMap on channel plugins.flutter.io/google_maps_0) E/flutter (18576): #0 MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:165:7) E/flutter (18576): <asynchronous suspension> E/flutter (18576): #1 GoogleMapController.init (package:google_maps_flutter/src/controller.dart:30:5) E/flutter (18576): <asynchronous suspension> E/flutter (18576): #2 _GoogleMapState.onPlatformViewCreated (package:google_maps_flutter/src/google_map.dart:394:44) E/flutter (18576): <asynchronous suspension> E/flutter (18576):

It states that a plugin is missing ! We don't even know what plugins it refers to ! the issue started less that 5 days back ! Right now I don't know if the issue is with this dependency or if it is with Google Maps directly !

Our project is halted because of this exception !

Thank you.

Please sign in to comment.