{"action":"created","issue":{"url":"https://api.github.com/repos/async-interop/event-loop/issues/84","repository_url":"https://api.github.com/repos/async-interop/event-loop","labels_url":"https://api.github.com/repos/async-interop/event-loop/issues/84/labels{/name}","comments_url":"https://api.github.com/repos/async-interop/event-loop/issues/84/comments","events_url":"https://api.github.com/repos/async-interop/event-loop/issues/84/events","html_url":"https://github.com/async-interop/event-loop/pull/84","id":166374737,"number":84,"title":"Add a warning/implementation note about installing handlers for a same signal on different loops","user":{"login":"bwoebi","id":3154871,"avatar_url":"https://avatars.githubusercontent.com/u/3154871?v=3","gravatar_id":"","url":"https://api.github.com/users/bwoebi","html_url":"https://github.com/bwoebi","followers_url":"https://api.github.com/users/bwoebi/followers","following_url":"https://api.github.com/users/bwoebi/following{/other_user}","gists_url":"https://api.github.com/users/bwoebi/gists{/gist_id}","starred_url":"https://api.github.com/users/bwoebi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bwoebi/subscriptions","organizations_url":"https://api.github.com/users/bwoebi/orgs","repos_url":"https://api.github.com/users/bwoebi/repos","events_url":"https://api.github.com/users/bwoebi/events{/privacy}","received_events_url":"https://api.github.com/users/bwoebi/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-07-19T16:25:20Z","updated_at":"2016-07-20T09:42:38Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/async-interop/event-loop/pulls/84","html_url":"https://github.com/async-interop/event-loop/pull/84","diff_url":"https://github.com/async-interop/event-loop/pull/84.diff","patch_url":"https://github.com/async-interop/event-loop/pull/84.patch"},"body":"This needs to be undefined behavior as we do not have the possibilities in PHP (i.e. the language and functions don't give us the power) to distinguish properly whether a signal is already installed or not\r\nAlso, when we try to set a handler for a signal we've already installed a signal elsewhere, the second onSignal() call will lead implementations to override the original handler (on the system level, with signal()/sigaction())\r\nUltimately some extensions just flat out emit a warning in that case (e.g. libev).\r\n\r\nThus, we cannot control what happens and hence this needs to be specified as undefined behavior.\r\n\r\nAlso see issues we encountered with https://github.com/async-interop/event-loop-test/blob/d6c299a4485e0ebb731a8d239ccaff346a3fe531/src/Test.php#L943 … Turned out we just were even unable to make this test work _in a controlled way_."},"comment":{"url":"https://api.github.com/repos/async-interop/event-loop/issues/comments/233902308","html_url":"https://github.com/async-interop/event-loop/pull/84#issuecomment-233902308","issue_url":"https://api.github.com/repos/async-interop/event-loop/issues/84","id":233902308,"user":{"login":"kelunik","id":2743004,"avatar_url":"https://avatars.githubusercontent.com/u/2743004?v=3","gravatar_id":"","url":"https://api.github.com/users/kelunik","html_url":"https://github.com/kelunik","followers_url":"https://api.github.com/users/kelunik/followers","following_url":"https://api.github.com/users/kelunik/following{/other_user}","gists_url":"https://api.github.com/users/kelunik/gists{/gist_id}","starred_url":"https://api.github.com/users/kelunik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kelunik/subscriptions","organizations_url":"https://api.github.com/users/kelunik/orgs","repos_url":"https://api.github.com/users/kelunik/repos","events_url":"https://api.github.com/users/kelunik/events{/privacy}","received_events_url":"https://api.github.com/users/kelunik/received_events","type":"User","site_admin":false},"created_at":"2016-07-20T09:42:38Z","updated_at":"2016-07-20T09:42:38Z","body":"> How about installing the signals when the event loop starts to run because there won't ever be more than one event loop running.\r\n\r\nThat's not true, that's the issue. Functions like shutdowns might require a fresh loop. So they will stack. There's still only one running at any time. But as soon as the inner loop ends, the other one will continue."}}
{"actor":{"display_login":"kelunik"}}