{"action":"closed","issue":{"url":"https://api.github.com/repos/not-raspberry/spawn_and_check/issues/3","labels_url":"https://api.github.com/repos/not-raspberry/spawn_and_check/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/not-raspberry/spawn_and_check/issues/3/comments","events_url":"https://api.github.com/repos/not-raspberry/spawn_and_check/issues/3/events","html_url":"https://github.com/not-raspberry/spawn_and_check/issues/3","id":78275666,"number":3,"title":"Wait for pre-checks the same way as we do with post-checks","user":{"login":"not-raspberry","id":12380813,"avatar_url":"https://avatars.githubusercontent.com/u/12380813?v=3","gravatar_id":"","url":"https://api.github.com/users/not-raspberry","html_url":"https://github.com/not-raspberry","followers_url":"https://api.github.com/users/not-raspberry/followers","following_url":"https://api.github.com/users/not-raspberry/following{/other_user}","gists_url":"https://api.github.com/users/not-raspberry/gists{/gist_id}","starred_url":"https://api.github.com/users/not-raspberry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/not-raspberry/subscriptions","organizations_url":"https://api.github.com/users/not-raspberry/orgs","repos_url":"https://api.github.com/users/not-raspberry/repos","events_url":"https://api.github.com/users/not-raspberry/events{/privacy}","received_events_url":"https://api.github.com/users/not-raspberry/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":{"login":"not-raspberry","id":12380813,"avatar_url":"https://avatars.githubusercontent.com/u/12380813?v=3","gravatar_id":"","url":"https://api.github.com/users/not-raspberry","html_url":"https://github.com/not-raspberry","followers_url":"https://api.github.com/users/not-raspberry/followers","following_url":"https://api.github.com/users/not-raspberry/following{/other_user}","gists_url":"https://api.github.com/users/not-raspberry/gists{/gist_id}","starred_url":"https://api.github.com/users/not-raspberry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/not-raspberry/subscriptions","organizations_url":"https://api.github.com/users/not-raspberry/orgs","repos_url":"https://api.github.com/users/not-raspberry/repos","events_url":"https://api.github.com/users/not-raspberry/events{/privacy}","received_events_url":"https://api.github.com/users/not-raspberry/received_events","type":"User","site_admin":false},"milestone":null,"comments":0,"created_at":"2015-05-19T22:31:52Z","updated_at":"2015-09-05T22:34:42Z","closed_at":"2015-09-05T22:34:42Z","body":"Running a service with `execute` and at least one check may fail if the previous service didn't terminate on time:\r\n\r\n1. Process X₁ is ran with the executor.\r\n2. SIGTERM is sent to the process X₁ but the service takes some time to tear down\r\n3. Process X₂ is ran with the executor - pre-checks fail because they see the previous service.\r\n4. X₁ terminates after some time but it's too late - X₂'s executor failed.\r\n\r\n\r\nDRY polling - currently there is a simple ``wait_until`` implementation in ``test.wait`` and a polling loop inside the ``execute`` function. There will be another polling for the pre-checks so the [rule of three](https://en.wikipedia.org/wiki/Rule_of_three_%28computer_programming%29) has to be applied."}}