Skip to content

Conversation

@vmaerten
Copy link
Member

@vmaerten vmaerten commented Jan 30, 2026

Summary

Check git repo cache before verifying context timeout in getOrCloneRepo. This prevents timeout errors when reading includes from the same repo after user spends time on trust prompt, since cached repos don't need network access.

fixes #2668

Test plan

  • Clear git cache: rm -rf /tmp/task-git-repos
  • Run a taskfile that includes a git remote with sub-includes
  • Wait several seconds before accepting trust prompt
  • Verify include resolution succeeds (previously timed out)

When fetching remote git taskfiles, the timeout context is shared
across the entire operation including user prompt time. This caused
timeouts when processing includes after the user accepted the trust
prompt, even when the repository was already cloned.

By checking the cache before verifying the context, we allow cache
hits to succeed regardless of timeout state, since no network access
is needed for cached repositories.
@vmaerten vmaerten marked this pull request as ready for review January 30, 2026 21:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Git remote taskfile timeout includes user prompt time

2 participants