Skip to content

Sign in button fails and Logcat complains of missing OAuth, #219

@olibye

Description

@olibye

Before creating a new issue, please confirm:

Which UI component?

Liveness

Gradle script dependencies

// Put output below this line
        amplifyVersion = '2.15.1'

Environment information

# Put output below this line

------------------------------------------------------------
Gradle 8.2.1
------------------------------------------------------------

Build time:   2023-07-10 12:12:35 UTC
Revision:     a38ec64d3c4612da9083cc506a1ccb212afeecaa

Kotlin:       1.8.20
Groovy:       3.0.17
Ant:          Apache Ant(TM) version 1.10.13 compiled on January 4 2023
JVM:          17.0.14 (Homebrew 17.0.14+0)
OS:           Mac OS X 15.3.1 x86_64


Please include any relevant guides or documentation you're referencing

No response

Describe the bug

Using tag release_liveness_v1.3.0, as later tags do not compile on my Mac.

  • All AWS backend deployed, and amplify push passing.
  • Android app compiles, but "Sign In" button does nothing.
  • Android Logcat: see log section of issue...

Reproduction steps (if applicable)

No response

Code Snippet

// Put your code below this line.

Log output

2025-03-09 20:17:21.622 28420-28420 MainActivity            com...yframework.ui.sample.liveness  E  Failed to sign in
                                                                                                    InvalidOauthConfigurationException{message=The Oauth configuration is missing or invalid., cause=null, recoverySuggestion=HostedUI Oauth section not configured or unable to parse from amplifyconfiguration.json file.}
                                                                                                    	at com.amplifyframework.auth.cognito.RealAWSCognitoAuthPlugin$signInWithHostedUI$1.invoke(RealAWSCognitoAuthPlugin.kt:926)
                                                                                                    	at com.amplifyframework.auth.cognito.RealAWSCognitoAuthPlugin$signInWithHostedUI$1.invoke(RealAWSCognitoAuthPlugin.kt:918)
                                                                                                    	at com.amplifyframework.statemachine.StateMachine$getCurrentState$1.invokeSuspend(StateMachine.kt:121)
                                                                                                    	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
                                                                                                    	at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:104)
                                                                                                    	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:524)
                                                                                                    	at java.util.concurrent.FutureTask.run(FutureTask.java:317)
                                                                                                    	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:348)
                                                                                                    	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1156)
                                                                                                    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:651)
                                                                                                    	at java.lang.Thread.run(Thread.java:1119)


amplifyconfiguration.json

{
"UserAgent": "aws-amplify-cli/2.0",
"Version": "1.0",
"api": {
"plugins": {
"awsAPIPlugin": {
"livenessBackendAPI": {
"endpointType": "REST",
"endpoint": "https://X.execute-api.eu-west-1.amazonaws.com/test",
"region": "eu-west-1",
"authorizationType": "AWS_IAM"
}
}
}
},
"auth": {
"plugins": {
"awsCognitoAuthPlugin": {
"UserAgent": "aws-amplify-cli/0.1.0",
"Version": "0.1.0",
"IdentityManager": {
"Default": {}
},
"CredentialsProvider": {
"CognitoIdentity": {
"Default": {
"PoolId": "X",
"Region": "eu-west-1"
}
}
},
"CognitoUserPool": {
"Default": {
"PoolId": "X",
"AppClientId": "X",
"Region": "eu-west-1"
}
},
"Auth": {
"Default": {
"authenticationFlowType": "USER_SRP_AUTH",
"mfaConfiguration": "OFF",
"mfaTypes": [
"SMS"
],
"passwordProtectionSettings": {
"passwordPolicyMinLength": 8,
"passwordPolicyCharacters": []
},
"signupAttributes": [
"EMAIL"
],
"socialProviders": [],
"usernameAttributes": [],
"verificationMechanisms": [
"EMAIL"
]
}
}
}
}
}
}

Additional information and screenshots

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    pending-maintainer-responseIssue is pending response from an Amplify team memberquestionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions