Description
For accounts with enough contribution data, the action's single GraphQL query can exceed GitHub's per-query resource limit. The GraphQL response contains data.user: null plus a RESOURCE_LIMITS_EXCEEDED error, but fetchData dereferences result.user.repositories first, so the action reports a misleading error:
TypeError: Cannot read properties of null (reading 'repositories')
at Object.fetchData (.../dist/index.js:1160:31)
This reproduces with v0.9.3 on qstommyshu. A public failing run is available at https://github.com/qstommyshu/qstommyshu/actions/runs/29690371983.
GraphQL response
{
"data": { "user": null },
"errors": [{
"type": "RESOURCE_LIMITS_EXCEEDED",
"path": ["user", "contributionsCollection", "contributionCalendar"],
"message": "Resource limits for this query exceeded."
}]
}
The full-year query fails consistently, while the same fields queried one quarter at a time succeed. This is not the hourly GraphQL point limit and reproduces with both a PAT and the workflow's built-in GITHUB_TOKEN.
Expected behavior
The action should still generate the contribution graph when the full-range query exceeds GitHub's per-query resource limit, or at minimum surface the GraphQL error rather than throwing while dereferencing user.
Proposed fix
Keep the existing single-query fast path. Only after the specific resource-limit error:
- fetch contributions in quarterly ranges;
- fetch repository statistics separately and retain existing pagination;
- merge totals, languages, and unique contribution dates;
- recalculate contribution levels from the maximum daily count across the full merged range.
I have a tested patch ready and will link the PR here.
Description
For accounts with enough contribution data, the action's single GraphQL query can exceed GitHub's per-query resource limit. The GraphQL response contains
data.user: nullplus aRESOURCE_LIMITS_EXCEEDEDerror, butfetchDatadereferencesresult.user.repositoriesfirst, so the action reports a misleading error:This reproduces with v0.9.3 on
qstommyshu. A public failing run is available at https://github.com/qstommyshu/qstommyshu/actions/runs/29690371983.GraphQL response
{ "data": { "user": null }, "errors": [{ "type": "RESOURCE_LIMITS_EXCEEDED", "path": ["user", "contributionsCollection", "contributionCalendar"], "message": "Resource limits for this query exceeded." }] }The full-year query fails consistently, while the same fields queried one quarter at a time succeed. This is not the hourly GraphQL point limit and reproduces with both a PAT and the workflow's built-in
GITHUB_TOKEN.Expected behavior
The action should still generate the contribution graph when the full-range query exceeds GitHub's per-query resource limit, or at minimum surface the GraphQL error rather than throwing while dereferencing
user.Proposed fix
Keep the existing single-query fast path. Only after the specific resource-limit error:
I have a tested patch ready and will link the PR here.