atuinsh/atuin

[Bug]: Inspector thinks that command that exited 0 exited with -1

ednolan opened this issue · 0 comments

What did you expect to happen?

The command that I've only run once that exited successfully should have appeared in the inspector as having the exit code 0.

What happened?

The inspector showed the exit code -1:

 Atuin v18.1.0                                                                   <esc>: exit, <ctrl-o>: search, <ctrl-d>: delete                                                            history count: 22409
  Search │ Inspect
 ┌Previous command──────────────────────────────────┐┌Command──────────────────────────────────────────────────────────────────────────────────────────────┐┌Next command──────────────────────────────────────┐
 │ echo foobar                                      ││ echo foobaz                                                                                         ││ No next command                                  │
 │                                                  ││                                                                                                     ││                                                  │
 └──────────────────────────────────────────────────┘└─────────────────────────────────────────────────────────────────────────────────────────────────────┘└──────────────────────────────────────────────────┘
 ┌Command stats──────────────────────────────────────────────────────┐┌Exit code distribution──────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
 │                                                                   ││███                                                                                                                                     │
 │Time          2024-03-14 15:58:58.272938763 +00:00:00              ││███                                                                                                                                     │
 │Duration      0s                                                   ││█1█                                                                                                                                     │
 │Avg duration  0s                                                   ││-1                                                                                                                                      │
 │Exit          -1                                                   │└────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
 │Directory     /home/eddie                                          │┌Runs per day────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
 │Session       018e3d902d7c71cd8121c32e1cb978da                     ││███                                                                                                                                     │
 │Total runs    1                                                    ││███                                                                                                                                     │
 │                                                                   ││█1█                                                                                                                                     │
 │                                                                   ││Thu                                                                                                                                     │
 │                                                                   │└────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
 │                                                                   │┌Duration over time──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
 │                                                                   ││                                                                                                                                        │
 │                                                                   ││                                                                                                                                        │
 │                                                                   ││                                                                                                                                        │
 │                                                                   ││                                                                                                                                        │
 └───────────────────────────────────────────────────────────────────┘└────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘

Meanwhile, the ctrl-r view shows the command time in green, indicating a successful exit:

Screenshot 2024-03-14 at 12 02 01 PM

Atuin doctor output

Atuin Doctor
Checking for diagnostics


Please include the output below with any bug reports or issues

atuin:
  version: 18.1.0
  sync:
    cloud: false
    records: true
    auto_sync: true
    last_sync: 2024-03-14 15:56:41.874810791 +00:00:00
shell:
  name: bash
  plugins:
  - bash-preexec
  - atuin
system:
  os: Ubuntu
  arch: x86_64
  version: '22.04'
  disks:
  - name: /dev/vda1
    filesystem: ext4
  - name: /dev/vda15
    filesystem: vfat

Code of Conduct

  • I agree to follow this project's Code of Conduct