bug identifier size vary across commands

Labels: kind/bug

Timeline

https://github.com/explore (seeduvax) opened

ls command gives id with 7 char while show command gives Id with 8 char. After quick code review, it appear the HumanId method implementation is not consistent in bug.go and snapshot.go. First use a constant that is defined in the same file. Second is hard coded in the Sprintf call. A first trivial fix (very easy I may send a pull request today) is to change the hard coded value in snapshot.go (7 char seems to be the right value to match the 7 char ids generally provided in git and github). A better fix should be to use the same constant. To be defined is the way to manage such constant: into a dedicated go file or to import bug.go in snapshot.go. To be checked: is there other alternative HumanId() functions hidden elsewhere?

Michael Muré (MichaelMure) added label kind/bug

Michael Muré (MichaelMure) commented

Fixed by #90

Michael Muré (MichaelMure) closed the bug