Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unresolved reference: ChuckerInterceptor #1338

Open
james04gr opened this issue Jan 22, 2025 · 8 comments
Open

Unresolved reference: ChuckerInterceptor #1338

james04gr opened this issue Jan 22, 2025 · 8 comments
Labels
incomplete This issue needs more data in order to be triaged

Comments

@james04gr
Copy link

✍️ Describe the bug

💣 Steps to reproduce

  1. Add dependencies to app build.gradle file
    dependencies {
    debugImplementation "com.github.chuckerteam.chucker:library:4.1.0"
    releaseImplementation "com.github.chuckerteam.chucker:library-no-op:4.1.0"
    }
  2. Trying to add ChuckerInterceptor to my OkHttpClient
  3. Get error { Unresolved reference: ChuckerInterceptor }

📷 Screenshots

Image

@cortinico
Copy link
Member

You're probably missing an import. Can you share your source file?

@cortinico cortinico added the incomplete This issue needs more data in order to be triaged label Jan 22, 2025
@james04gr
Copy link
Author

james04gr commented Jan 22, 2025

The point is that Androis Studio cannot find any available import in order to include...

Image

Which import should i include??

@cortinico
Copy link
Member

The correct import is:

import com.chuckerteam.chucker.api.ChuckerInterceptor

as you can see from the samples: https://github.com/ChuckerTeam/chucker/blob/main/sample/src/main/kotlin/com/chuckerteam/chucker/sample/OkHttpUtils.kt

You need to gradle sync after you modified your gradle files

@james04gr
Copy link
Author

I have sync my gradle successfully and i have try to import the above import manually but the result is the image above... :/ :/

@cortinico
Copy link
Member

Then please use this template: https://github.com/cortinico/kotlin-android-template
and create a reproducer so that we can see where is the issue

@erizoo
Copy link

erizoo commented Feb 10, 2025

I have the same error. I found that if you write only the implementation, don't debug and release, everything works.

@james04gr
Copy link
Author

What do u mean dont debug?? I dont want to keep logs in the releave version

@erizoo
Copy link

erizoo commented Feb 10, 2025

Of course I am, too.
I'm trying to figure out how to make it work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
incomplete This issue needs more data in order to be triaged
Projects
None yet
Development

No branches or pull requests

3 participants