Skip to content

Commons-codec Issue in Android Devices #89

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

Closed
AlexDelosSantos opened this issue Oct 28, 2020 · 6 comments
Closed

Commons-codec Issue in Android Devices #89

AlexDelosSantos opened this issue Oct 28, 2020 · 6 comments
Assignees

Comments

@AlexDelosSantos
Copy link

AlexDelosSantos commented Oct 28, 2020

The library is using JWT library that uses features of apache commons-codec that is only available in version 1.4 and higher, the problem is android runtime has a built in commons-codec that will always be used in runtime which is version 1.3. Therefore result to method "java.lang.NoSuchMethodError: No static method" error due to those features are not available yet in version 1.3 of commons codec.

gz#6908

@ferhatelmas
Copy link
Contributor

Please ensure you add the minimal required version into your build.gradle for your runtime as follows:

dependencies {
    implementation 'commons-codec:commons-codec:1.4'
}

@ferhatelmas ferhatelmas self-assigned this Oct 28, 2020
@ferhatelmas
Copy link
Contributor

Seems this issue is deeper, let me see what we can do.

@ferhatelmas ferhatelmas reopened this Oct 28, 2020
@ferhatelmas
Copy link
Contributor

@AlexDelosSantos Are you using client.Client in android ? If so, use cloud.CloudClient.

@AlexDelosSantos
Copy link
Author

@AlexDelosSantos Are you using client.Client in android ? If so, use cloud.CloudClient.

Thank you for answering. I Tried using the cloudclient, but the cloud client requires the generated token, and token generation also requires the commons-codec 1.4 and up.

@AlexDelosSantos
Copy link
Author

Also feeds docs is not yet available for android Kotlin, only the chat API.
image

@ferhatelmas
Copy link
Contributor

I Tried using the cloudclient, but the cloud client requires the generated token, and token generation also requires the commons-codec 1.4 and up.

Ok, clear. You need to generate the token in your server which is supposed to be not an android runtime.
Codec won't be an issue because cloud client will get the token from your backend and will pass to our backend, it doesn't need to do any signing which is causing the issue.

Yes, kotlin might come for feeds in the future but not available at the moment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants