closeio / closeio/tasktiger

Enforce `hard_timeout` if child process hangs

Open
#51 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
1.5k
Forks
95
Avg merge
4d 21h
Merged PRs (30d)
1

Description

Right now we raise an exception in the child process when a "hard" timeout occurs. This exception can be intercepted in the task code, or a task could be stuck in an interruptible state, causing a task to run longer than specified or even forever.

Should we keep the current hard_timeout behavior, and simply send SIGTERM / SIGKILL to the child a few seconds after the timeout happens? Or should we have a soft_timeout setting that's separate from hard_timeout? I'd ideally like to make soft_timeout something that can be intercepted by the task code (e.g. "stop task if timeout exceeded", or have a code section that can't be interrupted by a soft timeout).

Contributor guide

No contributing guide indexed for this repository

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.

Research direction

No files, tests, or entry points are identified in the issue. First clarify whether hard timeouts should terminate child processes or whether soft_timeout should be introduced, then trace the existing timeout handling and define tests for intercepted timeouts, interruptible tasks, and guaranteed termination.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.