我正在尝试使用Android Studio开发Android应用程序,因此我创建了一个Android应用程序,我想发布它.每当我点击"构建项目"来获取apk文件时,我都会收到此错误:
Error:Execution failed for task ':app:processDebugResources'.
> java.io.IOException: Could not delete folder C:\Users\ehsan\AndroidStudioProjects\MyApplication3\app\build\generated\source\r\debug\com\example\ehsan
Run Code Online (Sandbox Code Playgroud)
的build.gradle:
apply plugin: 'com.android.application'
android {
compileSdkVersion 23
buildToolsVersion "23.0.2"
defaultConfig {
applicationId "com.example.ehsan.myapplication"
minSdkVersion 15
targetSdkVersion 23
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:23.2.0'
}
Run Code Online (Sandbox Code Playgroud) 我对 React Native 相当陌生,看起来我的应用程序在执行我的主要应用程序代码之前崩溃了,但我不知道在哪里。在 VSCode 中,我在输出中看到以下内容:
Error: EPERM: operation not permitted, lstat 'c:\Dev\myapp\android\app\build\generated\not_namespaced_r_class_sources\debug\r\com\bumptech\glide\integration\okhttp'
Emitted 'error' event on NodeWatcher instance at:
at NodeWatcher.<anonymous> (c:\Dev\myapp\node_modules\sane\src\node_watcher.js:291:16)
at FSReqCallback.oncomplete (fs.js:176:21) {
errno: -4048,
code: 'EPERM',
syscall: 'lstat',
path: 'c:\\Dev\\myapp\\android\\app\\build\\generated\\not_namespaced_r_class_sources\\debug\\r\\com\\bumptech\\glide\\integration\\okhttp'
Run Code Online (Sandbox Code Playgroud)
我试图弄清楚如何确定这是从哪里来的,以及如何在将来调试此类错误。