Anyone using PyScripter to debug their Django apps?

2012-09-22 Thread Lars Ruoff
Hi, The PyScripter FAQ has an entry about how to debug Django applications: https://code.google.com/p/pyscripter/wiki/FAQ#How_can_I_debug_Django_applications? Has anybody tried this out? It doesn't work for me. I can run my Django app but it ignores my breakpoints. See my post on the

Re: Where/how to load global static data?

2012-04-05 Thread Lars Ruoff
Thanks a lot, Tom. That magnificantly answers my question. :-) One last thing: "... a function which loads, parses and returns the data, and memoize the result." That (and the first option also) means that we stay within the same Python interpreter environment even for different requests to the

Re: Where/how to load global static data?

2012-04-05 Thread Lars Ruoff
On Apr 5, 2:31 pm, kenneth gonsalves <law...@thenilgiris.com> wrote: > On Thu, 2012-04-05 at 05:25 -0700, Lars Ruoff wrote: > > the question is not about serving static data (like HTML, images > > etc.), but having global python variables initialized once, for all >

Re: Where/how to load global static data?

2012-04-05 Thread Lars Ruoff
On Apr 5, 9:05 am, kenneth gonsalves wrote: > I may be wrong, but AFAIK django is not a server - it is a framework > that runs on a web server, so every new request starts a new instance of > your site. You could use cacheing to serve static data - but this is not > like

Re: Where to load global static data?

2012-04-05 Thread Lars Ruoff
On Apr 5, 9:43 am, Mike Dewhirst <mi...@dewhirst.com.au> wrote: > On 5/04/2012 4:53pm, Lars Ruoff wrote: > > > Sorry, that message went off (twice!) while i was in the middle of > > typing :-) > > > The question is: > > How do i load static global data on

Re: Port Django to Javascript

2012-04-05 Thread Lars Ruoff
On Apr 5, 8:48 am, kenneth gonsalves wrote: > frankly these are not questions to be asked of an open source project. On the contrary, many more open source projects should ask themselves that question! I'm very much interested in the answer, since i really don't get it.

Where/how to load global static data?

2012-04-05 Thread Lars Ruoff
Hi, i'm using Django the first time for a browser game project. I will need to have some globally accessible, static data like string tables for every view. These would be loaded from XML files. For the moment all i have figured out with Django is that my code will be called via callbacks for the

Re: Where to load global static data?

2012-04-05 Thread Lars Ruoff
Sorry, that message went off (twice!) while i was in the middle of typing :-) The question is: How do i load static global data once and for all at server startup. I.e. i'd like to have that data in memory and accessible from any view during the lifetime of the server, so that it needs NOT to be

Where to load global static data?

2012-04-05 Thread Lars Ruoff
Hi, i'm using Django the first time for a browser game project. I will need to have some globally accessible, static data like string tables for every view. These would be loaded from XML files. For the moment all i have figured out with Django is that my code will be called via callbacks for the

Where to load global static data?

2012-04-05 Thread Lars Ruoff
Hi, i'm using Django the first time for a browser game project. I will need to have some globally accessible, static data like string tables for every view. These would be loaded from XML files. For the moment all i have figured out with Django is that my code will be called via callbacks for the

Re: Have different databases using SQLite

2011-10-07 Thread Lars Ruoff
Many thanks, Tom! Didn't notice this was covered in the docs. -- 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/msg/django-users/-/Mue4TVMYw_0J. To post to this group, send

Have different databases using SQLite

2011-10-06 Thread Lars Ruoff
Hi, i'm having the Django database set up like so: DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': 'D:\Users\Max\Projects\my4x\data\my4x.db', 'USER': '', # Not used with sqlite3. 'PASSWORD': '', #

Re: 2D map application: performance and design question

2010-11-04 Thread Lars Ruoff
ood results for my use cases. > > Regards > Knut > > On Tue, Nov 2, 2010 at 9:28 PM, Lars Ruoff <lars.ru...@gmail.com> wrote: > > Ok, thanks for the suggestion, Javier. > > I implemented this and it showed: > > I'm spending about > > 0.2 secs for the

Re: 2D map application: performance and design question

2010-11-02 Thread Lars Ruoff
, Javier Guerra Giraldez <jav...@guerrag.com> wrote: > On Tue, Nov 2, 2010 at 3:35 AM, Lars Ruoff <lars.ru...@gmail.com> wrote: > > Ok, so having excluded SQLite and the static served files, I'd like to > > test if the server matters. What would be a minimum Apache install a

Re: 2D map application: performance and design question

2010-11-02 Thread Lars Ruoff
Ok, so having excluded SQLite and the static served files, I'd like to test if the server matters. What would be a minimum Apache install and config to run Django locally (on Windows)? On Nov 1, 7:30 pm, Lars Ruoff <lars.ru...@gmail.com> wrote: > Ok, thanks all, > > So following B

Re: 2D map application: performance and design question

2010-11-01 Thread Lars Ruoff
Ok, thanks all, So following Bill's advice, i did: >python manage.py shell >>> import game.models >>> list(game.models.Location.objects.filter( \ ... x__gte=34, \ ... x__lte=46, \ ... y__gte=24, \ ... y__lte=36)) ...and the result showed up instantly! So it seems DB is not the issue.

Re: 2D map application: performance and design question

2010-11-01 Thread Lars Ruoff
com> wrote: > On 1 November 2010 10:59, Lars Ruoff <lars.ru...@gmail.com> wrote: > > > > > Hello, > > > first of all, these are my first steps with Django, and i only have > > limited experience with Python, so please be patient. > > > I'm using it f

Re: 2D map application: performance and design question

2010-11-01 Thread Lars Ruoff
Hi Daniel, you are right that images are being loaded. But i gave it a try and replaced the images by text. Still the page takes about 3 seconds to load. Lars On Nov 1, 12:30 pm, Daniel Roseman wrote: > It's a bit hard to tell without knowing how the slowness appears.

Re: 2D map application: performance and design question

2010-11-01 Thread Lars Ruoff
Ok, but that said, the database isn't that big here. (Well, i guess) There are currently 4800 entries in the "Location" table. Is this too much for SQLite already? May it be the query in locations = Location.objects.filter( \ x__gte=center_location.x-half_x, \

2D map application: performance and design question

2010-11-01 Thread Lars Ruoff
Hello, first of all, these are my first steps with Django, and i only have limited experience with Python, so please be patient. I'm using it for what is intended to be a browser game in the future. The main part of the game is a zoom view on a two-dimensional map of fields. I'm currently using