{"action":"created","issue":{"url":"https://api.github.com/repos/activeadmin/activeadmin/issues/4558","repository_url":"https://api.github.com/repos/activeadmin/activeadmin","labels_url":"https://api.github.com/repos/activeadmin/activeadmin/issues/4558/labels{/name}","comments_url":"https://api.github.com/repos/activeadmin/activeadmin/issues/4558/comments","events_url":"https://api.github.com/repos/activeadmin/activeadmin/issues/4558/events","html_url":"https://github.com/activeadmin/activeadmin/pull/4558","id":169348023,"number":4558,"title":"Don't reload routes twice on admin code changes.","user":{"login":"kaspth","id":350807,"avatar_url":"https://avatars.githubusercontent.com/u/350807?v=3","gravatar_id":"","url":"https://api.github.com/users/kaspth","html_url":"https://github.com/kaspth","followers_url":"https://api.github.com/users/kaspth/followers","following_url":"https://api.github.com/users/kaspth/following{/other_user}","gists_url":"https://api.github.com/users/kaspth/gists{/gist_id}","starred_url":"https://api.github.com/users/kaspth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kaspth/subscriptions","organizations_url":"https://api.github.com/users/kaspth/orgs","repos_url":"https://api.github.com/users/kaspth/repos","events_url":"https://api.github.com/users/kaspth/events{/privacy}","received_events_url":"https://api.github.com/users/kaspth/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-08-04T11:00:10Z","updated_at":"2017-01-29T18:33:17Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/activeadmin/activeadmin/pulls/4558","html_url":"https://github.com/activeadmin/activeadmin/pull/4558","diff_url":"https://github.com/activeadmin/activeadmin/pull/4558.diff","patch_url":"https://github.com/activeadmin/activeadmin/pull/4558.patch"},"body":"If someone makes a change in an `app/admin` file, Rails will trigger a\nroutes reload by eval'ing `routes.rb` which in turn will call `routes`\non the Active Admin application.\n\nLater, because we've inserted ourselves into the reloading through the\n`to_prepare` and `to_complete` callbacks, `to_prepare` will unload our\nnamespaces while `to_complete` will retrigger a routes and application\nreload.\n\nThus we can reliably skip the first routes reload whenver the reloader\nis `updated?`. Because `execute_if_updated` is called if it is updated\nthe routes will be reloaded at that time. When `execute_if_updated` is\nreloading the routes the reloader is no longer `updated?`. Finally, if\nthe code change wasn't in `app/admin` our reloader won't be `updated?`\nthere either.\n"},"comment":{"url":"https://api.github.com/repos/activeadmin/activeadmin/issues/comments/275935150","html_url":"https://github.com/activeadmin/activeadmin/pull/4558#issuecomment-275935150","issue_url":"https://api.github.com/repos/activeadmin/activeadmin/issues/4558","id":275935150,"user":{"login":"timoschilling","id":165599,"avatar_url":"https://avatars.githubusercontent.com/u/165599?v=3","gravatar_id":"","url":"https://api.github.com/users/timoschilling","html_url":"https://github.com/timoschilling","followers_url":"https://api.github.com/users/timoschilling/followers","following_url":"https://api.github.com/users/timoschilling/following{/other_user}","gists_url":"https://api.github.com/users/timoschilling/gists{/gist_id}","starred_url":"https://api.github.com/users/timoschilling/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timoschilling/subscriptions","organizations_url":"https://api.github.com/users/timoschilling/orgs","repos_url":"https://api.github.com/users/timoschilling/repos","events_url":"https://api.github.com/users/timoschilling/events{/privacy}","received_events_url":"https://api.github.com/users/timoschilling/received_events","type":"User","site_admin":false},"created_at":"2017-01-29T18:33:17Z","updated_at":"2017-01-29T18:33:17Z","body":"can some rebase this to get the tests green"}}
{"actor":{"display_login":"timoschilling"}}