We should definitely do this. It won't be as straightforward as just reading an additional field off the API result however since repository information is not included directly with the issue details. There is this field
If you call the languages_url you get something like this
{
"Go": 16965,
"JavaScript": 5957,
"CSS": 4965
}
That object is language mapped to the number of bytes in the repo. In this case Go shows first because I've vendored our third party dependencies and we are using CDNs for JS and CSS deps.
For many web apps that commit third party JS and CSS we would probably see one of those show up as the "top language" even if they aren't necessarily the most "important" language people might want to see. For that reason we should probably show all of the languages somehow.
Now making 1 or 2 extra http calls for every issue we find is going to get pretty expensive. We may need to look into caching. HOWEVER let's focus on getting this working correctly first then we can worry about getting it fast.
We should definitely do this. It won't be as straightforward as just reading an additional field off the API result however since repository information is not included directly with the issue details. There is this field
If you hit that it will tell you a bunch of repo information including these fields
If you call the
languages_url
you get something like thisThat object is language mapped to the number of bytes in the repo. In this case Go shows first because I've vendored our third party dependencies and we are using CDNs for JS and CSS deps.
For many web apps that commit third party JS and CSS we would probably see one of those show up as the "top language" even if they aren't necessarily the most "important" language people might want to see. For that reason we should probably show all of the languages somehow.
Now making 1 or 2 extra http calls for every issue we find is going to get pretty expensive. We may need to look into caching. HOWEVER let's focus on getting this working correctly first then we can worry about getting it fast.