Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Pages function does not work for search.

Open
#137 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
40/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
python
Domain
api

Research direction

Start in ghapi/page.py at last_page(), then inspect the request flow around the missing recv_hdrs shown in ghapi/core.py. Reproduce the search example and verify that Pages can determine and concatenate search results without raising AttributeError.

Written by the indexing model from the issue text.

Description

Pages for search does not work:

gh = GhApi(token=gh_token)
search = pages(gh.search.code, gh.last_page(), '"test"').concat

Will yield the following error:

  File "/Users/***/venv/lib/python3.9/site-packages/ghapi/page.py", line 57, in last_page
    header = self.recv_hdrs.get('Link', '')
  File "/Users/***/venv/lib/python3.9/site-packages/ghapi/core.py", line 124, in __getattr__
    def __getattr__(self,k): return self.groups[k] if 'groups' in vars(self) and k in self.groups else stop(AttributeError(k))
  File "/Users/***/venv/lib/python3.9/site-packages/fastcore/basics.py", line 205, in stop
    raise e
AttributeError: recv_hdrs
Dominant language
Python
Stars
687
Forks
69
Avg merge
1m
Merged PRs (30d)
2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from AnswerDotAI/ghapi

All issues in AnswerDotAI/ghapi

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.