flutter_libserialport icon indicating copy to clipboard operation
flutter_libserialport copied to clipboard

Android: Namespace not specified

Open rekire opened this issue 1 year ago • 2 comments

I get this exception when building my app for Android:

Failed to query the value of property 'buildFlowServiceProperty'.

Could not isolate value org.jetbrains.kotlin.gradle.plugin.statistics.BuildFlowService$Parameters_Decorated@17b5eafd of type BuildFlowService.Parameters A problem occurred configuring project ':flutter_libserialport'. > Could not create an instance of type com.android.build.api.variant.impl.LibraryVariantBuilderImpl. > Namespace not specified. Specify a namespace in the module's build file. See https://d.android.com/r/tools/upgrade-assistant/set-namespace for information about setting the namespace.

If you've specified the package attribute in the source AndroidManifest.xml, you can use the AGP Upgrade Assistant to migrate to the namespace value in the build file. Refer to https://d.android.com/r/tools/upgrade-assistant/agp-upgrade-assistant for general information about using the AGP Upgrade Assistant.

You just need to set the namespace (and likely update some dependencies) to resolve this.

rekire avatar Jun 20 '24 06:06 rekire

I just came across this issue. Is there a fix that I can implement?

MatthewHightech avatar Oct 24 '24 06:10 MatthewHightech

Let me quote myself from the pull request with the fix.

For others who might want to test it:

dependencies:
  // other dependencies
  flutter_libserialport: #^0.5.0
    # remove this git part when 0.5.0 is published
    git:
      url: https://github.com/snabble/flutter_libserialport.git
      ref: 0.5.0

rekire avatar Oct 24 '24 07:10 rekire

Just tested it and it works with that fix!

ImadMAKS avatar Nov 12 '24 16:11 ImadMAKS

Let me quote myself from the pull request with the fix.

For others who might want to test it:

dependencies:
  // other dependencies
  flutter_libserialport: #^0.5.0
    # remove this git part when 0.5.0 is published
    git:
      url: https://github.com/snabble/flutter_libserialport.git
      ref: 0.5.0

I am very grateful to you.. I have been searching for this solution for a month and a half.

abdulrhmanhassan avatar Jan 02 '25 19:01 abdulrhmanhassan