Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please move package namespace from Android manifest to build file. #6

Open
PeperMarkreel opened this issue Feb 18, 2024 · 2 comments
Open

Comments

@PeperMarkreel
Copy link

PeperMarkreel commented Feb 18, 2024

Hi,

Could you please remove package="fr.g123k.install_referrer" from the android manifest and move it to the build file?

Otherwise we get

FAILURE: Build failed with an exception.

* What went wrong:
A problem occurred configuring project ':install_referrer'.
> 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.

Change the following:
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="fr.g123k.install_referrer"> </manifest>

to
<manifest xmlns:android="http://schemas.android.com/apk/res/android"> </manifest>

and add the namespace in the module's build file like the following in build.gradle:

android { namespace "fr.g123k.install_referrer" compileSdkVersion 31

Thanks

@PeperMarkreel PeperMarkreel changed the title Please remove package namespace from Android manifest Please move package namespace from Android manifest to build file. Feb 18, 2024
@bsz0206
Copy link

bsz0206 commented Oct 25, 2024

@g123k
This issue needs addressing. People have even created PR for it. If you don't care about this project anymore, then delegate it to someone else.

@bastibense
Copy link

This cost me 2 hours of trial and error until I found out this was the culprit. :(

Ended up removing this pub for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants