sourcegraph/sourcegraph-git-extras

No blame info on files with spaces

sqs opened this issue · 1 comments

sqs commented

https://sourcegraph.sgdev.org/github.com/sourcegraph/Graphbook/-/blob/Dev%20lingo%20for%20non-devs.md?view=code#L15

No blame info is shown at the end of the line, even with blame enabled. Possibly a bug when viewing the raw (non-Markdown-rendered) file?

image

Issues here:

  • URI is not decoded. Error from backend is git ls-tree Dev%20lingo%20for%20non-devs.md: file does not exist
  • String concatenation with an object, resulting in [object Object] being logged.

This is a good example btw of how dangerous it is that a core feature like blame has seen no code review and has no tests - these two issues that could have easily been caught through review.