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

"invalid response data" in total lines #9389

Closed
ghost opened this issue Jul 16, 2023 · 9 comments
Closed

"invalid response data" in total lines #9389

ghost opened this issue Jul 16, 2023 · 9 comments
Labels
needs-upstream-help Not actionable without help from a service provider service-badge Accepted and actionable changes, features, and bugs

Comments

@ghost
Copy link

ghost commented Jul 16, 2023

Are you experiencing an issue with...

shields.io

馃悶 Description

I'm using the total lines badge, and I'm getting an "invalid response data" error. Here is a screenshot:
Screen Shot 2023-07-15 at 7 20 57 PM

I've gotten this error before, so it's not like I had a bad day today 馃槄

As for the repository I'm trying to access, it can be viewed at dishb/hive. So the repository does indeed exist.

馃敆 Link to the badge

Here is the badge in markdown:
Lines of code

The code:
![Lines of code](https://img.shields.io/tokei/lines/github/dishb/hive)

The URL:
https://img.shields.io/tokei/lines/github/dishb/hive

馃挕 Possible Solution

No response

@ghost ghost added the question Support questions, usage questions, unconfirmed bugs, discussions, ideas label Jul 16, 2023
@chris48s
Copy link
Member

The reason this is failing is because the response from tokei does not have a lines property. The detailed error is ValidationError: "lines" is required

I am also seeing this on the responses for other repos. I'm going to raise an issue for this one upstream.

@chris48s chris48s added needs-upstream-help Not actionable without help from a service provider service-badge Accepted and actionable changes, features, and bugs and removed question Support questions, usage questions, unconfirmed bugs, discussions, ideas labels Jul 16, 2023
@ghost
Copy link
Author

ghost commented Jul 16, 2023

Okay, thank you.

@chris48s
Copy link
Member

follow XAMPPRocky/tokei_rs#233 for updates

@ghost
Copy link
Author

ghost commented Jul 16, 2023

Just checked the API docs, maybe the correct way to access the lines of code from the response is through code?

EDIT: In the actual response (I got the response by running curl "https://tokei.rs/b1/github/dishb/hive" -H "Accept: application/json"), it looks like code isn't the correct attribute as it appears multiple times...?

@ashuthe1
Copy link

Hi! I am new to this community and would love to work on this.

@ghost
Copy link
Author

ghost commented Jul 22, 2023

@ashuthe1 - You'd probably need to ask to be assigned to this issue. If you noticed, the needs-upstream-help tag means this isn't necessarily an issue with shields but with one of its service providers.

@calebcartwright
Copy link
Member

Yeah appreciate the offer @ashuthe1 but there's nothing we can do here and are blocked on the upstream issue.

If you're just interested in getting involved with Shields more generally there's a number of other issues you could potentially look at, and I'd suggest starting with these: https://github.com/badges/shields/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22

@ashuthe1
Copy link

@calebcartwright thank you so much, I will look into good first issue first.

@ghost
Copy link
Author

ghost commented Jul 29, 2023

Duplicate of #7569.

This issue was closed.
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 service-badge Accepted and actionable changes, features, and bugs
Projects
None yet
Development

No branches or pull requests

3 participants