weishirongzhen / flutter_trust_wallet_core

MIT License
88 stars 33 forks source link

this lib build error with android #41

Closed jerrywangjing closed 2 years ago

jerrywangjing commented 2 years ago

when build with android device, load this lib will throw error like below:

maven {
            url = uri("https://maven.pkg.github.com/weishirongzhen/wallet-core")
            credentials {
                username = "weishirongzhen"
                password = "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" // GH token for only allow read package
            }
        }

console print error is:

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:checkDebugAarMetadata'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
   > Could not resolve com.trustwallet:wallet-core:2.7.2.
     Required by:
         project :app > project :trust_wallet_core
      > Could not resolve com.trustwallet:wallet-core:2.7.2.
         > Could not get resource '[https://maven.pkg.github.com/weishirongzhen/wallet-core/com/trustwallet/wallet-core/2.7.2/wallet-core-2.7.2.pom]()'.
            > Could not GET '[https://maven.pkg.github.com/weishirongzhen/wallet-core/com/trustwallet/wallet-core/2.7.2/wallet-core-2.7.2.pom]()'. Received status code 401 from server: Unauthorized

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at [https://help.gradle.org]()

BUILD FAILED in 1m 3s
[!] Gradle threw an error while downloading artifacts from the network. Retrying to download...

please help me, and tell how to install this lib in my project, think you very much! wish you reply.

badjone commented 2 years ago

same problem

weishirongzhen commented 2 years ago
maven {
            url = uri("https://maven.pkg.github.com/trustwallet/wallet-core")
            credentials {
                username = project.findProperty("gpr.user") ?: System.getenv("USERNAME")
                password = project.findProperty("gpr.key") ?: System.getenv("TOKEN")
            }
        }

now trustwallet core lib use offcial link, please set your own username and password to sync your build. or use my other repo for your test purpose