This error should be accompanied with error: closed
in terminal when deploying the debug version of the signer on a device that runs Android older than 5.0. It happens because the Android API does not support the reverse proxy that would allow the phone to communicate with the debug server on your computer.
A suitable workaround is to run both devices on the same WiFi and use your local WiFi IP address. Check your WiFi settings for your local IP address (eg. 192.168.1.42
), then, while having the app open on the phone (either on error page or blank screen) run a command in terminal:
adb shell input keyevent 82
(You can find adb
binary in your local Android SDK folder under platform-tools
, eg. /home/your_username/Android/Sdk/platform-tools
)
This should open a menu on the device. In that menu go to Dev Settings
> Debug server host & port for device
, and enter your local IP address with port 8081 (eg. 192.168.1.42:8081
). Restart the app, the error should disappear.
If shell has this error:
error: component 'rust-std' for target 'armv7-apple-ios' is unavailable for download for channel stable
Please switch rustup toolchains to version 1.41.1
with rustup default 1.41.1
since from 1.42.0 rust dropped 32-bit apple target support), the latest version for building ios target is 1.41.1.
yarn clean
yarn install
cd ios && pod install && cd ..
- delete app on device
yarn start --reset-cache
- in Xcode (be sure to open with
./ios/stylo-app.xcodeworkspace
file), clean build withshift + command + K
yarn run ios
- clean build with
cd android && ./gradlew clean && cd ..
yarn run android
- erase simulator data on iOS Simulator with
Device
->Erase all content and settings
yarn clean && yarn
yarn start --reset-cache
- build & run as above