Empty top languages card #1789
-
I have an empty Top Languages (https://github-readme-stats.vercel.app/api/top-langs/?username=a-menshchikov): Could you explain why? Previously I have thought that it's a temporary bug, but I see it more than 6 months. |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
@a-menshchikov Thanks for your issue. I checked your problem and it seems that something goes wrong while trying to fetch language data for your username using the GraphQL API. You can see this in action by using the following query in the graphql explorer: query userInfo($login: String!) {
user(login: $login) {
# fetch only owner repos & not forks
repositories(ownerAffiliations: OWNER, isFork: false, first: 100) {
nodes {
name
languages(first: 10, orderBy: {field: SIZE, direction: DESC}) {
edges {
size
node {
color
name
}
}
}
}
}
}
} You can then use the following in the query variables field. {"login": "a-menshchikov"} Fetching the user stats for your account doesn't cause any problems: query userInfo($login: String!) {
user(login: $login) {
repositories(first: 100, orderBy: {direction: DESC, field: STARGAZERS}) {
totalCount
nodes {
name
stargazers {
totalCount
}
}
}
}
} However, I noticed that you only have forks after looking through your repositories. We currently do not fetch data from forks only from parent repositories. This behaviour can be seen by changing the |
Beta Was this translation helpful? Give feedback.
-
I agree that this behaviour should be documented. A feature request for also counting language information for code that is found in forks can be found in #1437. I will close this issue for now. Feel free to comment if you still need help. |
Beta Was this translation helpful? Give feedback.
-
Related to #1790. |
Beta Was this translation helpful? Give feedback.
@a-menshchikov Thanks for your issue. I checked your problem and it seems that something goes wrong while trying to fetch language data for your username using the GraphQL API. You can see this in action by using the following query in the graphql explorer:
You can then use the…