﻿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
26751	dbshell error handling	Étienne BERSAC	nobody	"Hi,

The Django project made great improvements in batch mode for dbshell with password managment. That's a nice contribution !

For scripting, commands should return a non zero exit-code on error. But `runshell` seems to miss to manage exit code. Here is how to reproduce:

{{{
#!console
(venv) $ echo 'auieaui;' | django-admin dbshell
ERROR:  syntax error at or near ""auieaui""
LINE 1: auieaui;
        ^
(venv) $ echo $?
0
}}}

I suggested a fix in https://github.com/django/django/pull/6768 . @charettes asked me to open a ticket for discussion. Here your are :)

Regards,
Étienne"	Uncategorized	new	Core (Management commands)	dev	Normal		dbshell		Unreviewed	0	0	0		0	0
