Questions tagged [manage.py]

`manage.py` is a command-line utility for Django's administrative tasks. It is an automatically created thin wrapper around `django-admin.py`.

manage.py is similar to django-admin but it does some extra tasks like putting your project's package on sys.path and sets the DJANGO_SETTINGS_MODULE environment variable so that it points to your project’s settings.py file.

Usage

manage.py <command> [options]

Source

201 questions
0
votes
0 answers

Django dev server web page shuts down every 24 hours

New Django learner here! I have a Django web page that I want to run continuously. This is what I do to start the server in cmd. manage.py runserver 0.0.0.0:80 This starts the server and then I keep it running in the background. When I start…
Anurag Joshi
  • 300
  • 1
  • 12
0
votes
0 answers

Unknown command 'refreshcodes'

I'm new in python and following the youtube videos to learn how to code. But now i got a problem. I tried to write custom django-admin command 'refreshcodes'. Here is my file located in src/shortener/managment/commands/refreshcodes.py: from…
0
votes
1 answer

Run button in Visual Studio gives options for manage.py instead of running

I am trying to run a Django project with manage.py as the startup file. I can run it fine from command prompt using python manage.py runserverand manually navigate to the site. I am expecting that when I press the run button in Visual Studio that it…
Tessa
  • 176
  • 13
0
votes
2 answers

python manage.py sql Unknown command

When i run following command:- python manage.py sql i get an error stating that Unknown command: 'sql' Type 'manage.py help' for usage. version :- python manage.py --version 1.10
prateek desai
  • 19
  • 1
  • 5
0
votes
0 answers

how to merge the output of django dumpdata?

manage.py dumpdata is very convenient, I store fixture and other project related data in the project folder. If two people work on the same project and want to merge the output of dumpdata, how ? And is there might be clash with primary keys ?
user3599803
  • 6,435
  • 17
  • 69
  • 130
0
votes
1 answer

Reverse for 'post_new' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []

I get this traceback when browsing to https://monajalal.pythonanywhere.com/ and the complete code can be found here https://github.com/monajalal/FirstDjangoApp : NoReverseMatch at / Reverse for 'post_new' with arguments '()' and keyword arguments…
Mona Jalal
  • 34,860
  • 64
  • 239
  • 408
0
votes
1 answer

Django: can't inspectdb second database

I have the following 2 databases in my DATABASES dictionary: DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': 'C:/Users/B/Desktop/board.db' }, 'game':{ 'ENGINE':…
TheEyesHaveIt
  • 980
  • 5
  • 16
  • 33
0
votes
2 answers

Run manage.py migrate but no accout related tables created in graphite.db

I'm installing graphite 0.9.15 on Ubuntu Server 16.04 LTS. During configuration step cd /opt/graphite/webapp/graphite sudo cp local_settings.py.example local_settings.py Then using the command in the official installation instruction: sudo…
0
votes
1 answer

python3 manage.py runserver for Django

I can't run Django server and this is the problem : MacBook-Pro-di-viv:vivsite viv$ python3 manage.py runserver Traceback (most recent call last): File "manage.py", line 10, in execute_from_command_line(sys.argv) File…
0
votes
1 answer

Python Manage.py Commands Not Recognized on Heroku

Trying to run heroku run python manage.py migrate --remote [my app] and it is outputting a list of subcommands. Tried various other django commands with the same result, everything from 'shell' to some custom commands I invented. heroku run python…
bkoatz
  • 17
  • 3
0
votes
3 answers

Overlapping cron job that runs the same Django management command: problematic?

I have a recurring cron job that runs a Django management command. The command interacts with the ORM, sends email with sendmail, and sends SMS with Twilio. It's possible that the cron jobs will begin to overlap. In other words, the job (that runs…
Daniel
  • 1,774
  • 2
  • 22
  • 38
0
votes
1 answer

"Migrate" command for manage.py not recognised when using Django 1.8

Using "path/to/mySite/manage.py migrate" I get Unknown command: 'migrate' Type 'manage.py help' for usage. Listed commands are: changepassword cleanup compilemessages createcachetable createsuperuser dbshell diffsettings dumpdata …
Luken
  • 321
  • 3
  • 13
0
votes
2 answers

Django - ./manage.py defaults to python 2.x

So I've: chmod +x manage.pyso I can just ./manage.py when needed, but it defaults to python 2.7, but I want it to use python 3.4 I also have installed. I know I could just use python3 manage.pybut I want to know if there's a way to use the shortcut…
Anthony O.
  • 15
  • 1
  • 5
0
votes
2 answers

Django manage.py sqclear all apps

I want to get all apps sql clear code in Django. I can use ./manage.py sqlclear but I need to specify an appname, so is just for one app. Is there a way or command to execute sqlclear over all installed apps ?
levi
  • 22,001
  • 7
  • 73
  • 74
0
votes
1 answer

Cannot run "python manage.py runserver"

This is a project written by other people and I am working on adding new features to the project. I am new to python and django so the previous developer helped me setup the environment. It worked fine in the past, but today when I tried to run the…
Shawn Li
  • 99
  • 2
  • 13