app-release-unsigned.apk is not signed

2019-01-12 16:12发布

I downloaded the zip file of an Android app on github and I'm trying to run it, but I get a dialog with this message

app-release-unsigned.apk is not signed. Please configure the signing information for the selected flavor using the Project Structure dialog.

I'm using Android Studio. What am I supposed to do?

13条回答
Luminary・发光体
2楼-- · 2019-01-12 16:26

In tool window bar select Build Variants Change Build Variant from Release to Debug

查看更多
做个烂人
3楼-- · 2019-01-12 16:26

My solution was to change the name of my signing config from the default "config" to "debug". To verify, I changed it to some other random name and got the error again, and then changed it back to "debug" and the error was gone. So while it seems artificial and I tend to not believe this is the whole story, give this solution a try.

查看更多
叛逆
4楼-- · 2019-01-12 16:26

i also appear this problem,and my code below

        storeFile file(properties.getProperty("filepath"))
        storePassword properties.getProperty("keypassword")
        keyAlias properties.getProperty("keyAlias")
        keyPassword properties.getProperty("keypassword")

the reason is property name error,it should be keyPassword not keypassword

查看更多
贼婆χ
5楼-- · 2019-01-12 16:31

if you want to run app in debug mode

1) Look at Left Side bottom, above Favorites there is Build Variants

2) Click on Build Variants. Click on release and choose debug

it works perfect !!!

查看更多
Lonely孤独者°
6楼-- · 2019-01-12 16:32

signingConfigs should be before buildTypes

signingConfigs {
        debug {
            storeFile file("debug.keystore")
        }

        myConfig {
            storeFile file("other.keystore")
            storePassword "android"
            keyAlias "androidotherkey"
            keyPassword "android"
        }
    }

    buildTypes {
        bar {
            debuggable true
            jniDebugBuild true
            signingConfig signingConfigs.debug
        }
        foo {
            debuggable false
            jniDebugBuild false
            signingConfig signingConfigs.myConfig
        }
    }
查看更多
兄弟一词,经得起流年.
7楼-- · 2019-01-12 16:35

The app project you downloaded may include a signed info in the file of build.gradle. If you saw codes like these:

buildTypes {
    debug {
        signingConfig signingConfigs.release
    }
    release {
        signingConfig signingConfigs.release
    }
}

you could delete them and try again.

查看更多
登录 后发表回答