Django sqlmigrate not showing raw sql

I read the source code of sqlmigrate and found that add DB name for migrate may work.

So the working version would be:

$ python manage.py sqlmigrate app_name 0001 --database=db_name

The source code is here: https://github.com/django/django/blob/master/django/core/management/commands/migrate.py