Android expansion file "not licensed" error

Hi,

I recently crossed the 50mb threshold and had to move to an expansion file. It’s working, with hundreds of downloads per day, but I have a user reporting a “not licensed” issue.

Here’s the Android part of my build settings:

-- Android permissions androidPermissions = {   "android.permission.INTERNET",                 "android.permission.ACCESS\_NETWORK\_STATE",                 "com.android.vending.BILLING",                 "com.android.vending.CHECK\_LICENSE",                 "android.permission.WRITE\_EXTERNAL\_STORAGE",                    },                  android =          {            usesExpansionFile = true,            googlePlayGamesAppId = "My\_12\_digit\_ID"  --long App ID number (use yours!)         },

Here’s the issue coming up:  not-licensed.png

Hi @beernathan,

It appears that you’ve put your permissions table outside of the “android” table. It should be properly nested according the guide. On that note, we also recommend that you switch over to the “usesPermissions” format, as explained in the guide (the “androidPermissions” format should still work, but it shouldn’t be outside the “android” table).

http://docs.coronalabs.com/guide/distribution/buildSettings/index.html#androidsettings

Take care,

Brent

OK thanks Brent.

Weird that it is only impacting some players though?

Nathan.

Hi Nathan,

I just recalled something… did you implement Google Licensing in your config.lua file and require the licensing.* library as well?

Best regards,

Brent

Here’s my config. How do I require licensing.*?

application = { content = {                 graphicsCompatibility = 1,  -- Turn on V1 Compatibility Mode                 width = 320, height = 480,  scale = "letterbox",  fps = 30,         imageSuffix = {    ["@2x"] = 1.5,                      ["@4x"] = 3, } },         license = { google = { key = "MY\_KEY" }, },

Hi Nathan,

See the “App Licensing” section in this guide for details:

http://docs.coronalabs.com/daily/guide/basics/configSettings/index.html#licensing

I’m going to add a cross-link from the Build Settings guide to this page, since the two things are inter-related.

Note that you need to add things to config.lua and require the licensing.* library within main.lua.

Take care,

Brent

I did all this, but the user is having the same problem. Perhaps a problem at their end?

Hi @beernathan,

If one user is having this issue, then it could be any number of things, especially in the “wild west” of Android, manufacturer-tweaked versions of that OS, rooted devices, etc. We’d likely need to get some very specific details about which device is failing, and what the specific report is.

Thanks,

Brent

Hi @beernathan,

It appears that you’ve put your permissions table outside of the “android” table. It should be properly nested according the guide. On that note, we also recommend that you switch over to the “usesPermissions” format, as explained in the guide (the “androidPermissions” format should still work, but it shouldn’t be outside the “android” table).

http://docs.coronalabs.com/guide/distribution/buildSettings/index.html#androidsettings

Take care,

Brent

OK thanks Brent.

Weird that it is only impacting some players though?

Nathan.

Hi Nathan,

I just recalled something… did you implement Google Licensing in your config.lua file and require the licensing.* library as well?

Best regards,

Brent

Here’s my config. How do I require licensing.*?

application = { content = {                 graphicsCompatibility = 1,  -- Turn on V1 Compatibility Mode                 width = 320, height = 480,  scale = "letterbox",  fps = 30,         imageSuffix = {    ["@2x"] = 1.5,                      ["@4x"] = 3, } },         license = { google = { key = "MY\_KEY" }, },

Hi Nathan,

See the “App Licensing” section in this guide for details:

http://docs.coronalabs.com/daily/guide/basics/configSettings/index.html#licensing

I’m going to add a cross-link from the Build Settings guide to this page, since the two things are inter-related.

Note that you need to add things to config.lua and require the licensing.* library within main.lua.

Take care,

Brent

I did all this, but the user is having the same problem. Perhaps a problem at their end?

Hi @beernathan,

If one user is having this issue, then it could be any number of things, especially in the “wild west” of Android, manufacturer-tweaked versions of that OS, rooted devices, etc. We’d likely need to get some very specific details about which device is failing, and what the specific report is.

Thanks,

Brent