Code

Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#16968 closed Bug (needsinfo)

Cannot use runserver without definig default database

Reported by: yasar11732 Owned by: nobody
Component: Core (Management commands) Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Hi,

In latest source, you cannot use runserver command without defining a default database settings because django.core.management.validation imports django.db. I thought this may be a design decision, but I am opening a ticket just in case it is not.

Attachments (0)

Change History (2)

comment:1 Changed 3 years ago by charettes

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to needsinfo
  • Status changed from new to closed

Hi yasar!

Is it possible that you provide more info concerning the issue because it actually works for me doing the following:

(trunk)simon@simon-laptop:~/Bureau$ django-admin.py startproject ticket_16968
(trunk)simon@simon-laptop:~/Bureau$ cd ticket_16968/
(trunk)simon@simon-laptop:~/Bureau/ticket_16968$ ./manage.py validate
0 errors found
(trunk)simon@simon-laptop:~/Bureau/ticket_16968$ ./manage.py runserver 
Validating models...

0 errors found
Django version 1.4 pre-alpha SVN-16921, using settings 'ticket_16968.settings'
Development server is running at http://127.0.0.1:8000/
Quit the server with CONTROL-C.

Plus browsing to http://127.0.0.1:8000/ provides some useful information telling that you can actually run a django instance without interacting with a db:
If you plan to use a database, edit the DATABASES setting in ticket_16968/settings.py.

comment:2 Changed 3 years ago by yasar11732

I guess there was something in my installed apps that needed to use database in the time I was trying to runserver. Ticket can be closed.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.