aws-amplify / amplify-flutter

A declarative library with an easy-to-use interface for building Flutter applications on AWS.
https://docs.amplify.aws
Apache License 2.0
1.31k stars 242 forks source link

Compile issues after upgrading to 2.2.0 #5165

Closed iosephmagno closed 2 weeks ago

iosephmagno commented 1 month ago

Description

After upgrading to latest flutter master channel and upgrading Amplify to 2.2.0, I get several compile issues that I cannto solve:

// Error
error: cannot find symbol
      flutterEngine.getPlugins().add(new com.amazonaws.amplify.amplify_secure_storage.AmplifySecureStoragePlugin());
// Warnings 
Package amplify_secure_storage:linux references amplify_secure_storage_dart:linux as the default plugin, but the package does not exist.
Ask the maintainers of amplify_secure_storage to either avoid referencing a default implementation via `platforms: linux: default_package: amplify_secure_storage_dart` or create a plugin named amplify_secure_storage_dart.

Package amplify_secure_storage:windows references amplify_secure_storage_dart:windows as the default plugin, but the package does not exist.
Ask the maintainers of amplify_secure_storage to either avoid referencing a default implementation via `platforms: windows: default_package: amplify_secure_storage_dart` or create a plugin named amplify_secure_storage_dart.

Package amplify_secure_storage:linux references amplify_secure_storage_dart:linux as the default plugin, but the package does not exist.
Ask the maintainers of amplify_secure_storage to either avoid referencing a default implementation via `platforms: linux: default_package: amplify_secure_storage_dart` or create a plugin named amplify_secure_storage_dart.

Package amplify_secure_storage:windows references amplify_secure_storage_dart:windows as the default plugin, but the package does not exist.
Ask the maintainers of amplify_secure_storage to either avoid referencing a default implementation via `platforms: windows: default_package: amplify_secure_storage_dart` or create a plugin named amplify_secure_storage_dart.

Package amplify_secure_storage:linux references amplify_secure_storage_dart:linux as the default plugin, but the package does not exist.
Ask the maintainers of amplify_secure_storage to either avoid referencing a default implementation via `platforms: linux: default_package: amplify_secure_storage_dart` or create a plugin named amplify_secure_storage_dart.

Package amplify_secure_storage:windows references amplify_secure_storage_dart:windows as the default plugin, but the package does not exist.
Ask the maintainers of amplify_secure_storage to either avoid referencing a default implementation via `platforms: windows: default_package: amplify_secure_storage_dart` or create a plugin named amplify_secure_storage_dart.

My pubspec is:

  amplify_auth_cognito: 2.2.0
  amplify_flutter: 2.2.0 
  amplify_storage_s3: 2.2.0 
  amplify_authenticator: 2.1.0 

Categories

Steps to Reproduce

Set pubspec as follow and compile

  amplify_auth_cognito: 2.2.0
  amplify_flutter: 2.2.0 
  amplify_storage_s3: 2.2.0 
  amplify_authenticator: 2.1.0 

Screenshots

No response

Platforms

Flutter Version

Channel Master 3.24.0-1.0.pre.151

Amplify Flutter Version

2.2.0

Deployment Method

Amplify CLI

Schema

No response

Equartey commented 1 month ago

Hi @iosephmagno, thank's for reporting this.

Due to frequent changes in the Flutter Master channel, issues like this can occasionally occur (and even resolve themselves). However, we will investigate to ensure this won't be an issue long term.

delfme commented 1 month ago

Other plugin had to fix same issue as well, please check here https://github.com/MaikuB/flutter_local_notifications/issues/2368

Equartey commented 1 month ago

@iosephmagno @delfme

Hi all, a fix for this has been merged. We will let yall know when this has been released. Thanks again for reporting it.

iosephmagno commented 3 weeks ago

Hello, just informing that we tried latest version of plugin and still throws compile errors. We have to downgrade to amplify v. 1.7.0 to be able to compile.

MarlonJD commented 3 weeks ago

Hello, just informing that we tried latest version of plugin and still throws compile errors. We have to downgrade to amplify v. 1.7.0 to be able to compile.

Which version on flutter? Is this master branch of flutter? This changes merged but not available on 2.3.0, these changes not released yet, so you might get build error while you trying to build on latest flutter version.

iosephmagno commented 3 weeks ago

Yep master branch, I'm not at deck now and can't say the version, but a recent one.

NikaHsn commented 2 weeks ago

@iosephmagno @delfme the fix bas been merged and will be released in the next version.

jamontesg commented 2 weeks ago

@NikaHsn this was solved on todays release ?

delfme commented 2 weeks ago

Thx guys! 🚀

NikaHsn commented 2 weeks ago

I'm going to close this issue as the fix has been released in 2.4.0 version. If you see otherwise or have additional questions, please open a new issue.