Onebox of github commits overview is just the onebox of the first commit

Hello,

for the link https://github.com/beta-europe/www.beta-europe.org/commits/master, I expected to have a onebox different from a precise commit. This is a bit misleading.

Onebox for the link above:

(edit by @david: screenshot of the old result, for future reference)

https://github.com/beta-europe/www.beta-europe.org/commits/master

4 Likes

Agree, we can do better here #pr-welcome

3 Likes

Links leading to issues and pull requests overview both render whitelistedgeneric onebox:

https://github.com/rails/rails/issues
https://github.com/rails/rails/pulls

Should the same happen when adding a link to commit history as well?

1 Like

As Maja suggested, links to multiple commits will now be rendered using the whitelistedgeneric onebox

https://github.com/discourse/onebox/commit/4103d115c199458a9a9368e5962dd20e674abf52

Unfortunately the opengraph data which github provides for these URLs is generic - it will just show the repo name/description. However, I still think this is less confusing than arbitrarily rendering the first commit.

A brand new onebox for these “multi-commit” links would still be #pr-welcome, if someone would like to try it.

5 Likes