已配置ANDROID_SDK_ROOT,expo-development-client仍无法找到Android SDK
Expo run:Android 问题排查记录
已完成的排查操作
- 反复确认在
~/.zshrc文件中配置了ANDROID_SDK_ROOT环境变量,执行source ~/.zshrc使其生效,且在运行expo run:android前验证变量可用 - 在Android SDK Manager中设置了SDK路径
- 更新了expo-development-client
- 运行过
expo doctor - 冷启动重启Android模拟器
- 检查Android及SDK文件夹权限,均标记为可执行,权限归属当前用户及staff组
~/Library/Android/sdk 文件夹内容
build-tools cmdline-tools emulator licenses patcher platform-tools platforms skins sources system-images
环境版本信息
- MacOS Monterey 12.4
- 设备:2021年末款Apple M1 Pro笔记本
- node v16.17.0
项目package.json依赖
"dependencies": { "@expo/vector-icons": "^13.0.0", "@miblanchard/react-native-slider": "^2.1.0", "@react-navigation/bottom-tabs": "^6.0.5", "@react-navigation/drawer": "^6.4.3", "@react-navigation/native": "^6.0.2", "@react-navigation/native-stack": "^6.1.0", "@reduxjs/toolkit": "^1.8.2", "awesome-debounce-promise": "^2.1.0", "axios": "^0.27.2", "babel-plugin-dotenv-import": "^2.2.0", "expo": "~45.0.0", "expo-asset": "~8.5.0", "expo-constants": "~13.1.1", "expo-dev-client": "~1.0.1", "expo-font": "~10.1.0", "expo-linking": "~3.1.0", "expo-secure-store": "~11.2.0", "expo-splash-screen": "~0.15.1", "expo-status-bar": "~1.3.0", "expo-web-browser": "~10.2.1", "hooks": "^0.3.2", "moment": "^2.29.4", "react": "17.0.2", "react-dom": "17.0.2", "react-hook-form": "^7.33.0", "react-native": "0.68.2", "react-native-confirmation-code-field": "^7.3.0", "react-native-dropdown-picker": "^5.4.2", "react-native-email": "^2.1.0", "react-native-gesture-handler": "~2.2.1", "react-native-modal-dropdown": "^1.0.2", "react-native-reanimated": "2.8.0", "react-native-safe-area-context": "4.2.4", "react-native-screens": "~3.11.1", "react-native-svg": "12.3.0", "react-native-swipe-list-view": "^3.2.9", "react-native-web": "0.17.7", "react-redux": "^8.0.2", "rithmm-api-client-ts": "^0.42.0", "styled-components": "^5.3.5" }, "devDependencies": { "@babel/core": "^7.12.9", "@svgr/webpack": "^6.3.1", "@types/react": "~17.0.21", "@types/react-native": "~0.67.6", "@types/react-native-modal-dropdown": "^0.7.2", "@types/styled-components": "^5.1.6", "@types/styled-components-react-native": "^5.1.3", "expo-cli": "^5.5.1", "expo-updates": "^0.13.3", "file-loader": "^6.2.0", "jest": "^26.6.3", "jest-expo": "^45.0.0", "react-native-dotenv": "^3.3.1", "react-test-renderer": "17.0.2", "typescript": "~4.3.5" }
内容的提问来源于stack exchange,提问作者Anne
相关产品推荐
相关产品推荐

