Code

Opened 7 years ago

Closed 7 years ago

#4708 closed (invalid)

manage.py dbshell problem on Windows

Reported by: anonymous Owned by: adrian
Component: Core (Management commands) Version: master
Severity: Keywords: manage.py dbshell
Cc: yml.nospam@… Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

Hello,

I have a problem on my laptop when I run this command: "manage.py runserver" I get this error message:

C:\yml\_myScript_\dj_things\web_development\workspace\dj_project>manage.py dbshell
Traceback (most recent call last):

File "C:\yml\_myScript_\dj_things\web_development\workspace\dj_project\manage.py", line 11, in <module>

execute_manager(settings)

File "C:\yml\_myScript_\dj_things\web_development\svn_views\django_src\unicode\django\core\management.py", line 1736,

in execute_manager

execute_from_command_line(action_mapping, argv)

File "C:\yml\_myScript_\dj_things\web_development\svn_views\django_src\unicode\django\core\management.py", line 1631,

in execute_from_command_line

action_mapping[action]()

File "C:\yml\_myScript_\dj_things\web_development\svn_views\django_src\unicode\django\core\management.py", line 1330,

in dbshell

runshell()

File "C:\yml\_myScript_\dj_things\web_development\svn_views\django_src\unicode\django\db\init.py", line 28, in <la

mbda>

runshell = lambda: import('django.db.backends.%s.client' % settings.DATABASE_ENGINE, {}, {}, []).runshell()

File "C:\yml\_myScript_\dj_things\web_development\svn_views\django_src\unicode\django\db\backends\mysql\client.py", li

ne 27, in runshell

os.execvp('mysql', args)

File "C:\install\Python25\lib\os.py", line 354, in execvp

_execvpe(file, args)

File "C:\install\Python25\lib\os.py", line 392, in _execvpe

func(fullname, *argrest)

OSError: [Errno 2] No such file or directory

Also the rest of the framework is working just fine. I was running from the trunk on windows with python 2.5. Then I try to use the unicode branch same result. Then I have updated from python 2.5 to 2.5.1 same result.

Thank you for your help

Attachments (0)

Change History (6)

comment:1 Changed 7 years ago by Paul Bx <pb@…>

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Summary changed from manage.py dbshell is broken to manage.py dbshell problem on Windows

comment:2 Changed 7 years ago by Ramiro Morales

It seems you are using dj_project as your Django project name. This name should be a valid Python module name (see the Note here http://www.djangoproject.com/documentation/tutorial01/#creating-a-project) and dj_project isn't.

comment:3 Changed 7 years ago by Ramiro Morales

Disregard my previous post (I remember having some problems when using _ in a project/app name that I solved renaming them; but now I'm testing things with a dummy project and if works Ok).

Reading the complete traceback (what I shold have done first :) it seems you don't have the mysql.exe (does such thing exist?) MySQL command line client accesible via the PATH envvar.

comment:4 Changed 7 years ago by anonymous

I finally manage to test this on a Linux box and it is working fine there. I am assuming that this bug is a windows only or it is linked to the configuration of this particular computer.

comment:5 Changed 7 years ago by Ramiro Morales

So, can this ticket be closed?

comment:6 Changed 7 years ago by anonymous

  • Resolution set to invalid
  • Status changed from new to closed

I confirm that this issue was due to the fact that mysql.exe was not in my path. I set this ticket as invalid.
Thank you for your help

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.