{"action":"created","issue":{"url":"https://api.github.com/repos/django/django/issues/4978","labels_url":"https://api.github.com/repos/django/django/issues/4978/labels{/name}","comments_url":"https://api.github.com/repos/django/django/issues/4978/comments","events_url":"https://api.github.com/repos/django/django/issues/4978/events","html_url":"https://github.com/django/django/pull/4978","id":94251467,"number":4978,"title":"Fixed #25064 -- Allowed empty join columns","user":{"login":"AlexHill","id":1011483,"avatar_url":"https://avatars.githubusercontent.com/u/1011483?v=3","gravatar_id":"","url":"https://api.github.com/users/AlexHill","html_url":"https://github.com/AlexHill","followers_url":"https://api.github.com/users/AlexHill/followers","following_url":"https://api.github.com/users/AlexHill/following{/other_user}","gists_url":"https://api.github.com/users/AlexHill/gists{/gist_id}","starred_url":"https://api.github.com/users/AlexHill/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AlexHill/subscriptions","organizations_url":"https://api.github.com/users/AlexHill/orgs","repos_url":"https://api.github.com/users/AlexHill/repos","events_url":"https://api.github.com/users/AlexHill/events{/privacy}","received_events_url":"https://api.github.com/users/AlexHill/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-07-10T08:37:00Z","updated_at":"2015-08-12T15:19:20Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/django/django/pulls/4978","html_url":"https://github.com/django/django/pull/4978","diff_url":"https://github.com/django/django/pull/4978.diff","patch_url":"https://github.com/django/django/pull/4978.patch"},"body":"[Trac ticket](https://code.djangoproject.com/ticket/25064)\r\n\r\nThis cleans up ON clause generation in ``Join.as_sql()``, so that it generates valid SQL as long as either joining columns or extra restrictions are provided by the join field, and raising ``ValueError`` if neither are provided by the field, instead of generating an invalid ON clause.\r\n\r\nThe substance of the fix is [this one-line addition to datastructures.py](https://github.com/django/django/commit/ec0ed0bd8db17676cc7fa64cc06e510504776926#diff-2a2517e5f15e44b5bf7ad8f970a00cb7). The following commit 23c3a55f2dc89c8c7ca37abc7b62de992b550c55 reorganises ``Join.as_sql()`` to be a little clearer and adds the exception."},"comment":{"url":"https://api.github.com/repos/django/django/issues/comments/130339973","html_url":"https://github.com/django/django/pull/4978#issuecomment-130339973","issue_url":"https://api.github.com/repos/django/django/issues/4978","id":130339973,"user":{"login":"timgraham","id":411869,"avatar_url":"https://avatars.githubusercontent.com/u/411869?v=3","gravatar_id":"","url":"https://api.github.com/users/timgraham","html_url":"https://github.com/timgraham","followers_url":"https://api.github.com/users/timgraham/followers","following_url":"https://api.github.com/users/timgraham/following{/other_user}","gists_url":"https://api.github.com/users/timgraham/gists{/gist_id}","starred_url":"https://api.github.com/users/timgraham/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timgraham/subscriptions","organizations_url":"https://api.github.com/users/timgraham/orgs","repos_url":"https://api.github.com/users/timgraham/repos","events_url":"https://api.github.com/users/timgraham/events{/privacy}","received_events_url":"https://api.github.com/users/timgraham/received_events","type":"User","site_admin":false},"created_at":"2015-08-12T15:19:20Z","updated_at":"2015-08-12T15:19:20Z","body":"Here's a proposed refactoring so we aren't extending models.py/tests.py indefinitely: https://github.com/django/django/pull/5133. Look okay? If we could merge that first and then rebase your additions, that would be great."}}