Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lines of code is showing 0 for several repositories that used to count lines OK #7569

Open
sgbaird opened this issue Feb 5, 2022 · 11 comments 路 May be fixed by #9581
Open

Lines of code is showing 0 for several repositories that used to count lines OK #7569

sgbaird opened this issue Feb 5, 2022 · 11 comments 路 May be fixed by #9581
Labels
needs-upstream-help Not actionable without help from a service provider

Comments

@sgbaird
Copy link

sgbaird commented Feb 5, 2022

Are you experiencing an issue with...

shields.io

馃悶 Description

See https://github.com/sparks-baird/mat_discover and https://github.com/sgbaird-5DOF/interp for example. If it's not showing "lines 0" when you open this, then I'll assume this was fixed. Not sure if the issue is on the shields.io side or the tokei side.

馃敆 Link to the badge

https://img.shields.io/tokei/lines/github/sparks-baird/mat_discover

馃挕 Possible Solution

No response

@sgbaird sgbaird added the question Support questions, usage questions, unconfirmed bugs, discussions, ideas label Feb 5, 2022
@PyvesB
Copy link
Member

PyvesB commented Feb 5, 2022

Hello @sgbaird ! 馃憢

Thanks for reporting this! Our Tokei tests have started failing as well.

It does seem like a problem on the Tokei side, hitting the API for the sparks-baird/mat_discover repository, I get the following response:

{"blanks":0,"code":0,"comments":0,"lines":0,"stats":[],"inaccurate":false}

Other users have also reported this problematic behaviour here: XAMPPRocky/tokei#881

@PyvesB PyvesB added needs-upstream-help Not actionable without help from a service provider service-badge Accepted and actionable changes, features, and bugs bug Bugs in badges and the frontend and removed question Support questions, usage questions, unconfirmed bugs, discussions, ideas labels Feb 5, 2022
@calebcartwright calebcartwright removed bug Bugs in badges and the frontend service-badge Accepted and actionable changes, features, and bugs labels Feb 7, 2022
@calebcartwright
Copy link
Member

Things appear to have been sorted upstream so going to close. If there's any recurrence in the near term please feel free to post here and we can reopen.

If anyone significantly in the future sees similar symptoms, it's probably better to open a new issue

@calebcartwright
Copy link
Member

Reopening as the upstream issue has recurred

@librity
Copy link

librity commented May 1, 2022

I'm having the same problem. Examples:
Lines of code
Lines of code
Lines of code
Lines of code

@calebcartwright
Copy link
Member

calebcartwright commented May 1, 2022

Folks, please refrain from posting the "me too" types of comments as they just add unhelpful noise. The above thread already contains relevant information explaining that the issue is upstream.

Shields.io is not a system of record. It doesn't provide CI/pipeline capabilities, and it doesn't count lines of code either. We have to get the data from the relevant upstream endpoint, and we then display whatever data the upstream system of record provides. The upstream system in this case is Tokei, and they've been having this recurring issue for quite some time, as indicated above in the linked tokei issues. Tokei is the service responsible for counting lines of code, and for whatever reason it intermittently claims the count is 0, and thus 0 is displayed on the badges.

There's absolutely nothing we can do about this, so I'd encourage you to subscribe to those issues in the tokei repository if you're interested in receiving updates.

@librity
Copy link

librity commented May 1, 2022

Folks, please refrain from posting the "me too" types of comments as they just add unhelpful noise. The above thread already contains relevant information explaining that the issue is upstream.

Shields.io is not a system of record. It doesn't provide CI/pipeline capabilities, and it doesn't count lines of code either. We have to get the data from the relevant upstream endpoint, and we then display whatever data the upstream system of record provides. The upstream system in this case is Tokei, and they've been having this recurring issue for quite some time, as indicated above in the linked tokei issues. Tokei is the service responsible for counting lines of code, and for whatever reason it intermittently claims the count is 0, and thus 0 is displayed on the badges.

There's absolutely nothing we can do about this, so I'd encourage you to subscribe to those issues in the tokei repository if you're interested in receiving updates.

I will, thanks.

@hongbo-miao
Copy link

Maybe a new shields badge using this service https://github.com/boyter/scc might help 馃槂

@AleixMT
Copy link

AleixMT commented Jul 27, 2023

Hello. I wanted to say that I have a similar issue with the lines of code badge too. The badge always say "Invalid response data". I tried with many repositories and I also tried giving shields.io more permissions, but the message is still shown.

Here is the badge that I want to show:
Lines of code

The shield has the following URL: https://img.shields.io/tokei/lines/github/AleixMT/eChempad

Thank you for your response and for this wonderful project.

@chris48s
Copy link
Member

I think this is a duplicate of #9389 and the upstream issue is XAMPPRocky/tokei_rs#233

@ghost
Copy link

ghost commented Jul 29, 2023

I think this is a duplicate of #9389 and the upstream issue is XAMPPRocky/tokei_rs#233

#9389 was created much later?

@chris48s
Copy link
Member

OK well #9389 is a duplicate of this.

The main point was I wanted to link to the upstream issue with tokei as this issue was bumped recently.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-upstream-help Not actionable without help from a service provider
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants