{"action":"created","issue":{"url":"https://api.github.com/repos/code-dot-org/code-dot-org/issues/10405","repository_url":"https://api.github.com/repos/code-dot-org/code-dot-org","labels_url":"https://api.github.com/repos/code-dot-org/code-dot-org/issues/10405/labels{/name}","comments_url":"https://api.github.com/repos/code-dot-org/code-dot-org/issues/10405/comments","events_url":"https://api.github.com/repos/code-dot-org/code-dot-org/issues/10405/events","html_url":"https://github.com/code-dot-org/code-dot-org/pull/10405","id":174407764,"number":10405,"title":"Make Pd* models soft-delete","user":{"login":"aoby","id":8405316,"avatar_url":"https://avatars.githubusercontent.com/u/8405316?v=3","gravatar_id":"","url":"https://api.github.com/users/aoby","html_url":"https://github.com/aoby","followers_url":"https://api.github.com/users/aoby/followers","following_url":"https://api.github.com/users/aoby/following{/other_user}","gists_url":"https://api.github.com/users/aoby/gists{/gist_id}","starred_url":"https://api.github.com/users/aoby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aoby/subscriptions","organizations_url":"https://api.github.com/users/aoby/orgs","repos_url":"https://api.github.com/users/aoby/repos","events_url":"https://api.github.com/users/aoby/events{/privacy}","received_events_url":"https://api.github.com/users/aoby/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/code-dot-org/code-dot-org/labels/data","name":"data","color":"efcd1c"},{"url":"https://api.github.com/repos/code-dot-org/code-dot-org/labels/professional-learning","name":"professional-learning","color":"0094ca"}],"state":"open","locked":false,"assignee":{"login":"ashercodeorg","id":14206260,"avatar_url":"https://avatars.githubusercontent.com/u/14206260?v=3","gravatar_id":"","url":"https://api.github.com/users/ashercodeorg","html_url":"https://github.com/ashercodeorg","followers_url":"https://api.github.com/users/ashercodeorg/followers","following_url":"https://api.github.com/users/ashercodeorg/following{/other_user}","gists_url":"https://api.github.com/users/ashercodeorg/gists{/gist_id}","starred_url":"https://api.github.com/users/ashercodeorg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ashercodeorg/subscriptions","organizations_url":"https://api.github.com/users/ashercodeorg/orgs","repos_url":"https://api.github.com/users/ashercodeorg/repos","events_url":"https://api.github.com/users/ashercodeorg/events{/privacy}","received_events_url":"https://api.github.com/users/ashercodeorg/received_events","type":"User","site_admin":false},"assignees":[{"login":"ashercodeorg","id":14206260,"avatar_url":"https://avatars.githubusercontent.com/u/14206260?v=3","gravatar_id":"","url":"https://api.github.com/users/ashercodeorg","html_url":"https://github.com/ashercodeorg","followers_url":"https://api.github.com/users/ashercodeorg/followers","following_url":"https://api.github.com/users/ashercodeorg/following{/other_user}","gists_url":"https://api.github.com/users/ashercodeorg/gists{/gist_id}","starred_url":"https://api.github.com/users/ashercodeorg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ashercodeorg/subscriptions","organizations_url":"https://api.github.com/users/ashercodeorg/orgs","repos_url":"https://api.github.com/users/ashercodeorg/repos","events_url":"https://api.github.com/users/ashercodeorg/events{/privacy}","received_events_url":"https://api.github.com/users/ashercodeorg/received_events","type":"User","site_admin":false}],"milestone":null,"comments":6,"created_at":"2016-09-01T00:06:56Z","updated_at":"2016-09-01T14:19:25Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/code-dot-org/code-dot-org/pulls/10405","html_url":"https://github.com/code-dot-org/code-dot-org/pull/10405","diff_url":"https://github.com/code-dot-org/code-dot-org/pull/10405.diff","patch_url":"https://github.com/code-dot-org/code-dot-org/pull/10405.patch"},"body":"While `deleted_at` is not necessarily honored on the Pegasus side, the only place these models are referenced there are in the exit surveys: [here](https://github.com/code-dot-org/code-dot-org/blob/5e8d575c3eb6ab0712326b6edcca34e8e05df84e/pegasus/sites.v3/code.org/public/pd-workshop-survey/splat.haml#L7-L11), [here](https://github.com/code-dot-org/code-dot-org/blob/622afefcc9663f1ce91ec7302328ccc78cde6533/pegasus/sites.v3/code.org/public/pd-workshop-survey/materials/splat.haml#L9-L14), and [here](https://github.com/code-dot-org/code-dot-org/blob/ea5ee2cecca58c59fc0f609fc78cf63d523059c5/pegasus/forms/pd_workshop_survey.rb#L83).\r\n\r\nIn the rare case where a workshop is deleted after the exit survey email went out, we should still allow the teacher to take the survey so I'm intentionally leaving `deleted_at` off of those queries."},"comment":{"url":"https://api.github.com/repos/code-dot-org/code-dot-org/issues/comments/244093468","html_url":"https://github.com/code-dot-org/code-dot-org/pull/10405#issuecomment-244093468","issue_url":"https://api.github.com/repos/code-dot-org/code-dot-org/issues/10405","id":244093468,"user":{"login":"ashercodeorg","id":14206260,"avatar_url":"https://avatars.githubusercontent.com/u/14206260?v=3","gravatar_id":"","url":"https://api.github.com/users/ashercodeorg","html_url":"https://github.com/ashercodeorg","followers_url":"https://api.github.com/users/ashercodeorg/followers","following_url":"https://api.github.com/users/ashercodeorg/following{/other_user}","gists_url":"https://api.github.com/users/ashercodeorg/gists{/gist_id}","starred_url":"https://api.github.com/users/ashercodeorg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ashercodeorg/subscriptions","organizations_url":"https://api.github.com/users/ashercodeorg/orgs","repos_url":"https://api.github.com/users/ashercodeorg/repos","events_url":"https://api.github.com/users/ashercodeorg/events{/privacy}","received_events_url":"https://api.github.com/users/ashercodeorg/received_events","type":"User","site_admin":false},"created_at":"2016-09-01T14:19:25Z","updated_at":"2016-09-01T14:19:25Z","body":"My vote is not to have indexes around that are never used."}}
{"actor":{"display_login":"ashercodeorg"}}