Are you experiencing an issue with...
:beetle: Description
:link: Link to the badge
Originally I thought one Code Climate badge through Shields is not working. It turns out it is case sensitive.
Badge from Shields
1) Username: Hongbo-Miao


2) Username: hongbo-miao


:bulb: Possible Solution
If the username is not case sensitive, that will be better user experience!
BTW, thanks for the cool library!
That's because with the native CodeClimate badge, you are using the repo ID directly. The Shields experience allows users to specify their user and repo names, which we are internally using to call a CC api to determine the repo id. That CC Repositories API is apparently case sensitive on the GitHub slug, which is not something we can control.
To see why this is happening, compare the results of:
https://api.codeclimate.com/v1/repos?github_slug=Hongbo-Miao/hongbomiao.com
with:
https://api.codeclimate.com/v1/repos?github_slug=hongbo-miao/hongbomiao.com
Within Shields, we have no way of knowing what the "correct" case should be for any given GitHub owner/repo value so I don't see anything we could do within Shields to allow our users to specify any case.
If this is something you'd really like to see, then you'll probably need to reach out to the CodeClimate team to see if they can make their Repositories API case insensitive on the GitHub Slug query parameter.
@calebcartwright Thanks, I think you are right! I guess it will be their API experience issue.
Most helpful comment
That's because with the native CodeClimate badge, you are using the repo ID directly. The Shields experience allows users to specify their user and repo names, which we are internally using to call a CC api to determine the repo id. That CC Repositories API is apparently case sensitive on the GitHub slug, which is not something we can control.
To see why this is happening, compare the results of:
https://api.codeclimate.com/v1/repos?github_slug=Hongbo-Miao/hongbomiao.com
with:
https://api.codeclimate.com/v1/repos?github_slug=hongbo-miao/hongbomiao.com
Within Shields, we have no way of knowing what the "correct" case should be for any given GitHub owner/repo value so I don't see anything we could do within Shields to allow our users to specify any case.
If this is something you'd really like to see, then you'll probably need to reach out to the CodeClimate team to see if they can make their Repositories API case insensitive on the GitHub Slug query parameter.