﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
31219	PROTECT may crash in some situations	Matthias Kestenholz	nobody	"{{{
======================================================================
ERROR: test_protect_via (delete.tests.OnDeleteTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File ""/usr/lib/python3.6/unittest/case.py"", line 59, in testPartExecutor
    yield
  File ""/usr/lib/python3.6/unittest/case.py"", line 605, in run
    testMethod()
  File ""/home/matthias/Projects/django/tests/delete/tests.py"", line 99, in test_protect_via
    p.delete()
  File ""/home/matthias/Projects/django/django/db/models/base.py"", line 941, in delete
    collector.collect([self], keep_parents=keep_parents)
  File ""/home/matthias/Projects/django/django/db/models/deletion.py"", line 300, in collect
    error.protected_objects[0].__class__.__name__,
TypeError: 'itertools.chain' object is not subscriptable
}}}

Pull request follows.

(By the way, this came up while testing https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!msg/django-developers/WmgqJnQ6ioE/b52uACoPAgAJ / the JSONField GSoC pull request. Apart from this crash everything worked fine!)"	Bug	new	Database layer (models, ORM)	dev	Normal				Unreviewed	0	0	0	0	0	0
