Docs/guide about debugging crashes for java developers

Aperta
#683 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
52/100
Tipo di issue
Documentazione
Chiarezza
Abbastanza chiara
Stato di attività
Tranquilla
Stack tecnologico
java, swift
Ambito
documentation

Direzione di ricerca

Parti dall’output del crash nell’issue e dal comando swift demangle menzionato; nel payload non è identificato alcun file di documentazione né alcun test. La guida dovrebbe spiegare come gli sviluppatori Java possono analizzare i crash Swift e demanglare gli stack frame nativi, usando l’esempio fornito come riferimento per completarla.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

documentation

It's important to teach how java developers can debug crashes in swift.

E.g. a crash


     Stack: [0x000000016d7c8000,0x000000016d9cb000],  sp=0x000000016d9c5d10,  free space=2039k
     Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
     V  [libjvm.dylib+0x579b14]  jni_GetArrayLength+0x108
     C  [libSwiftJava.dylib+0x1a1dc4]  $sSa16SwiftJavaJNICoreAA0B5ValueRzlE7fromJNI2inSayxGSvSg_SpySPySo18JNINativeInterfaceVGSgGtcfC+0x118
     C  [libSwiftJava.dylib+0x1a4c24]  $sSayxG16SwiftJavaJNICore0B5ValueA2bCRzlAbCP7fromJNI2inx7JNITypeQz_SpySPySo18JNINativeInterfaceVGSgGtcfCTW+0x20
     C  [libSwiftJava.dylib+0x1a277c]  $sSa16SwiftJavaJNICoreAA0B5ValueRzlE7fromJNI2inSayxGSvSg_SpySPySo18JNINativeInterfaceVGSgGtcfcx7JNITypeQzXEfU2_+0xb8
     C  [libSwiftJava.dylib+0x1a27bc]  $sSa16SwiftJavaJNICoreAA0B5ValueRzlE7fromJNI2inSayxGSvSg_SpySPySo18JNINativeInterfaceVGSgGtcfcx7JNITypeQzXEfU2_TA+0x2c
     C  [libSwiftJava.dylib+0x1988]  $sSlsE3mapySayqd__Gqd__7ElementQzqd_0_YKXEqd_0_YKs5ErrorRd_0_r0_lF+0x400
     C  [libSwiftJava.dylib+0x1a2150]  $sSa16SwiftJavaJNICoreAA0B5ValueRzlE7fromJNI2inSayxGSvSg_SpySPySo18JNINativeInterfaceVGSgGtcfC+0x4a4
     C  [libMySwiftLibrary.dylib+0x36670]
     $s14MySwiftLibrary023Java_com_example_swift_abC29__00024nestedByteArray___3_3B11environment9thisClass5arraySvSgSpySPySo18JNINativeInterfaceVGSgGSg_SvAFtF+0xe8
     C  [libMySwiftLibrary.dylib+0x36580]  Java_com_example_swift_MySwiftLibrary__00024nestedByteArray___3_3B+0xc
     j  com.example.swift.MySwiftLibrary.$nestedByteArray([[B)[[B+0
     j  com.example.swift.MySwiftLibrary.nestedByteArray([[B)[[B+9
     j  com.example.swift.ArraysTest.lambda$nestedByteArray_null$1()V+24
     j  com.example.swift.ArraysTest$$Lambda+0x0000060001166dc0.execute()V+0
     j  org.junit.jupiter.api.AssertThrows.assertThrows(Ljava/lang/Class;Lorg/junit/jupiter/api/function/Executable;Ljava/lang/Object;)Ljava/lang/Throwable;+1
     j  org.junit.jupiter.api.AssertThrows.assertThrows(Ljava/lang/Class;Lorg/junit/jupiter/api/function/Executable;)Ljava/lang/Throwable;+3
     j  org.junit.jupiter.api.Assertions.assertThrows(Ljava/lang/Class;Lorg/junit/jupiter/api/function/Executable;)Ljava/lang/Throwable;+2
     j  com.example.swift.ArraysTest.nestedByteArray_null()V+18

can be demangled using cat ... | swift demangle but java developers may not know about this etc.

Lingua principale
Swift
Stelle
1.3k
Fork
127
Merge medio
2g 14h
PR unite (30g)
5

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di swiftlang/swift-java

Tutte le issue di swiftlang/swift-java

Issue simili

Altre issue su Swift

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.