Initial commit on Forgejo
All checks were successful
CI and deploy / Test (push) Successful in 4m52s
CI and deploy / Deploy production (push) Successful in 23s

Fresh repository history for elektrine/tarakan hosted at
https://git.elektrine.com/elektrine/tarakan.
This commit is contained in:
Maxfield Luke 2026-07-29 04:43:40 -04:00
commit af6077b9c3
455 changed files with 78366 additions and 0 deletions

View file

@ -0,0 +1,22 @@
defmodule Tarakan.GitHubBulkStub do
@moduledoc """
Bulk-lookup stub. Tests script responses per node id with
`put_response/2`; unscripted ids resolve to `nil` (node gone).
"""
@behaviour Tarakan.GitHubBulkClient
def put_response(node_id, response) do
Process.put({__MODULE__, node_id}, response)
end
@impl true
def fetch_repositories_by_node_ids(node_ids) when is_list(node_ids) do
case Process.get({__MODULE__, :batch_error}) do
nil -> {:ok, Enum.map(node_ids, &Process.get({__MODULE__, &1}))}
reason -> {:error, reason}
end
end
def fail_batches_with(reason), do: Process.put({__MODULE__, :batch_error}, reason)
end