{"action":"created","issue":{"url":"https://api.github.com/repos/buildbot/buildbot/issues/2268","repository_url":"https://api.github.com/repos/buildbot/buildbot","labels_url":"https://api.github.com/repos/buildbot/buildbot/issues/2268/labels{/name}","comments_url":"https://api.github.com/repos/buildbot/buildbot/issues/2268/comments","events_url":"https://api.github.com/repos/buildbot/buildbot/issues/2268/events","html_url":"https://github.com/buildbot/buildbot/pull/2268","id":159157370,"number":2268,"title":"Add cascading deletes on foreign keys for builder_masters","user":{"login":"gracinet","id":474220,"avatar_url":"https://avatars.githubusercontent.com/u/474220?v=3","gravatar_id":"","url":"https://api.github.com/users/gracinet","html_url":"https://github.com/gracinet","followers_url":"https://api.github.com/users/gracinet/followers","following_url":"https://api.github.com/users/gracinet/following{/other_user}","gists_url":"https://api.github.com/users/gracinet/gists{/gist_id}","starred_url":"https://api.github.com/users/gracinet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gracinet/subscriptions","organizations_url":"https://api.github.com/users/gracinet/orgs","repos_url":"https://api.github.com/users/gracinet/repos","events_url":"https://api.github.com/users/gracinet/events{/privacy}","received_events_url":"https://api.github.com/users/gracinet/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2016-06-08T12:59:39Z","updated_at":"2016-06-15T19:56:15Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/buildbot/buildbot/pulls/2268","html_url":"https://github.com/buildbot/buildbot/pull/2268","diff_url":"https://github.com/buildbot/buildbot/pull/2268.diff","patch_url":"https://github.com/buildbot/buildbot/pull/2268.patch"},"body":"This solves http://trac.buildbot.net/ticket/3504\r\n\r\nondelete is supported by SQLA 0.8.0.\r\nApparently [SQLA 0.9.2](http://docs.sqlalchemy.org/en/rel_0_9/changelog/changelog_09.html#change-0.9.2) brings dialect-dependent validation of such arguments,\r\nbut the syntax is uniform between SQLite, MySQL and PostgreSQL anyway.\r\n\r\n(SQLite3 has had CASCADE since it got FKs in the first place in version 3.6.19)\r\n\r\nCaveats / TODOs:\r\n\r\n- upgrade-master does not add the ondelete option\r\n- should do most of the other many2many relationships as well\r\n\r\nI'm a bit concerned that we'll find corner cases where deletion of data is actually unwanted (e.g, because it's temporary / should be an update / should be a disabling), but that's beyond the scope of this PR."},"comment":{"url":"https://api.github.com/repos/buildbot/buildbot/issues/comments/226301490","html_url":"https://github.com/buildbot/buildbot/pull/2268#issuecomment-226301490","issue_url":"https://api.github.com/repos/buildbot/buildbot/issues/2268","id":226301490,"user":{"login":"tardyp","id":109859,"avatar_url":"https://avatars.githubusercontent.com/u/109859?v=3","gravatar_id":"","url":"https://api.github.com/users/tardyp","html_url":"https://github.com/tardyp","followers_url":"https://api.github.com/users/tardyp/followers","following_url":"https://api.github.com/users/tardyp/following{/other_user}","gists_url":"https://api.github.com/users/tardyp/gists{/gist_id}","starred_url":"https://api.github.com/users/tardyp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tardyp/subscriptions","organizations_url":"https://api.github.com/users/tardyp/orgs","repos_url":"https://api.github.com/users/tardyp/repos","events_url":"https://api.github.com/users/tardyp/events{/privacy}","received_events_url":"https://api.github.com/users/tardyp/received_events","type":"User","site_admin":false},"created_at":"2016-06-15T19:56:15Z","updated_at":"2016-06-15T19:56:15Z","body":"@gracinet will you be able to work on the upgrade script?"}}
{"actor":{"display_login":"tardyp"}}