pusher-channels-flutter
pusher-channels-flutter copied to clipboard
Namespace not specified
A problem occurred configuring project ':pusher_channels_flutter'.
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.
gradle-8.3
Same issue, I am facing from the past 2 days.
I am also facing the same issue when I upgraded the gradle and SDKs. Has anyone solved the issue yet?
try
pusher_channels_flutter:
git:
url: https://github.com/kishormainali/pusher-channels-flutter.git
ref: master
@we-prajapati-c001 where do I put that config?
instead of fetching the package from pub.dev, use below in you project pubspec.yaml
pusher_channels_flutter:
git:
url: https://github.com/kishormainali/pusher-channels-flutter.git
ref: master
Thank, I found out the problem that latest version of gradle don't support older version
try
pusher_channels_flutter: git: url: https://github.com/kishormainali/pusher-channels-flutter.git ref: master
This works so far
Hi, I found this stack overflow answer that helped me to solve the issue:
https://stackoverflow.com/a/77738936/2114245
I applied the mod on android root build.gradle file:
...
allprojects {
repositories {
google()
mavenCentral()
}
// This code is where all the magic happens and fixes the error.
subprojects {
afterEvaluate { project ->
if (project.hasProperty('android')) {
project.android {
if (namespace == null) {
namespace project.group
}
}
}
}
}
// This code is where all the magic happens and fixes the error.
}
...
then executed the following commands:
flutter clean
flutter pub get
flutter run
😄