separate CI steps more clearly
Some checks are pending
Cache Dependencies / test (push) Waiting to run

Add more info to error reports
This commit is contained in:
OmarHatem 2024-12-10 14:06:56 +02:00
parent 5553d5c9cb
commit 35cf4a716f
3 changed files with 25 additions and 5 deletions

View file

@ -61,6 +61,14 @@ jobs:
sudo apt update sudo apt update
sudo apt-get install -y curl unzip automake build-essential file pkg-config git python libtool libtinfo5 cmake clang sudo apt-get install -y curl unzip automake build-essential file pkg-config git python libtool libtinfo5 cmake clang
- name: Clone Repo
run: |
sudo mkdir -p /opt/android
sudo chown $USER /opt/android
cd /opt/android
git clone https://github.com/cake-tech/cake_wallet.git --branch ${{ env.BRANCH_NAME }}
- name: Cache Keystore - name: Cache Keystore
id: cache-keystore id: cache-keystore
uses: actions/cache@v3 uses: actions/cache@v3
@ -76,12 +84,9 @@ jobs:
- name: Execute Build and Setup Commands - name: Execute Build and Setup Commands
run: | run: |
sudo mkdir -p /opt/android
sudo chown $USER /opt/android
cd /opt/android cd /opt/android
-y curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -y curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
cargo install cargo-ndk cargo install cargo-ndk
git clone https://github.com/cake-tech/cake_wallet.git --branch ${{ env.BRANCH_NAME }}
cd cake_wallet/scripts/android/ cd cake_wallet/scripts/android/
./install_ndk.sh ./install_ndk.sh
source ./app_env.sh cakewallet source ./app_env.sh cakewallet

View file

@ -198,8 +198,9 @@ class TOTPEnterCode extends BasePage {
}, },
); );
if (isForSetup && result) { if (isForSetup && result) {
Navigator.pushReplacementNamed( if (context.mounted) {
context, Routes.modify2FAPage); Navigator.pushReplacementNamed(context, Routes.modify2FAPage);
}
} }
}, },

View file

@ -1,9 +1,11 @@
import 'dart:io'; import 'dart:io';
import 'package:cake_wallet/di.dart';
import 'package:cake_wallet/entities/preferences_key.dart'; import 'package:cake_wallet/entities/preferences_key.dart';
import 'package:cake_wallet/generated/i18n.dart'; import 'package:cake_wallet/generated/i18n.dart';
import 'package:cake_wallet/main.dart'; import 'package:cake_wallet/main.dart';
import 'package:cake_wallet/src/widgets/alert_with_two_actions.dart'; import 'package:cake_wallet/src/widgets/alert_with_two_actions.dart';
import 'package:cake_wallet/store/app_store.dart';
import 'package:cake_wallet/utils/show_bar.dart'; import 'package:cake_wallet/utils/show_bar.dart';
import 'package:cake_wallet/utils/show_pop_up.dart'; import 'package:cake_wallet/utils/show_pop_up.dart';
import 'package:cw_core/root_dir.dart'; import 'package:cw_core/root_dir.dart';
@ -29,9 +31,21 @@ class ExceptionHandler {
_file = File('${appDocDir.path}/error.txt'); _file = File('${appDocDir.path}/error.txt');
} }
String? walletType;
CustomTrace? programInfo;
try {
walletType = getIt.get<AppStore>().wallet?.type.name;
programInfo = CustomTrace(stackTrace ?? StackTrace.current);
} catch (_) {}
final exception = { final exception = {
"${DateTime.now()}": { "${DateTime.now()}": {
"Error": "$error\n\n", "Error": "$error\n\n",
"WalletType": "$walletType\n\n",
"VerboseLog":
"${programInfo?.fileName}#${programInfo?.lineNumber}:${programInfo?.columnNumber} ${programInfo?.callerFunctionName}\n\n",
"Library": "$library\n\n", "Library": "$library\n\n",
"StackTrace": stackTrace.toString(), "StackTrace": stackTrace.toString(),
} }