Electronics & Programming

develissimo

Open Source electronics development and programming

  • You are not logged in.

#1 Dec. 30, 2010 00:39:22

Emmanuel M.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

django and eclipse


I installed the pydev plugin in eclipse.
I configured it.
Imported my django project and it almost works.

Is any one of you using django/eclipse?

Well, all goes well until I start the django development server.
1/ how can I change the default port, it is running on ?
2/ My sqlite db files is regenerated by the runserver (I had never
seen that!) in a different directory (at the project level).
If I symlink the 2 db files, it works as expected.
Any clue?

BTW, I noticed that when creating a django project in eclipse, it ask
for the path to the db files (when using sqlite3)
It is configured to point to the right location, but runserver doesn't get that.
So what is this db file path used for ? (settings.py is created but
not even configured...)

--
Emmanuel Mayssat

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

Offline

#2 Dec. 30, 2010 00:54:46

Emmanuel M.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

django and eclipse


For the sqlite.db file issue, I changed the settings.py with:

import os
PROJECT_DIR = os.path.dirname(__file__)
...
DATABASE_ENGINE = 'sqlite3'
DATABASE_NAME = os.path.join(PROJECT_DIR, 'sqlite.db')

that now works as expected.
--
Emmanuel Mayssat



On Wed, Dec 29, 2010 at 4:38 PM, Emmanuel Mayssat <emays...@gmail.com> wrote:
> I installed the pydev plugin in eclipse.
> I configured it.
> Imported my django project and it almost works.
>
> Is any one of you using django/eclipse?
>
> Well, all goes well until I start the django development server.
> 1/ how can I change the default port, it is running on ?
> 2/ My sqlite db files is regenerated by the runserver (I had never
> seen  that!) in a different directory (at the project level).
> If I symlink the 2 db files, it works as expected.
> Any clue?
>
> BTW, I noticed that when creating a django project in eclipse, it ask
> for the path to the db files (when using sqlite3)
> It is configured to point to the right location, but runserver doesn't get
> that.
> So what is this db file path used for ? (settings.py is created but
> not even configured...)
>
> --
> Emmanuel Mayssat
>

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

Offline

#3 Dec. 30, 2010 05:06:05

girish s.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

django and eclipse


to change port:
django-admin.py runsserver <new port number>

On Thu, Dec 30, 2010 at 6:24 AM, Emmanuel Mayssat <emays...@gmail.com>wrote:

> For the sqlite.db file issue, I changed the settings.py with:
>
> import os
> PROJECT_DIR = os.path.dirname(__file__)
> ...
> DATABASE_ENGINE = 'sqlite3'
> DATABASE_NAME = os.path.join(PROJECT_DIR, 'sqlite.db')
>
> that now works as expected.
> --
> Emmanuel Mayssat
>
>
>
> On Wed, Dec 29, 2010 at 4:38 PM, Emmanuel Mayssat <emays...@gmail.com>
> wrote:
> > I installed the pydev plugin in eclipse.
> > I configured it.
> > Imported my django project and it almost works.
> >
> > Is any one of you using django/eclipse?
> >
> > Well, all goes well until I start the django development server.
> > 1/ how can I change the default port, it is running on ?
> > 2/ My sqlite db files is regenerated by the runserver (I had never
> > seen that!) in a different directory (at the project level).
> > If I symlink the 2 db files, it works as expected.
> > Any clue?
> >
> > BTW, I noticed that when creating a django project in eclipse, it ask
> > for the path to the db files (when using sqlite3)
> > It is configured to point to the right location, but runserver doesn't
> get that.
> > So what is this db file path used for ? (settings.py is created but
> > not even configured...)
> >
> > --
> > Emmanuel Mayssat
> >
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com<django-users%2bunsubscr...@googlegroups.com>
> .
> For more options, visit this group at
>http://groups.google.com/group/django-users?hl=en.
>
>


--
Girish M S

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

Offline

#4 Dec. 30, 2010 11:47:43

Rajendra W.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

django and eclipse


To run Django server on specific IP and port you can use following
command:

python manage.py runserver <IP>:<port>

e.g. python manage.py runserver 11.12.13.145:5678

If you do not specify IP and the port it starts on
localhost(127.0.0.1) and port 8000.

If you are using command prompt and do not want to use it, you can use
eclipse for the same, following link is useful for this:http://www.magpiebrain.com/2006/10/09/using-eclipse-and-pydev-for-django/--Rajendra.

On Dec 30, 10:05 am, girish shabadimath <girishmss.1...@gmail.com>
wrote:
> to change port:
> django-admin.py runsserver <new port number>
>
> On Thu, Dec 30, 2010 at 6:24 AM, Emmanuel Mayssat <emays...@gmail.com>wrote:
>
>
>
> > For the sqlite.db file issue, I changed the settings.py with:
>
> > import os
> > PROJECT_DIR = os.path.dirname(__file__)
> > ...
> > DATABASE_ENGINE = 'sqlite3'
> > DATABASE_NAME = os.path.join(PROJECT_DIR, 'sqlite.db')
>
> > that now works as expected.
> > --
> > Emmanuel Mayssat
>
> > On Wed, Dec 29, 2010 at 4:38 PM, Emmanuel Mayssat <emays...@gmail.com>
> > wrote:
> > > I installed the pydev plugin in eclipse.
> > > I configured it.
> > > Imported my django project and it almost works.
>
> > > Is any one of you using django/eclipse?
>
> > > Well, all goes well until I start the django development server.
> > > 1/ how can I change the default port, it is running on ?
> > > 2/ My sqlite db files is regenerated by the runserver (I had never
> > > seen  that!) in a different directory (at the project level).
> > > If I symlink the 2 db files, it works as expected.
> > > Any clue?
>
> > > BTW, I noticed that when creating a django project in eclipse, it ask
> > > for the path to the db files (when using sqlite3)
> > > It is configured to point to the right location, but runserver doesn't
> > get that.
> > > So what is this db file path used for ? (settings.py is created but
> > > not even configured...)
>
> > > --
> > > Emmanuel Mayssat
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Django users" group.
> > To post to this group, send email to django-us...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > django-users+unsubscr...@googlegroups.com<django-users%2bunsubscr...@googlegroups.com>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/django-users?hl=en.
>
> --
> Girish M S

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

Offline

#5 Dec. 30, 2010 13:24:14

C.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

django and eclipse


You have to set up the run environment. Make sure on run manage.py and
the parameters are runserver x.x.x.x:000 where x.x.x.x is the server
and :000 is the port you want to run from. After that it should not
ask anything and run off your settings.

On Dec 29, 7:38 pm, Emmanuel Mayssat <emays...@gmail.com> wrote:
> I installed the pydev plugin in eclipse.
> I configured it.
> Imported my django project and it almost works.
>
> Is any one of you using django/eclipse?
>
> Well, all goes well until I start the django development server.
> 1/ how can I change the default port, it is running on ?
> 2/ My sqlite db files is regenerated by the runserver (I had never
> seen  that!) in a different directory (at the project level).
> If I symlink the 2 db files, it works as expected.
> Any clue?
>
> BTW, I noticed that when creating a django project in eclipse, it ask
> for the path to the db files (when using sqlite3)
> It is configured to point to the right location, but runserver doesn't get
> that.
> So what is this db file path used for ? (settings.py is created but
> not even configured...)
>
> --
> Emmanuel Mayssat

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

Offline

Board footer

Moderator control

Enjoy the 21st of August
PoweredBy

The Forums are managed by develissimo stuff members, if you find any issues or misplaced content please help us to fix it. Thank you! Tell us via Contact Options
Leave a Message
Welcome to Develissimo Live Support