Is Python in your path?
On Wed, Sep 14, 2011 at 10:01 PM, PremAnand Lakshmanan
wrote:
> I have a problem executing this command,
>
> C:\Python27\Lib\site-packages\django\bin\django-admin.py startproject
> mysite2
>
> SyntaxError: invalid syntax
>
> I get the above error..
>
> --
> Prem
>
> --
>
Maybe reinstall django would resolve this problem
On Thu, Sep 15, 2011 at 10:01 AM, PremAnand Lakshmanan
wrote:
> I have a problem executing this command,
>
> C:\Python27\Lib\site-packages\django\bin\django-admin.py startproject
> mysite2
>
> SyntaxError: invalid syntax
>
> I get the above error
I have a problem executing this command,
C:\Python27\Lib\site-packages\django\bin\django-admin.py startproject
mysite2
SyntaxError: invalid syntax
I get the above error..
--
Prem
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to t
On 09/15/2011 01:44 AM, Russell Keith-Magee wrote:
> 2011/9/14 Simon Bächler :
>> Any news considering HTTPS and runserver?
>
> What "News" are you expecting?
>
> The Django project has made no secret of the fact that we don't
> consider runserver to be a "real" webserver. It isn't intended for
>
if you need to simulate https for development, like for facebook apps,
you can setup apache proxy.
something like:
ProxyPass / http://localhost:8000/ retry=1
ProxyPassReverse / http://localhost:8000/
ProxyPreserveHost On
ErrorLog ${APACHE_LOG_DIR}/error.log
2011/9/14 Simon Bächler :
> Any news considering HTTPS and runserver?
What "News" are you expecting?
The Django project has made no secret of the fact that we don't
consider runserver to be a "real" webserver. It isn't intended for
production use. We haven't spent any time or effort auditing it f
Hello I have these two models:
class SubOrder(models.Model):
"""
This is model for single order
it should be used later in complex order
"""
product = models.ForeignKey(Product)
quantity = models.SmallIntegerField()
class Order(models.Model):
"Model for complex order
I made what I wanted using signals:)
All works now. I use post delete to be sure that object is deleted, than I
remove images.
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To view this discussion on the web visit
https://groups.google.com/d
Make sure you run step 2.5 here on the current database before running
syncdb: http://postgis.refractions.net/docs/ch02.html#id2619431
Did you do that?
Lucian
On Wed, Sep 14, 2011 at 11:39 PM, Dan H wrote:
> I am getting the following error:
>
> django.core.exceptions.ImproperlyConfigured: Cann
I am getting the following error:
django.core.exceptions.ImproperlyConfigured: Cannot determine PostGIS
version for database "dbname". GeoDjango requires at least PostGIS
version 1.3. Was the database created from a spatial database
template?
when i try to run: python manage.py syncdb
and when i
Finally! The admin interface worked, when I used the dev version
in a virtualenv. I cleaned every trace of Django in my system,
and I had to compile (requires python-dev package in
Ubuntu) and install MySQLdb into the virtualenv.
Not sure what exactly was wrong before, but Babatunde's suggestion
t
I have an application which is designed for publishing blog posts etc.
I upload images but normally they are at the end of the text because they
are uploaded after I save the entry, that means I cant embedd them directly
inside the text.
Is there any way I can add new images directly inside the
Hi Tom,
I checked the link you send and probably you are right but
can you explain why this is a bad solution?
Yes using autocommit() or disabling transactions seems more right
are there any downsides of the update() that you are seeing?
Image a case when you want to update the result set without
Reinout van Rees has posted several articles on using Django class
based views that you might find useful (posted Aug 23/24 2011 ):
http://reinout.vanrees.org/weblog/2011/08/24/class-based-views-walkthrough.html
--
You received this message because you are subscribed to the Google Groups
"Dja
On Wed, Sep 14, 2011 at 6:10 AM, Tom Evans wrote:
I'm not entirely experienced with scgi or uWSGI, but I'm almost
> certain that neither of them talk HTTP, which is what Firefox uses to
> talk to servers. You need to connect your WSGI/SCGI server to a HTTP
> server like Apache, lighttpd, Cherokee
Thanks for the input from both of you! And Donald, I think I'll take you up
on that offer. I'd really like to learn them. Hopefully down the line, when
this initial project is out the door and I have solid understanding of the
CBV's, I'll be able to contribute a little to the documentation as well.
Agreed, and fwiw both you Kurtis, and anyone else can feel free to ping me
directly in #django if they need help getting the hang of CBV's, if i'm around
(which I am most the day typically) I'll be more then happy to help.
On Wednesday, September 14, 2011 at 9:54 AM, Andre Terra wrote:
> OTO
OTOH, getting the hang of it can be hard with the current state of the docs
and given that they require a completely different mindset when coding
views.
Cheers,
AT
On Wed, Sep 14, 2011 at 10:35 AM, Donald Stufft wrote:
> Class Based Views let you override and subclass views to modify their
>
Class Based Views let you override and subclass views to modify their
behavior, I find them to be very quick once you get the hang of them.
On Wednesday, September 14, 2011 at 9:33 AM, Kurtis wrote:
> Hey Guys,
>
> I'm relatively new to Django 1.3. As others have noticed, there is
> less doc
Hey Guys,
I'm relatively new to Django 1.3. As others have noticed, there is
less documentation around the Class-Based views than typical for
Django. No needs for apologies as I have seen in other threads. I
don't blame others for my lack of knowledge :)
If I am working on a large project from sc
14.9.2011 12:46, Jonas H. kirjoitti:
On 09/14/2011 11:37 AM, Иван Иванов wrote:
The problem here is, like Peter said, that you cannot order before
grouping. And that's very annoying.
Of course you can, using a subselect just like I showed. SQLite example:
> .schema
CREATE TABLE a (name varch
On Wed, Sep 14, 2011 at 2:12 AM, mohammed safeer.mtp
wrote:
> if a user hits “Refresh” on a page that was loaded via POST, that request is
> be repeated.
> is there any remedy for this problem??
No, you can't prevent a web browser from re-POSTing forms.
What you can do is prevent the browser fro
Any news considering HTTPS and runserver?
I tried the stunnel method but I get the message: Line 5: End of
section https: SSL server needs a certificate.
Stunnel also complains about the openssl version. I have 0.9.8r
installed. The build of 1.0 fails on OSX.
When I then try to access the page I
And I apologize for not even saying yours, Robert!
Yours,
André
On Wed, Sep 14, 2011 at 9:32 AM, Andre Terra wrote:
> Take a look at the aggregation docs at http://django.me/aggregation for
> sum, group by, etc.
>
>
> Cheers,
> AT
>
>
> On Tue, Sep 13, 2011 at 7:44 PM, Robert wrote:
>
>>
>>
On Sun, Sep 11, 2011 at 7:40 AM, Micah Carrick wrote:
> I have
> read https://code.djangoproject.com/wiki/CookBookThreadlocalsAndUser and
> numerous other discussions about the use of threading.local() yet I still
> see it being employed in various projects.
> I have recently implemented a referra
Take a look at the aggregation docs at http://django.me/aggregation for sum,
group by, etc.
Cheers,
AT
On Tue, Sep 13, 2011 at 7:44 PM, Robert wrote:
>
> I apologize for using AT rather than your name, Andre.
>
> On Sep 13, 6:42 pm, Robert wrote:
> > Thanks, AT. Actually this is the article
After you successfully process a POST request, you can use a redirect to
send the user back to the orginal page.
On Wed, Sep 14, 2011 at 4:24 AM, Tom Evans wrote:
> On Wed, Sep 14, 2011 at 8:12 AM, mohammed safeer.mtp
> wrote:
> > if a user hits “Refresh” on a page that was loaded via POST, tha
On Wed, Sep 14, 2011 at 8:12 AM, Ilian Iliev wrote:
> How are you pulling the data from the database in the desktop app - using
> pure SQL or using the ORM?
>
> If using the ORM it is possible it to cache the results of the database so
> you can run:
>
> mymodel.objects.update()
>
> This should cl
On Wed, Sep 14, 2011 at 8:12 AM, mohammed safeer.mtp
wrote:
> if a user hits “Refresh” on a page that was loaded via POST, that request is
> be repeated.
> is there any remedy for this problem??
>
Yes, don't load the page via POST.
POST requests are meant to be used for data modifying requests,
if a user hits “Refresh” on a page that was loaded via POST, that request is
be repeated.
is there any remedy for this problem??
--
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.
On 09/14/2011 11:37 AM, Иван Иванов wrote:
The problem here is, like Peter said, that you cannot order before
grouping. And that's very annoying.
Of course you can, using a subselect just like I showed. SQLite example:
> .schema
CREATE TABLE a (name varchar, mod int);
e> select * from a;
b1|1
Hi again,
maybe I get an answer if I ask the other way round.
I've got an inline admin model with a generic foreignkey and I want to
validate a set of it's properties in the models clean() method. If I add
a new model neither content_type nor object_id is set in the clean()
method, but if I t
На Wed, 14 Sep 2011 10:59:01 +0200
"Jonas H." написа:
> On 09/14/2011 04:35 AM, Peter of the Norse wrote:
> > What are you trying to do? The outer GROUP BY destroys the inner
> > ORDER BY. Try putting them on the same level and see what happens.
>
> Say I've got an Event table and some records l
Correct,
You need a webserver in front of manage.py runfcgi, which understands the
protocol.
To talk to django directly with your browser use manage.py runserver
On 14 September 2011 10:10, Tom Evans wrote:
> On Sat, Sep 10, 2011 at 9:05 PM, Brian Myers
> wrote:
> > It seems I am getting a
On Sat, Sep 10, 2011 at 9:05 PM, Brian Myers wrote:
> It seems I am getting an error from the WSGI server after all. As a reminder,
> my uwsgi process is started from upstart like this:
>
> exec python /var/www/NurseTriage/triagedb/manage.py runfcgi protocol=scgi
> method=threaded host=127.0.0.1
It's a bit offtopic, but:
There is a project for non relational Django, and they have released
backend for django and mongoDB. It might be interesting for you, if you
don't know about the project:
http://www.allbuttonspressed.com/blog/django/2010/05/MongoDB-backend-for-Django-nonrel-released
На T
On 09/14/2011 04:35 AM, Peter of the Norse wrote:
What are you trying to do? The outer GROUP BY destroys the inner ORDER BY. Try
putting them on the same level and see what happens.
Say I've got an Event table and some records like this
name: foo, timestamp: 9 pm
name: foo, timestamp: 10p
Brilliant - that does the trick! Many thanks Ilian. A very simple solution
yet I trawled the documentation and never came across it. Must've been
looking in the wrong place. Yes, I'm using the ORM... and occasionally raw
SQL for the app.
Cheers
Phil
--
You received this message because you ar
How are you pulling the data from the database in the desktop app - using
pure SQL or using the ORM?
If using the ORM it is possible it to cache the results of the database so
you can run:
mymodel.objects.update()
This should clear the cache.
--
eng. Ilian Iliev
Web Software Developer
Mobile:
39 matches
Mail list logo