Search code examples
androidgradlejava-websocket

Failed to resolve compile "org.java-websocket:java-websocket:1.3.2"


I am developing chat application based on a demo from github. They used java-webocket:1.3.2, I was using java-websocket:1.3.1 but I got error because in 1.3.1 there is no setSocket() method. Then I changed in the gradle my version and suddenly I got this error

Failed to resolve compile "org.java-websocket:java-websocket:1.3.2"

I tried to find jar of this library but I could not find. I do not know why this is happening I am stuck with this error for 2 hours now, my internet is working fine but I cannot add java-websocket:1.3.2 to my dependencies but its working fine when I change back to 1.3.1


Solution

  • please add maven { url 'http://clojars.org/repo' } into your build.gradle that under the project then it will work.