Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Element R: add, and log, msgids to outgoing to-device messages #25722

Closed
richvdh opened this issue Jul 5, 2023 · 4 comments
Closed

Element R: add, and log, msgids to outgoing to-device messages #25722

richvdh opened this issue Jul 5, 2023 · 4 comments

Comments

@richvdh
Copy link
Member

richvdh commented Jul 5, 2023

... to help with diagnosing where they are coming from, and going to.

This might just be a matter of turning on the rust-sdk feature in matrix-org/matrix-rust-sdk#1946. But we need to make sure that the msgids get logged at tx time.

@richvdh
Copy link
Member Author

richvdh commented Oct 3, 2023

A couple of problems here.

  1. When I turn on the feature, I get this spew when trying to send an encrypted event:
panicked at /home/rav/work/matrix-rust-sdk/crates/matrix-sdk-crypto/src/session_manager/group_sessions.rs:699:30:
We should be able to deserialize the content we generated: Error("missing field `org.matrix.msgid`", line: 1, column: 1252)

Stack:

1799/</module.exports.__wbg_new_abda76e883ba8a5f@http://localhost:8080/bundles/_dev_/17.js:7133:17
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[2726]:0x29389f
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[17071]:0x3e1296
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[4031]:0x2e5c29
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[5420]:0x324c9c
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[8727]:0x38665a
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[11467]:0x3b6c1c
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[6425]:0x348154
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[692]:0x1862a0
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[191]:0x3d188
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[9885]:0x39d637
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[510]:0x141bef
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[2784]:0x298246
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[2650]:0x28d9bf
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[14309]:0x3d506a
__wbg_adapter_59@http://localhost:8080/bundles/_dev_/17.js:366:10
real@http://localhost:8080/bundles/_dev_/17.js:308:20
promise callback*1799/</module.exports.__wbg_then_11f7a54d67b4bfad@http://localhost:8080/bundles/_dev_/17.js:7665:33
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[6986]:0x3598f1
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[8123]:0x37848e
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[10533]:0x3a8896
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[12095]:0x3bedea
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[4465]:0x2fb6c5
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[3102]:0x2aef69
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[4094]:0x2e9146
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[2650]:0x28d9bf
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[14309]:0x3d506a
__wbg_adapter_59@http://localhost:8080/bundles/_dev_/17.js:366:10
real@http://localhost:8080/bundles/_dev_/17.js:308:20
promise callback*1799/</module.exports.__wbg_then_11f7a54d67b4bfad@http://localhost:8080/bundles/_dev_/17.js:7665:33
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[6986]:0x3598f1
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[8123]:0x37848e
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[10533]:0x3a8896
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[12095]:0x3bedea
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[4465]:0x2fb6c5
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[3104]:0x2af1a6
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[4093]:0x2e9062
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[2650]:0x28d9bf
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[14309]:0x3d506a
__wbg_adapter_59@http://localhost:8080/bundles/_dev_/17.js:366:10
real@http://localhost:8080/bundles/_dev_/17.js:308:20
promise callback*1799/</module.exports.__wbg_then_11f7a54d67b4bfad@http://localhost:8080/bundles/_dev_/17.js:7665:33
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[6986]:0x3598f1
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[9242]:0x3913d3
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[6078]:0x33c825
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[8925]:0x38abdc
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[3746]:0x2d6998
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[4148]:0x2ebecb
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[259]:0xb80b6
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[10100]:0x3a1323
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[5206]:0x31c1fc
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[4094]:0x2e910a
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[2650]:0x28d9bf
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[14309]:0x3d506a
__wbg_adapter_59@http://localhost:8080/bundles/_dev_/17.js:366:10
real@http://localhost:8080/bundles/_dev_/17.js:308:20
promise callback*1799/</module.exports.__wbg_then_11f7a54d67b4bfad@http://localhost:8080/bundles/_dev_/17.js:7665:33
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[6986]:0x3598f1
@http://localhost:8080/bundles/_dev_/17.js line 7856 > WebAssembly.instantiate:wasm-function[9242]:0x3913d3


[rageshake.ts:74:27](webpack:///matrix-react-sdk/src/rageshake/rageshake.ts)
15:27:51.141
Uncaught (in promise) RuntimeError: unreachable executed
    __wbg_adapter_59 matrix_sdk_crypto_wasm.js:274
    real matrix_sdk_crypto_wasm.js:216
    promise callback*1799/</module.exports.__wbg_then_11f7a54d67b4bfad matrix_sdk_crypto_wasm.js:7573
    __wbg_adapter_59 matrix_sdk_crypto_wasm.js:274
    real matrix_sdk_crypto_wasm.js:216
    promise callback*1799/</module.exports.__wbg_then_11f7a54d67b4bfad matrix_sdk_crypto_wasm.js:7573
    __wbg_adapter_59 matrix_sdk_crypto_wasm.js:274
    real matrix_sdk_crypto_wasm.js:216
    promise callback*1799/</module.exports.__wbg_then_11f7a54d67b4bfad matrix_sdk_crypto_wasm.js:7573
    __wbg_adapter_59 matrix_sdk_crypto_wasm.js:274
    real matrix_sdk_crypto_wasm.js:216
    promise callback*1799/</module.exports.__wbg_then_11f7a54d67b4bfad matrix_sdk_crypto_wasm.js:7573
  1. Incoming to-device messages are passed to OlmMachine::record_message_id, which stores the message id in the tracing span... which isn't propagated to the javascript console.

@richvdh richvdh removed their assignment Oct 11, 2023
@richvdh
Copy link
Member Author

richvdh commented Oct 17, 2023

point 2 will be fixed by matrix-org/matrix-rust-sdk-crypto-wasm#40

@richvdh
Copy link
Member Author

richvdh commented Oct 18, 2023

Whatever caused point 1 before seems to have gone away.

I still find the actual log output a bit incomprehensible, though

@richvdh richvdh self-assigned this Oct 19, 2023
@richvdh
Copy link
Member Author

richvdh commented Oct 20, 2023

Log improvements at matrix-org/matrix-rust-sdk#2747 and matrix-org/matrix-js-sdk#3810

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants