ChatGPT Pro with Github Connector cannot read any file contents (can only list and search). How to fix?

I connected my ChatGPT to my private repo on Github using the Github connector in ChatGPT settings.

However, ChatGPT Pro cannot read any file contents and can only list and search (which confirms it's successfully connecting to my repo).

I tried waiting, tried multiple different sessions, same results.

Specifically, it is unable to do fetch_file or fetch as they fail and result in an AttributeError: 'str' object has no attribute 'get'. Apparently the the file‑content codepath is broken because when the connector gets a string body (HTML page or raw bytes), it treats it like a dict and calls .get(…), causing the AttributeError.

It's quite frustrating because it seems like 1) the Host allow‑list is too strict (fetch(url=…) rejects api.github.com and raw.githubusercontent.com), 2) there's some kind of type assumption bug (the implementation assumes JSON/dicts and calls .get(…) even when the body is text/HTML (string) or raw bytes), and 3) fetch_file looks like it likely builds a github.com/…/blob/… URL under the hood (HTML), not the API URL, which combined with 2), makes it crashes?

I need the Pro model to analyze the code inside the files in my repo which I thought was the entire point of this Github connector in ChatGPT, so how can I fix this?

Leave a Reply