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

可以Gradle Sync成功但是Run的时候报错 #10

Open
gongzelong0718 opened this issue Sep 9, 2024 · 1 comment
Open

可以Gradle Sync成功但是Run的时候报错 #10

gongzelong0718 opened this issue Sep 9, 2024 · 1 comment

Comments

@gongzelong0718
Copy link

在local.properties里添加:
workingDirPath=/Users/gongzelong/Downloads/sdk/build-tools/32.0.0/

发现可以Gradle Sync成功。

Issue:

但是点击运行的时候就报错:
Screenshot 2024-09-09 at 17 30 49

> Task :app:writeDebugSigningConfigVersions UP-TO-DATE

FAILURE: Build completed with 7 failures.

1: Task 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.wang.avi:library:2.1.3.
     Required by:
         project :app > project :wgllss-common-re-library
      > Could not resolve com.wang.avi:library:2.1.3.
         > Could not get resource 'https://jitpack.io/com/wang/avi/library/2.1.3/library-2.1.3.pom'.
            > Could not HEAD 'https://jitpack.io/com/wang/avi/library/2.1.3/library-2.1.3.pom'. Received status code 401 from server: Unauthorized

Investigation:

看着貌似是这个库下载不下来。我点击了这个链接,能访问,但是提示要输入username和password。


Screenshot 2024-09-09 at 17 31 50

@wgllss
Copy link
Owner

wgllss commented Sep 10, 2024

在local.properties里添加: workingDirPath=/Users/gongzelong/Downloads/sdk/build-tools/32.0.0/

发现可以Gradle Sync成功。

Issue:

但是点击运行的时候就报错: Screenshot 2024-09-09 at 17 30 49

> Task :app:writeDebugSigningConfigVersions UP-TO-DATE

FAILURE: Build completed with 7 failures.

1: Task 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.wang.avi:library:2.1.3.
     Required by:
         project :app > project :wgllss-common-re-library
      > Could not resolve com.wang.avi:library:2.1.3.
         > Could not get resource 'https://jitpack.io/com/wang/avi/library/2.1.3/library-2.1.3.pom'.
            > Could not HEAD 'https://jitpack.io/com/wang/avi/library/2.1.3/library-2.1.3.pom'. Received status code 401 from server: Unauthorized

Investigation:

看着貌似是这个库下载不下来。我点击了这个链接,能访问,但是提示要输入username和password。

Screenshot 2024-09-09 at 17 31 50
你好 我这边能够拉取下来,wgllss-common-re-library 和maven-wgllss-common-re-library 工程内 我把本地 包进去了,可以注释掉放开
`dependencies {
//如果implementation 'com.wang.avi:library:2.1.3' 拉取不下来 放开下面这句注释,用本地的包
// implementation files('libs/com_wang_avi_library-2.1.3.aar')

implementation libSupportAppcompat
implementation 'androidx.activity:activity-ktx:1.3.0-rc01'
implementation 'androidx.fragment:fragment-ktx:1.4.0-alpha04'
implementation "androidx.core:core-ktx:$rootProject.ext.kotlin_version"
implementation 'com.github.bumptech.glide:glide:4.13.2'

implementation 'com.wang.avi:library:2.1.3'
implementation 'com.squareup.retrofit2:converter-gson:2.9.0'
//权限申请框架
implementation 'com.github.getActivity:XXPermissions:16.2'

}`

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