Nokia X 304 - The package name extracted from an APK file does not match the package name specified in the content item

StackOverflow https://stackoverflow.com//questions/22058326

  •  23-12-2019
  •  | 
  •  

Question

So the Quick, default publish app option did not work (which is a serious getting started / user experience issue). So I tried the standard option.

After I uploaded the app, I get this error

Errors 304 - The package name extracted from an APK file does not match the package name specified in the content item.

Now, this happens because I have the following development environment

  1. Android Library project with packagename com.mcruiseon.caregiri
  2. A Android project dependent on 1), with packagename in the manifest as com.mcruiseon.caregirihindjewadibeta

When I upload the app, I guess your validation extracts the file, compares the actual packagename of class files, with the androidmanifest file and comes up with this conflict.

Why do I have this setup ? Its called multiple builds project supported by Android (http://developer.android.com/tools/projects/index.html) My scenario is that I am building a carpool app, and I will use the same source code to build a bike pool app. And the same code base to build a demo app (marketing / sales buys can use to demonstrate to people on the road and in road shows). Its like the preprocessor directive thingy in C #ifdef.

Was it helpful?

Solution

I doubt it matters what java package you use for your classes.

I think you have made a typo entering the package name for the application metadata during publishing. You can verify the packagename of your apk with the aapt command (it's located in you Android SDK/build-tools/[version]/aapt) by running:

$ aapt d badging YOURAPPLICATION.apk
package: name='com.mcruiseon.caregirihindjewadibeta' versionCode='1' versionName='1.0.0'
...

Use the name attribute there (I assume it will be com.mcruiseon.caregirihindjewadibeta) as the Package name of your content item during publishing.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top