question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

manage.py print_settings not working with specified names

See original GitHub issue

Running Django 1.8.9.

$ python manage.py print_settings DEBUG INSTALLED_APPS
usage: manage.py print_settings [-h] [--version] [-v {0,1,2,3}]
                            [--settings SETTINGS]
                            [--pythonpath PYTHONPATH] [--traceback]
                            [--no-color]
manage.py print_settings: error: unrecognized arguments: DEBUG INSTALLED_APPS

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:9 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
trbscommented, Aug 8, 2017

I think the command broke again with the change in how arguments work in django commands.

Basically the positional arguments are not working anymore. Looking at https://docs.djangoproject.com/en/1.11/howto/custom-management-commands/ the fix should be pretty trivial.

I hope somebody has a few minutes time to create a pull request fixing the positional arguments and a test in the test suite which tests the examples that are given in the documentation: https://django-extensions.readthedocs.io/en/latest/print_settings.html

0reactions
trbscommented, Apr 1, 2018

Closing this for being inactive for too long. If there is a better way we are still happy to accept a PR for this.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How do I print out the contents of my settings in a django shell?
from django.conf import settings dir(settings). and then choose attribute from what dir(settings) have shown you to say: settings.name. where name is the ...
Read more >
Django settings - Django documentation
The command python manage.py diffsettings displays differences between the current settings file and Django's default settings. For more, see the diffsettings ...
Read more >
print_settings — django-extensions 3.2.1 documentation
Yielding an error when a settings does not exist: $ ./manage.py print_settings -f INSTALLED_APPZ CommandError: INSTALLED_APPZ not found in settings. For more ...
Read more >
PrinterSettings Class (System.Drawing.Printing)
Specifies information about how a document is printed, including the printer that prints it, when printing from a Windows Forms application.
Read more >
Settings management - pydantic
Create a clearly-defined, type-hinted application configuration class; Automatically read modifications to the configuration from environment variables ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found