... odelAdmin.list_display that clashed with a reverse field on the model ( #25299 ). Fixed autocompletion for options of non- argparse management commands ( #25372 ). Alphabetized ordering of imports in from django.db import migrations, models statement in ... ... ved by the command is now always the dest name specified in the command option definition (as long as the command uses the argparse module). The dbshell command now supports MySQL's optional SSL certificate authority setting ( --ssl-ca ). The new makemig ... rgs command variable, you might get an error like Error: unrecognized arguments: ... , as variable parsing is now based on argparse which doesn't implicitly accept positional arguments. You can make your command backwards compatible by simply setting the ... cls, parser) class method on the test runner and call parser.add_argument to add any custom arguments, as parser is now an argparse.ArgumentParser instance. Model check ensures auto-generated column names are within limits specified by database A field n ... ... lete () # ... The option ( delete in our example) is available in the options dict parameter of the handle method. See the argparse Python documentation for more about add_argument usage. 独自のコマンドラインオプションを追加できるのに加え、 管理コマンド ... itional arguments, you can customize the message error returned in the case of missing arguments. The default is output by argparse ("too few arguments"). BaseCommand. output_transaction コマンドが SQL 文を出力するかどうかを決めるブール値。 True の場合、 ... ... IN_REDIRECT_URL settings will be removed. Support for optparse will be dropped for custom management commands (replaced by argparse ). The class django.core.management.NoArgsCommand will be removed. Use BaseCommand instead, which takes no arguments by de ... ... uments ( parser ) [ソース] Override this class method to add custom arguments accepted by the test management command. See argparse.ArgumentParser.add_argument() for details about adding arguments to a parser. DiscoverRunner. setup_test_environment ( ** ... 2026年10月08日