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

Print last_error.instruction in xor caught an error message #236

Open
folex opened this issue Apr 1, 2022 · 0 comments
Open

Print last_error.instruction in xor caught an error message #236

folex opened this issue Apr 1, 2022 · 0 comments
Labels
C-dx category: developer experience improvements C-good-first-issue category: good for newcomers

Comments

@folex
Copy link
Member

folex commented Apr 1, 2022

ATM, if you have a lot of errors, it looks like this

xor caught an error: value '[]' does not contain element for idx = '0'
call failed with an error `value '[]' does not contain element for idx = '0'`, peerId `12D3KooWSD5PToNiLQwKDXsu8JSysCwUt8BVUJEqCHcDe7P5h45e`
xor caught an error: value '[]' does not contain element for idx = '0'
call failed with an error `value '[]' does not contain element for idx = '0'`, peerId `12D3KooWSD5PToNiLQwKDXsu8JSysCwUt8BVUJEqCHcDe7P5h45e`
xor caught an error: value '[]' does not contain element for idx = '0'
call failed with an error `value '[]' does not contain element for idx = '0'`, peerId `12D3KooWSD5PToNiLQwKDXsu8JSysCwUt8BVUJEqCHcDe7P5h45e`
xor caught an error: value '[]' does not contain element for idx = '0'
call failed with an error `value '[]' does not contain element for idx = '0'`, peerId `12D3KooWSD5PToNiLQwKDXsu8JSysCwUt8BVUJEqCHcDe7P5h45e`
xor caught an error: value '[]' does not contain element for idx = '0'
call failed with an error `value '[]' does not contain element for idx = '0'`, peerId `12D3KooWSD5PToNiLQwKDXsu8JSysCwUt8BVUJEqCHcDe7P5h45e`
xor caught an error: value '[]' does not contain element for idx = '0'
call failed with an error `value '[]' does not contain element for idx = '0'`, peerId `12D3KooWSD5PToNiLQwKDXsu8JSysCwUt8BVUJEqCHcDe7P5h45e`
xor caught an error: value '[]' does not contain element for idx = '0'
call failed with an error `value '[]' does not contain element for idx = '0'`, peerId `12D3KooWSD5PToNiLQwKDXsu8JSysCwUt8BVUJEqCHcDe7P5h45e`

It's hard to tell what caused this. I suggest to print more information here. For example, format like this:

xor caught an error: 
\t $last_error.message 
\t on peer $last_error.peer_id
\t failed instruction: $last_error.instruction
@mikevoronov mikevoronov added C-dx category: developer experience improvements C-good-first-issue category: good for newcomers labels Apr 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-dx category: developer experience improvements C-good-first-issue category: good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants