vimeo / vimeo/vimeo-networking-java

Android app crashes while trying to authenticate with access token got from vimeo developer dashboard. Below is the stacktrace

Open
#526 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Kotlin
Stars
128
Forks
48
PR merge metrics
No merged PRs in 30d

Description

  • Stacktrace

    Caused by: java.lang.IllegalStateException: Authentication is not supported when using a fixed access token
    at com.vimeo.networking2.internal.NoOpAuthenticatorImpl.reject(NoOpAuthenticatorImpl.kt:85)
    at com.vimeo.networking2.internal.NoOpAuthenticatorImpl.authenticateWithClientCredentials(NoOpAuthenticatorImpl.kt:23)
    at com.radio.playbackspeeddemo.PlayApp.onCreate(PlayApp.kt:27)
    at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1190)
    at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6850)


  • Code causing issue:

val accessToken: String = "token here"
var vimeoApiConfiguration: VimeoApiConfiguration? = null
var vimeoApiClient: VimeoApiClient? = null

    vimeoApiConfiguration = VimeoApiConfiguration.Builder(accessToken)
        .build()
    val authenticator = Authenticator(vimeoApiConfiguration!!)

    vimeoApiClient = VimeoApiClient(vimeoApiConfiguration!!, authenticator)

    authenticator.authenticateWithClientCredentials(
        vimeoCallback(
            onSuccess = {
                Log.e("vimeo success", "vimeo success")
            },
            onError = {
                Log.e("vimeo failed", "vimeo failed")
            }
        )
    )

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with PlayApp.kt:27 and read the stack trace into NoOpAuthenticatorImpl.kt:23 and :85. Check how VimeoApiConfiguration.Builder(accessToken) interacts with Authenticator.authenticateWithClientCredentials; done means the fixed-token authentication behavior is understood and the reported crash path has a clear resolution.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, kotlin
Domain
authentication, mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.