Subject: Re: [PATCH v5 3/6] git-p4: retry kill/cleanup operations in tests with timeout

From: Luke Diamand <[email-masked]>
Date: Tue, 17 Nov 2015 09:38:39 +0000

On 17/11/15 08:22, Lars Schneider wrote:
>
> On 16 Nov 2015, at 09:36, Luke Diamand <[email-masked]> wrote:
>
>> On 15/11/15 13:08, [email-masked] wrote:
>>> From: Lars Schneider <[email-masked]>
>>>
>>> In rare cases kill/cleanup operations in tests fail. Retry these
>>> operations with a timeout to make the test less flaky.
>>
>> Should there be a sleep in that retry_until_success loop so that it doesn't spin sending signals to p4d?
> Agreed. I will add a sleep in the next roll!
>
>
>>
>> Do we need to worry about the time offset being updated (e.g. NTP) while this is running?
> Interesting question! I would consider this an edge case but I can see how it could happen.
> Do you see a way to handle that in an easy way?
>

You want to somehow call clock_gettime(CLOCK_MONOTONIC). That's not in 
python until 3.3. Writing a C program seems like overkill but could be a 
solution if this becomes a problem.