Re: DATABASE in settings file not working

2014-12-11 Thread dennis breland
Thanks. I've spent hours on this silly typo.

On Thursday, December 11, 2014 9:53:12 AM UTC-5, François Schiettecatte 
wrote:

> PASSSWORD => PASSWORD 
>
>
> > On Dec 11, 2014, at 9:26 AM, dennis breland  > wrote: 
> > 
> > Please help with this problem... 
> > 
> >   
> > I am getting an access denied error when running Django; details follow: 
> > Currently installed versions: 
> > Python 2.7.3 
> > MySQL-python package 1.2.3 
> > Django 1.7 
> >   
> > I previously used the Django tutorial and successfully used the polling 
> app, using sqlite3. Now I started over with the tutorial and I’m trying to 
> use mysql instead. I created a database called denmain. 
> > As stated in the tutorial, when I perform: 
> > python manage.py migrate 
> > I get this response: 
> > … 
> > File 
> "/usr/lib/python2.7/dist-packages/MySQLdb/connections.py", line 187, in 
> __init__ 
> > super(Connection, self).__init__(*args, **kwargs2) 
> > django.db.utils.OperationalError: (1045, "Access denied for user 
> 'dennis'@'localhost' (using password: NO)") 
> >   
> > Here is my settings.py: 
> > … 
> > DATABASES = { 
> > 'default': { 
> > 'ENGINE': 'django.db.backends.mysql', 
> > 'NAME': 'denmain', 
> > 'USER': 'dennis', 
> > 'PASSSWORD': 'mypass', 
> > 'HOST': '127.0.0.1', 
> > 'PORT': '3306', 
> > } 
> > … 
> > 
> > On Friday, February 17, 2012 9:11:11 AM UTC-5, Detectedstealth wrote: 
> > Hi, 
> > 
> > I am just coming back to django development after a while of 
> > developing with pyramid. I have taking over an application. 
> > 
> > For some reason with the newest version of django it is not reading 
> > the password I set in settings: 
> > 
> > DATABASES = { 
> > 'default': { 
> > 'ENGINE': 'django.db.backends.mysql', # Add 
> > 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'. 
> > 'NAME': 'mydatabase',  # Or path to 
> > database file if using sqlite3. 
> > 'USER': 'root',  # Not used with sqlite3. 
> > 'PASSWORD': 'mypassword',  # Not used with 
> > sqlite3. 
> > 'HOST': '',  # Set to empty string for 
> > localhost. Not used with sqlite3. 
> > 'PORT': '',  # Set to empty string for 
> > default. Not used with sqlite3. 
> > } 
> > } 
> > 
> > When starting the server I get the following error: 
> > ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py", 
> > line 187, in 
> > __init__ 
> > _mysql_exceptions.OperationalError: (1045, "Access denied for user 
> > 'root'@'localhost' (using password: NO)") 
> > 
> > Not sure why it is saying there was not password. For the newest 
> > version of django is there a new way to tell python manage.py 
> > runserver what password/username/database to use? 
> > 
> > -- 
> > You received this message because you are subscribed to the Google 
> Groups "Django users" group. 
> > To unsubscribe from this group and stop receiving emails from it, send 
> an email to django-users...@googlegroups.com . 
> > To post to this group, send email to django...@googlegroups.com 
> . 
> > Visit this group at http://groups.google.com/group/django-users. 
> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/fd0f8b04-a8ff-41fc-8c77-01bd47abb679%40googlegroups.com.
>  
>
> > For more options, visit https://groups.google.com/d/optout. 
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/1710bde5-b671-40e3-bbde-94b0aabb61b1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: DATABASE in settings file not working

2014-12-11 Thread François Schiettecatte
PASSSWORD => PASSWORD


> On Dec 11, 2014, at 9:26 AM, dennis breland  wrote:
> 
> Please help with this problem...
> 
>  
> I am getting an access denied error when running Django; details follow:
> Currently installed versions:
> Python 2.7.3
> MySQL-python package 1.2.3
> Django 1.7
>  
> I previously used the Django tutorial and successfully used the polling app, 
> using sqlite3. Now I started over with the tutorial and I’m trying to use 
> mysql instead. I created a database called denmain.
> As stated in the tutorial, when I perform:
> python manage.py migrate
> I get this response:
> …
> File "/usr/lib/python2.7/dist-packages/MySQLdb/connections.py", 
> line 187, in __init__
> super(Connection, self).__init__(*args, **kwargs2)
> django.db.utils.OperationalError: (1045, "Access denied for user 
> 'dennis'@'localhost' (using password: NO)")
>  
> Here is my settings.py:
> …
> DATABASES = {
> 'default': {
> 'ENGINE': 'django.db.backends.mysql',
> 'NAME': 'denmain',
> 'USER': 'dennis',
> 'PASSSWORD': 'mypass',
> 'HOST': '127.0.0.1',
> 'PORT': '3306',
> }
> …
> 
> On Friday, February 17, 2012 9:11:11 AM UTC-5, Detectedstealth wrote:
> Hi, 
> 
> I am just coming back to django development after a while of 
> developing with pyramid. I have taking over an application. 
> 
> For some reason with the newest version of django it is not reading 
> the password I set in settings: 
> 
> DATABASES = { 
> 'default': { 
> 'ENGINE': 'django.db.backends.mysql', # Add 
> 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'. 
> 'NAME': 'mydatabase',  # Or path to 
> database file if using sqlite3. 
> 'USER': 'root',  # Not used with sqlite3. 
> 'PASSWORD': 'mypassword',  # Not used with 
> sqlite3. 
> 'HOST': '',  # Set to empty string for 
> localhost. Not used with sqlite3. 
> 'PORT': '',  # Set to empty string for 
> default. Not used with sqlite3. 
> } 
> } 
> 
> When starting the server I get the following error: 
> ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py", 
> line 187, in 
> __init__ 
> _mysql_exceptions.OperationalError: (1045, "Access denied for user 
> 'root'@'localhost' (using password: NO)") 
> 
> Not sure why it is saying there was not password. For the newest 
> version of django is there a new way to tell python manage.py 
> runserver what password/username/database to use?
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/fd0f8b04-a8ff-41fc-8c77-01bd47abb679%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/5CBEEB4E-6A70-430F-B2F4-C25EE064B28E%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: DATABASE in settings file not working

2014-12-11 Thread dennis breland


Please help with this problem...
 
I am getting an access denied error when running Django; details follow:

Currently installed versions:

Python 2.7.3

MySQL-python package 1.2.3

Django 1.7

 

I previously used the Django tutorial and successfully used the polling 
app, using sqlite3. Now I started over with the tutorial and I’m trying to 
use mysql instead. I created a database called denmain.

As stated in the tutorial, when I perform:

python manage.py migrate

I get this response:

…

File "/usr/lib/python2.7/dist-packages/MySQLdb/connections.py", 
line 187, in __init__

super(Connection, self).__init__(*args, **kwargs2)

django.db.utils.OperationalError: (1045, "Access denied for user 
'dennis'@'localhost' (using password: NO)")

 

Here is my settings.py:

…

DATABASES = {

'default': {

'ENGINE': 'django.db.backends.mysql',

'NAME': 'denmain',

'USER': 'dennis',

'PASSSWORD': 'mypass',

'HOST': '127.0.0.1',

'PORT': '3306',

}

…

On Friday, February 17, 2012 9:11:11 AM UTC-5, Detectedstealth wrote:
>
> Hi, 
>
> I am just coming back to django development after a while of 
> developing with pyramid. I have taking over an application. 
>
> For some reason with the newest version of django it is not reading 
> the password I set in settings: 
>
> DATABASES = { 
> 'default': { 
> 'ENGINE': 'django.db.backends.mysql', # Add 
> 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'. 
> 'NAME': 'mydatabase',  # Or path to 
> database file if using sqlite3. 
> 'USER': 'root',  # Not used with sqlite3. 
> 'PASSWORD': 'mypassword',  # Not used with 
> sqlite3. 
> 'HOST': '',  # Set to empty string for 
> localhost. Not used with sqlite3. 
> 'PORT': '',  # Set to empty string for 
> default. Not used with sqlite3. 
> } 
> } 
>
> When starting the server I get the following error: 
> ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py", 
> line 187, in 
> __init__ 
> _mysql_exceptions.OperationalError: (1045, "Access denied for user 
> 'root'@'localhost' (using password: NO)") 
>
> Not sure why it is saying there was not password. For the newest 
> version of django is there a new way to tell python manage.py 
> runserver what password/username/database to use?

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/fd0f8b04-a8ff-41fc-8c77-01bd47abb679%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: DATABASE in settings file not working

2012-02-17 Thread Detectedstealth
Ok it looks like there is an issue with my desktop. I did everything
from scratch on my labtop (also running opensuse) and changes to the
settings file now work

On Feb 17, 9:05 pm, Detectedstealth  wrote:
> I am starting to wonder if it is an opensuse bug. I am thinking about
> switching back to Ubuntu.
>
> On Feb 17, 9:04 pm, Detectedstealth  wrote:
>
>
>
>
>
>
>
> > Yeah I have tried removing settings.pyc and __init__.pyc it
> > regenerates the *.pyc files but still is not reading the database
> > settings for some reason
>
> > On Feb 17, 7:56 am, Furbee  wrote:
>
> > > That is strange. This probably won't help, but try deleting the
> > > settings.pyc file and then run python manage.py runserver again (without
> > > --settings=settings).
>
> > > Furbee
>
> > > On Fri, Feb 17, 2012 at 7:45 AM, Babatunde Akinyanmi
> > > wrote:
>
> > > > Yes I do get it. I didn't realize that while I was typing my reply
> > > > your message had already been delivered to the group.
>
> > > > On 2/17/12, Detectedstealth  wrote:
> > > > > I can connect with the same credentials that isn't the problem.
>
> > > > > The problem is if I set a password in settings.py it doesn't use a
> > > > > password as the error message states. However when I force the
> > > > > settings file with the --settings option then it reads the file
> > > > > correctly and uses the password.
>
> > > > > On Feb 17, 7:06 am, Babatunde Akinyanmi  wrote:
> > > > >> Try to connect to mysql with the same credentials on your terminal. 
> > > > >> If
> > > > >> it doesn't work then you need to reset your root password.
>
> > > > >> sudo dpkg-reconfigure mysql-server-5.1
>
> > > > >> Should do the trick and then restart the server (That works on 
> > > > >> ubuntu).
>
> > > > >> Also you should consider creating a separate user instead of using 
> > > > >> root.
>
> > > > >> On 2/17/12, Detectedstealth  wrote:
>
> > > > >> > Hi,
>
> > > > >> > I am just coming back to django development after a while of
> > > > >> > developing with pyramid. I have taking over an application.
>
> > > > >> > For some reason with the newest version of django it is not reading
> > > > >> > the password I set in settings:
>
> > > > >> > DATABASES = {
> > > > >> >     'default': {
> > > > >> >         'ENGINE': 'django.db.backends.mysql', # Add
> > > > >> > 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 
> > > > >> > 'oracle'.
> > > > >> >         'NAME': 'mydatabase',                      # Or path to
> > > > >> > database file if using sqlite3.
> > > > >> >         'USER': 'root',                      # Not used with 
> > > > >> > sqlite3.
> > > > >> >         'PASSWORD': 'mypassword',                  # Not used with
> > > > >> > sqlite3.
> > > > >> >         'HOST': '',                      # Set to empty string for
> > > > >> > localhost. Not used with sqlite3.
> > > > >> >         'PORT': '',                      # Set to empty string for
> > > > >> > default. Not used with sqlite3.
> > > > >> >     }
> > > > >> > }
>
> > > > >> > When starting the server I get the following error:
> > > > >> > ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py",
> > > > >> > line 187, in
> > > > >> > __init__
> > > > >> > _mysql_exceptions.OperationalError: (1045, "Access denied for user
> > > > >> > 'root'@'localhost' (using password: NO)")
>
> > > > >> > Not sure why it is saying there was not password. For the newest
> > > > >> > version of django is there a new way to tell python manage.py
> > > > >> > runserver what password/username/database to use?
>
> > > > >> > --
> > > > >> > You received this message because you are subscribed to the Google
> > > > >> > Groups
> > > > >> > "Django users" group.
> > > > >> > To post to this group, send email to django-users@googlegroups.com.
> > > > >> > To unsubscribe from this group, send email to
> > > > >> > django-users+unsubscr...@googlegroups.com.
> > > > >> > For more options, visit this group at
> > > > >> >http://groups.google.com/group/django-users?hl=en.
>
> > > > >> --
> > > > >> Sent from my mobile device
>
> > > > > --
> > > > > You received this message because you are subscribed to the Google 
> > > > > Groups
> > > > > "Django users" group.
> > > > > To post to this group, send email to django-users@googlegroups.com.
> > > > > To unsubscribe from this group, send email to
> > > > > django-users+unsubscr...@googlegroups.com.
> > > > > For more options, visit this group at
> > > > >http://groups.google.com/group/django-users?hl=en.
>
> > > > --
> > > > Sent from my mobile device
>
> > > > --
> > > > You received this message because you are subscribed to the Google 
> > > > Groups
> > > > "Django users" group.
> > > > To post to this group, send email to django-users@googlegroups.com.
> > > > To unsubscribe from this group, send email to
> > > > 

Re: DATABASE in settings file not working

2012-02-17 Thread Detectedstealth
I am starting to wonder if it is an opensuse bug. I am thinking about
switching back to Ubuntu.

On Feb 17, 9:04 pm, Detectedstealth  wrote:
> Yeah I have tried removing settings.pyc and __init__.pyc it
> regenerates the *.pyc files but still is not reading the database
> settings for some reason
>
> On Feb 17, 7:56 am, Furbee  wrote:
>
>
>
>
>
>
>
> > That is strange. This probably won't help, but try deleting the
> > settings.pyc file and then run python manage.py runserver again (without
> > --settings=settings).
>
> > Furbee
>
> > On Fri, Feb 17, 2012 at 7:45 AM, Babatunde Akinyanmi
> > wrote:
>
> > > Yes I do get it. I didn't realize that while I was typing my reply
> > > your message had already been delivered to the group.
>
> > > On 2/17/12, Detectedstealth  wrote:
> > > > I can connect with the same credentials that isn't the problem.
>
> > > > The problem is if I set a password in settings.py it doesn't use a
> > > > password as the error message states. However when I force the
> > > > settings file with the --settings option then it reads the file
> > > > correctly and uses the password.
>
> > > > On Feb 17, 7:06 am, Babatunde Akinyanmi  wrote:
> > > >> Try to connect to mysql with the same credentials on your terminal. If
> > > >> it doesn't work then you need to reset your root password.
>
> > > >> sudo dpkg-reconfigure mysql-server-5.1
>
> > > >> Should do the trick and then restart the server (That works on ubuntu).
>
> > > >> Also you should consider creating a separate user instead of using 
> > > >> root.
>
> > > >> On 2/17/12, Detectedstealth  wrote:
>
> > > >> > Hi,
>
> > > >> > I am just coming back to django development after a while of
> > > >> > developing with pyramid. I have taking over an application.
>
> > > >> > For some reason with the newest version of django it is not reading
> > > >> > the password I set in settings:
>
> > > >> > DATABASES = {
> > > >> >     'default': {
> > > >> >         'ENGINE': 'django.db.backends.mysql', # Add
> > > >> > 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
> > > >> >         'NAME': 'mydatabase',                      # Or path to
> > > >> > database file if using sqlite3.
> > > >> >         'USER': 'root',                      # Not used with sqlite3.
> > > >> >         'PASSWORD': 'mypassword',                  # Not used with
> > > >> > sqlite3.
> > > >> >         'HOST': '',                      # Set to empty string for
> > > >> > localhost. Not used with sqlite3.
> > > >> >         'PORT': '',                      # Set to empty string for
> > > >> > default. Not used with sqlite3.
> > > >> >     }
> > > >> > }
>
> > > >> > When starting the server I get the following error:
> > > >> > ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py",
> > > >> > line 187, in
> > > >> > __init__
> > > >> > _mysql_exceptions.OperationalError: (1045, "Access denied for user
> > > >> > 'root'@'localhost' (using password: NO)")
>
> > > >> > Not sure why it is saying there was not password. For the newest
> > > >> > version of django is there a new way to tell python manage.py
> > > >> > runserver what password/username/database to use?
>
> > > >> > --
> > > >> > You received this message because you are subscribed to the Google
> > > >> > Groups
> > > >> > "Django users" group.
> > > >> > To post to this group, send email to django-users@googlegroups.com.
> > > >> > To unsubscribe from this group, send email to
> > > >> > django-users+unsubscr...@googlegroups.com.
> > > >> > For more options, visit this group at
> > > >> >http://groups.google.com/group/django-users?hl=en.
>
> > > >> --
> > > >> Sent from my mobile device
>
> > > > --
> > > > You received this message because you are subscribed to the Google 
> > > > Groups
> > > > "Django users" group.
> > > > To post to this group, send email to django-users@googlegroups.com.
> > > > To unsubscribe from this group, send email to
> > > > django-users+unsubscr...@googlegroups.com.
> > > > For more options, visit this group at
> > > >http://groups.google.com/group/django-users?hl=en.
>
> > > --
> > > Sent from my mobile device
>
> > > --
> > > You received this message because you are subscribed to the Google Groups
> > > "Django users" group.
> > > To post to this group, send email to django-users@googlegroups.com.
> > > To unsubscribe from this group, send email to
> > > django-users+unsubscr...@googlegroups.com.
> > > For more options, visit this group at
> > >http://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 

Re: DATABASE in settings file not working

2012-02-17 Thread Detectedstealth
Yeah I have tried removing settings.pyc and __init__.pyc it
regenerates the *.pyc files but still is not reading the database
settings for some reason

On Feb 17, 7:56 am, Furbee  wrote:
> That is strange. This probably won't help, but try deleting the
> settings.pyc file and then run python manage.py runserver again (without
> --settings=settings).
>
> Furbee
>
> On Fri, Feb 17, 2012 at 7:45 AM, Babatunde Akinyanmi
> wrote:
>
>
>
>
>
>
>
> > Yes I do get it. I didn't realize that while I was typing my reply
> > your message had already been delivered to the group.
>
> > On 2/17/12, Detectedstealth  wrote:
> > > I can connect with the same credentials that isn't the problem.
>
> > > The problem is if I set a password in settings.py it doesn't use a
> > > password as the error message states. However when I force the
> > > settings file with the --settings option then it reads the file
> > > correctly and uses the password.
>
> > > On Feb 17, 7:06 am, Babatunde Akinyanmi  wrote:
> > >> Try to connect to mysql with the same credentials on your terminal. If
> > >> it doesn't work then you need to reset your root password.
>
> > >> sudo dpkg-reconfigure mysql-server-5.1
>
> > >> Should do the trick and then restart the server (That works on ubuntu).
>
> > >> Also you should consider creating a separate user instead of using root.
>
> > >> On 2/17/12, Detectedstealth  wrote:
>
> > >> > Hi,
>
> > >> > I am just coming back to django development after a while of
> > >> > developing with pyramid. I have taking over an application.
>
> > >> > For some reason with the newest version of django it is not reading
> > >> > the password I set in settings:
>
> > >> > DATABASES = {
> > >> >     'default': {
> > >> >         'ENGINE': 'django.db.backends.mysql', # Add
> > >> > 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
> > >> >         'NAME': 'mydatabase',                      # Or path to
> > >> > database file if using sqlite3.
> > >> >         'USER': 'root',                      # Not used with sqlite3.
> > >> >         'PASSWORD': 'mypassword',                  # Not used with
> > >> > sqlite3.
> > >> >         'HOST': '',                      # Set to empty string for
> > >> > localhost. Not used with sqlite3.
> > >> >         'PORT': '',                      # Set to empty string for
> > >> > default. Not used with sqlite3.
> > >> >     }
> > >> > }
>
> > >> > When starting the server I get the following error:
> > >> > ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py",
> > >> > line 187, in
> > >> > __init__
> > >> > _mysql_exceptions.OperationalError: (1045, "Access denied for user
> > >> > 'root'@'localhost' (using password: NO)")
>
> > >> > Not sure why it is saying there was not password. For the newest
> > >> > version of django is there a new way to tell python manage.py
> > >> > runserver what password/username/database to use?
>
> > >> > --
> > >> > You received this message because you are subscribed to the Google
> > >> > Groups
> > >> > "Django users" group.
> > >> > To post to this group, send email to django-users@googlegroups.com.
> > >> > To unsubscribe from this group, send email to
> > >> > django-users+unsubscr...@googlegroups.com.
> > >> > For more options, visit this group at
> > >> >http://groups.google.com/group/django-users?hl=en.
>
> > >> --
> > >> Sent from my mobile device
>
> > > --
> > > You received this message because you are subscribed to the Google Groups
> > > "Django users" group.
> > > To post to this group, send email to django-users@googlegroups.com.
> > > To unsubscribe from this group, send email to
> > > django-users+unsubscr...@googlegroups.com.
> > > For more options, visit this group at
> > >http://groups.google.com/group/django-users?hl=en.
>
> > --
> > Sent from my mobile device
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Django users" group.
> > To post to this group, send email to django-users@googlegroups.com.
> > To unsubscribe from this group, send email to
> > django-users+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> >http://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: DATABASE in settings file not working

2012-02-17 Thread Furbee
That is strange. This probably won't help, but try deleting the
settings.pyc file and then run python manage.py runserver again (without
--settings=settings).

Furbee

On Fri, Feb 17, 2012 at 7:45 AM, Babatunde Akinyanmi
wrote:

> Yes I do get it. I didn't realize that while I was typing my reply
> your message had already been delivered to the group.
>
> On 2/17/12, Detectedstealth  wrote:
> > I can connect with the same credentials that isn't the problem.
> >
> > The problem is if I set a password in settings.py it doesn't use a
> > password as the error message states. However when I force the
> > settings file with the --settings option then it reads the file
> > correctly and uses the password.
> >
> > On Feb 17, 7:06 am, Babatunde Akinyanmi  wrote:
> >> Try to connect to mysql with the same credentials on your terminal. If
> >> it doesn't work then you need to reset your root password.
> >>
> >> sudo dpkg-reconfigure mysql-server-5.1
> >>
> >> Should do the trick and then restart the server (That works on ubuntu).
> >>
> >> Also you should consider creating a separate user instead of using root.
> >>
> >> On 2/17/12, Detectedstealth  wrote:
> >>
> >>
> >>
> >>
> >>
> >>
> >>
> >>
> >>
> >> > Hi,
> >>
> >> > I am just coming back to django development after a while of
> >> > developing with pyramid. I have taking over an application.
> >>
> >> > For some reason with the newest version of django it is not reading
> >> > the password I set in settings:
> >>
> >> > DATABASES = {
> >> > 'default': {
> >> > 'ENGINE': 'django.db.backends.mysql', # Add
> >> > 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
> >> > 'NAME': 'mydatabase',  # Or path to
> >> > database file if using sqlite3.
> >> > 'USER': 'root',  # Not used with sqlite3.
> >> > 'PASSWORD': 'mypassword',  # Not used with
> >> > sqlite3.
> >> > 'HOST': '',  # Set to empty string for
> >> > localhost. Not used with sqlite3.
> >> > 'PORT': '',  # Set to empty string for
> >> > default. Not used with sqlite3.
> >> > }
> >> > }
> >>
> >> > When starting the server I get the following error:
> >> > ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py",
> >> > line 187, in
> >> > __init__
> >> > _mysql_exceptions.OperationalError: (1045, "Access denied for user
> >> > 'root'@'localhost' (using password: NO)")
> >>
> >> > Not sure why it is saying there was not password. For the newest
> >> > version of django is there a new way to tell python manage.py
> >> > runserver what password/username/database to use?
> >>
> >> > --
> >> > You received this message because you are subscribed to the Google
> >> > Groups
> >> > "Django users" group.
> >> > To post to this group, send email to django-users@googlegroups.com.
> >> > To unsubscribe from this group, send email to
> >> > django-users+unsubscr...@googlegroups.com.
> >> > For more options, visit this group at
> >> >http://groups.google.com/group/django-users?hl=en.
> >>
> >> --
> >> Sent from my mobile device
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Django users" group.
> > To post to this group, send email to django-users@googlegroups.com.
> > To unsubscribe from this group, send email to
> > django-users+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> > http://groups.google.com/group/django-users?hl=en.
> >
> >
>
> --
> Sent from my mobile device
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: DATABASE in settings file not working

2012-02-17 Thread Babatunde Akinyanmi
Yes I do get it. I didn't realize that while I was typing my reply
your message had already been delivered to the group.

On 2/17/12, Detectedstealth  wrote:
> I can connect with the same credentials that isn't the problem.
>
> The problem is if I set a password in settings.py it doesn't use a
> password as the error message states. However when I force the
> settings file with the --settings option then it reads the file
> correctly and uses the password.
>
> On Feb 17, 7:06 am, Babatunde Akinyanmi  wrote:
>> Try to connect to mysql with the same credentials on your terminal. If
>> it doesn't work then you need to reset your root password.
>>
>> sudo dpkg-reconfigure mysql-server-5.1
>>
>> Should do the trick and then restart the server (That works on ubuntu).
>>
>> Also you should consider creating a separate user instead of using root.
>>
>> On 2/17/12, Detectedstealth  wrote:
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> > Hi,
>>
>> > I am just coming back to django development after a while of
>> > developing with pyramid. I have taking over an application.
>>
>> > For some reason with the newest version of django it is not reading
>> > the password I set in settings:
>>
>> > DATABASES = {
>> >     'default': {
>> >         'ENGINE': 'django.db.backends.mysql', # Add
>> > 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
>> >         'NAME': 'mydatabase',                      # Or path to
>> > database file if using sqlite3.
>> >         'USER': 'root',                      # Not used with sqlite3.
>> >         'PASSWORD': 'mypassword',                  # Not used with
>> > sqlite3.
>> >         'HOST': '',                      # Set to empty string for
>> > localhost. Not used with sqlite3.
>> >         'PORT': '',                      # Set to empty string for
>> > default. Not used with sqlite3.
>> >     }
>> > }
>>
>> > When starting the server I get the following error:
>> > ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py",
>> > line 187, in
>> > __init__
>> > _mysql_exceptions.OperationalError: (1045, "Access denied for user
>> > 'root'@'localhost' (using password: NO)")
>>
>> > Not sure why it is saying there was not password. For the newest
>> > version of django is there a new way to tell python manage.py
>> > runserver what password/username/database to use?
>>
>> > --
>> > You received this message because you are subscribed to the Google
>> > Groups
>> > "Django users" group.
>> > To post to this group, send email to django-users@googlegroups.com.
>> > To unsubscribe from this group, send email to
>> > django-users+unsubscr...@googlegroups.com.
>> > For more options, visit this group at
>> >http://groups.google.com/group/django-users?hl=en.
>>
>> --
>> Sent from my mobile device
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>

-- 
Sent from my mobile device

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: DATABASE in settings file not working

2012-02-17 Thread Detectedstealth
I can connect with the same credentials that isn't the problem.

The problem is if I set a password in settings.py it doesn't use a
password as the error message states. However when I force the
settings file with the --settings option then it reads the file
correctly and uses the password.

On Feb 17, 7:06 am, Babatunde Akinyanmi  wrote:
> Try to connect to mysql with the same credentials on your terminal. If
> it doesn't work then you need to reset your root password.
>
> sudo dpkg-reconfigure mysql-server-5.1
>
> Should do the trick and then restart the server (That works on ubuntu).
>
> Also you should consider creating a separate user instead of using root.
>
> On 2/17/12, Detectedstealth  wrote:
>
>
>
>
>
>
>
>
>
> > Hi,
>
> > I am just coming back to django development after a while of
> > developing with pyramid. I have taking over an application.
>
> > For some reason with the newest version of django it is not reading
> > the password I set in settings:
>
> > DATABASES = {
> >     'default': {
> >         'ENGINE': 'django.db.backends.mysql', # Add
> > 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
> >         'NAME': 'mydatabase',                      # Or path to
> > database file if using sqlite3.
> >         'USER': 'root',                      # Not used with sqlite3.
> >         'PASSWORD': 'mypassword',                  # Not used with
> > sqlite3.
> >         'HOST': '',                      # Set to empty string for
> > localhost. Not used with sqlite3.
> >         'PORT': '',                      # Set to empty string for
> > default. Not used with sqlite3.
> >     }
> > }
>
> > When starting the server I get the following error:
> > ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py",
> > line 187, in
> > __init__
> > _mysql_exceptions.OperationalError: (1045, "Access denied for user
> > 'root'@'localhost' (using password: NO)")
>
> > Not sure why it is saying there was not password. For the newest
> > version of django is there a new way to tell python manage.py
> > runserver what password/username/database to use?
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Django users" group.
> > To post to this group, send email to django-users@googlegroups.com.
> > To unsubscribe from this group, send email to
> > django-users+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> >http://groups.google.com/group/django-users?hl=en.
>
> --
> Sent from my mobile device

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: DATABASE in settings file not working

2012-02-17 Thread Babatunde Akinyanmi
Try to connect to mysql with the same credentials on your terminal. If
it doesn't work then you need to reset your root password.

sudo dpkg-reconfigure mysql-server-5.1

Should do the trick and then restart the server (That works on ubuntu).

Also you should consider creating a separate user instead of using root.

On 2/17/12, Detectedstealth  wrote:
> Hi,
>
> I am just coming back to django development after a while of
> developing with pyramid. I have taking over an application.
>
> For some reason with the newest version of django it is not reading
> the password I set in settings:
>
> DATABASES = {
> 'default': {
> 'ENGINE': 'django.db.backends.mysql', # Add
> 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
> 'NAME': 'mydatabase',  # Or path to
> database file if using sqlite3.
> 'USER': 'root',  # Not used with sqlite3.
> 'PASSWORD': 'mypassword',  # Not used with
> sqlite3.
> 'HOST': '',  # Set to empty string for
> localhost. Not used with sqlite3.
> 'PORT': '',  # Set to empty string for
> default. Not used with sqlite3.
> }
> }
>
> When starting the server I get the following error:
> ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py",
> line 187, in
> __init__
> _mysql_exceptions.OperationalError: (1045, "Access denied for user
> 'root'@'localhost' (using password: NO)")
>
> Not sure why it is saying there was not password. For the newest
> version of django is there a new way to tell python manage.py
> runserver what password/username/database to use?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>

-- 
Sent from my mobile device

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: DATABASE in settings file not working

2012-02-17 Thread Detectedstealth
I have it working, however I need to provide the settings file when
running all commands:

python manage.py runserver --settings=settings

On Feb 17, 6:11 am, Detectedstealth  wrote:
> Hi,
>
> I am just coming back to django development after a while of
> developing with pyramid. I have taking over an application.
>
> For some reason with the newest version of django it is not reading
> the password I set in settings:
>
> DATABASES = {
>     'default': {
>         'ENGINE': 'django.db.backends.mysql', # Add
> 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
>         'NAME': 'mydatabase',                      # Or path to
> database file if using sqlite3.
>         'USER': 'root',                      # Not used with sqlite3.
>         'PASSWORD': 'mypassword',                  # Not used with
> sqlite3.
>         'HOST': '',                      # Set to empty string for
> localhost. Not used with sqlite3.
>         'PORT': '',                      # Set to empty string for
> default. Not used with sqlite3.
>     }
>
> }
>
> When starting the server I get the following error:
> ...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py",
> line 187, in
> __init__
> _mysql_exceptions.OperationalError: (1045, "Access denied for user
> 'root'@'localhost' (using password: NO)")
>
> Not sure why it is saying there was not password. For the newest
> version of django is there a new way to tell python manage.py
> runserver what password/username/database to use?

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



DATABASE in settings file not working

2012-02-17 Thread Detectedstealth
Hi,

I am just coming back to django development after a while of
developing with pyramid. I have taking over an application.

For some reason with the newest version of django it is not reading
the password I set in settings:

DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # Add
'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
'NAME': 'mydatabase',  # Or path to
database file if using sqlite3.
'USER': 'root',  # Not used with sqlite3.
'PASSWORD': 'mypassword',  # Not used with
sqlite3.
'HOST': '',  # Set to empty string for
localhost. Not used with sqlite3.
'PORT': '',  # Set to empty string for
default. Not used with sqlite3.
}
}

When starting the server I get the following error:
...MySQL_python-1.2.3-py2.7-linux-x86_64.egg/MySQLdb/connections.py",
line 187, in
__init__
_mysql_exceptions.OperationalError: (1045, "Access denied for user
'root'@'localhost' (using password: NO)")

Not sure why it is saying there was not password. For the newest
version of django is there a new way to tell python manage.py
runserver what password/username/database to use?

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.