App Crashing on Launch when starting a geth node

78 Views Asked by At

I'm trying to start a geth node on android but my app crashes after launching, here is the error it is telling me in my logcat :

2021-04-21 15:36:45.503 9575-9575/? I/om.example.get: Not late-enabling -Xcheck:jni (already on) 2021-04-21 15:36:45.540 9575-9575/? I/om.example.get: Unquickening 12 vdex files! 2021-04-21 15:36:45.545 9575-9575/? W/om.example.get: Unexpected CPU variant for X86 using defaults: x86 2021-04-21 15:36:46.112 9575-9575/com.example.geth D/NetworkSecurityConfig: No Network Security Config specified, using platform default 2021-04-21 15:36:46.122 9575-9575/com.example.geth D/NetworkSecurityConfig: No Network Security Config specified, using platform default 2021-04-21 15:36:46.225 9575-9602/com.example.geth D/libEGL: loaded /vendor/lib/egl/libEGL_emulation.so 2021-04-21 15:36:46.232 9575-9602/com.example.geth D/libEGL: loaded /vendor/lib/egl/libGLESv1_CM_emulation.so 2021-04-21 15:36:46.268 9575-9602/com.example.geth D/libEGL: loaded /vendor/lib/egl/libGLESv2_emulation.so 2021-04-21 15:36:46.862 9575-9575/com.example.geth W/om.example.get: Accessing hidden method Landroid/view/View;->computeFitSystemWindows(Landroid/graphics/Rect;Landroid/graphics/Rect;)Z (greylist, reflection, allowed) 2021-04-21 15:36:46.863 9575-9575/com.example.geth W/om.example.get: Accessing hidden method Landroid/view/ViewGroup;->makeOptionalFitsSystemWindows()V (greylist, reflection, allowed) 2021-04-21 15:36:47.108 9575-9575/com.example.geth W/om.example.get: Accessing hidden method Landroid/app/AppGlobals;->getInitialApplication()Landroid/app/Application; (greylist, reflection, allowed) 2021-04-21 15:36:47.109 9575-9603/com.example.geth A/libc: Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 9603 (om.example.geth), pid 9575 (om.example.geth)

log image

In my MainActivity.java:

public class MainActivity extends AppCompatActivity {

    private TextView accDisplayTextView;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

        accDisplayTextView = findViewById(R.id.acc_display_textview);

        try {
            NodeConfig nc = new NodeConfig();
            Node node = Geth.newNode(getFilesDir() + "/.ethNode", nc);
            node.start();

            GethNodeHolder gethNode = GethNodeHolder.getInstance();
            gethNode.setNode(node);

        } catch (Exception e) {
            Log.e("error: ", e.getMessage());
            e.printStackTrace();
        }
    }
}

main activity image

and my other error is that java can't resolve keystore class from org.ethereum.geth package:

import org.ethereum.geth.KeyStore

import error image

Can you help me please

0

There are 0 best solutions below