Re: Cannot resolve keyword '___' into field

2007-05-14 Thread Mark Jarecki
The temporary fix that I've employed at the moment is e.g.: Instead of >> osIcons = product.productOSIcons.filter(isPublished=True).order_by >> ('osIconName') I've got: icons = ProductOSIcons.objects.filter(isPublished=True) osIcons2 = [] for icon in icons: if Products.

Re: Cannot resolve keyword '___' into field

2007-05-14 Thread Mark Jarecki
I'm not sure whether this could be the cause of the error, when I start Apache on the server, I get the message: Failed to enable the 'httpready' Accept Filter Could this somehow be causing the problem? My host won't fix it on the shared production server, unless it's a "life and death issue".

No "many-to-many tables for Group model" on syncdb

2007-05-14 Thread Javier
Hi, I'm creating a django proyect and when i want to add a group and the group's permission i get a "Table 'mysite.auth_group_permissions' doesn't exist" I've seen that in some tutorials, on syncdb, the output contains the following line: Creating many-to-many tables for Group model I never see

Newform and Minimal File Upload Example

2007-05-14 Thread Michael Lake
Hi all Guillaume wrote in May "Newform and File Upload problem" > Well, my message was maybe a little long. I still have not found answers > to my problem. To make it short, Is there anywhere a short example of file > upload using newform ? > The most simple thing with a model with 1 FileFi

Very Urgent requirements

2007-05-14 Thread delhi job bank
Very Urgent requirements Pls sends your CV in www.allindiajobbank.com website. It is fast and gives U positive response. Pls pass this message to Ur friend also because vacancies are waiting. ACCOUNTS MANAGER Delhi Daily involvement in operations to ensure and effective execution of accoun

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread Forest Bond
On Tue, May 15, 2007 at 01:34:21AM -, elemental wrote: > Still redundant...but it seems like I'm merely returning self.passport > rather than changing it as before. Am I correct here? Quick look-over suggests that you'll be just fine. Maybe the exception you're getting has something to do wit

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread elemental
Thanks for the updates and giving the code a closer look. It may just be my local configuration (I'll play with the code once I get it on the live server), but I cannot get past the "ordinal not in range(128)" error without performing two base64 encodings. I'm sure this is why I have to decode twi

Installing Django on Plesk server

2007-05-14 Thread sedated
Hey folks. I am trying to get Django to install onto a Plesk server and I was wondering if anyone has had any luck getting it to install and run properly. Mind you, I am a complete newbie and haven't touched Django before so any getting it going would be great! Thanks. --~--~-~--~

Re: assertRedirects

2007-05-14 Thread Russell Keith-Magee
On 5/15/07, Jiri Barton <[EMAIL PROTECTED]> wrote: > > Or, do you think this is too specific for an interface? Do I have to > parse the response URL by myself? Redirecting to a GET with data is a fairly eclectic edge case, and I can't say I'm a huge fan of an assertion statement modifying the var

Re: ManyToManyField and TypeError using lists

2007-05-14 Thread Russell Keith-Magee
On 5/15/07, Milan Andric <[EMAIL PROTECTED]> wrote: > > A friend on IRC informed me .. > > since the object has no ID yet > and an m2m is a link between IDs > t = Tutorial(...everything but author...) > t.save() > t.author.add(user1) FYI, the following is also legal: t = Tutorial(...everything b

+ Important: Repent, Completely trust in God only and, Love Him with all of your heart.

2007-05-14 Thread Secret
There is a section below with the title "Atheism and Evolution are WRONG." All those who have sinned deserve to suffer in Hell forever. "Pride" is an example of a terrible sin. 1. Repent (be truly sorry for your sins; beg for God's forgiveness; abandon sin; ask Him to help you stop sinning; and

Re: Full history branch unable to retrieve audit trail information

2007-05-14 Thread Russell Keith-Magee
On 5/15/07, jeffhg58 <[EMAIL PROTECTED]> wrote: > > Not sure if many people have used the full history branch. But, I can > see the ChangeLog information via the admin site. But, when I try and > get information via the shell > I get ChangeLog is not defined. Is there something I need to import to

Re: Cannot resolve keyword '___' into field

2007-05-14 Thread Mark Jarecki
Just to let you know, the code below works fine on the development server. I've now tried all the patches and the error still persists. Are there any suggestions? Cheers Mark On 14/05/2007, at 1:33 PM, Mark Jarecki wrote: > Hi, > > Im currently at a loss about how to fix this issue. > > I

Re: Random features in sidebar

2007-05-14 Thread Benjamin Slavin
On 5/14/07, Mordy Ovits <[EMAIL PROTECTED]> wrote: > And (after checking the python docs because I still think in Python > 1.5.2), random.sample() makes even more sense. For those interested, the snippet I posted (#230) has been updated to reflect the results of this discussion. - Ben --~--~-

Model subclassing

2007-05-14 Thread Joe
I was wondering what the status of this is? I know that it broke a while back with the introduction of magic object removal, and has been in the pipeline since. I just tested it out on my recent SVN checkout, and it seemed to create the tables in the database in the way that one would expect. Howe

RE: Using newforms for multiple db rows

2007-05-14 Thread Chris Brand
> I think if it were me I'd build a form builder function, metaclass, or > do it in __init__. Probably the easiest is passing in an argument to > __init__ , that gives enough information to build the form. That sounds like the kind of thing I'm looking for. Thanks very much once again, Chris

problem with file download?

2007-05-14 Thread Bob Dively
Hi all. Another n00b question. I'm trying to send an Excel file to the user thusly: fullpath = os.path.join('C:/', 'text.xls') response = HttpResponse(file(fullpath).read(), mimetype='application/ vnd.ms-excel') response['Content-disposition'] = 'Attachment; filename=extract.xls' return response

Re: SQL Queries over multiple Tables

2007-05-14 Thread Jeremy Dunck
On 5/14/07, James Bennett <[EMAIL PROTECTED]> wrote: > > On 5/14/07, Sven Herzing <[EMAIL PROTECTED]> wrote: > > and I like to get the Products for a specific group and for a specific > > company. > > Given a specific company name and a specific product group name, the > following retrieves all th

Discussion on urgently-looking-for-python-with-django-developers---london

2007-05-14 Thread Vinay Sajip
Are you looking for contract developers, permanent developers or either? --~--~-~--~~~---~--~~ 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 un

Re: how do I get new record PK after save()?

2007-05-14 Thread Bob Dively
On May 10, 8:02 pm, "Russell Keith-Magee" <[EMAIL PROTECTED]> wrote: > Not quite. AutoField defines a field that tells the DB to choose the > next available value. An AutoField is added automatically to every > Django model that doesn't define its own 'primary_key=True' field > (i.e., you don't n

Allowed tags filter?

2007-05-14 Thread Mordy Ovits
From the docs, there are two html tag-related filters: striptags and removetags. The former removes all tags and the latter a list of banned tags. Is there a similar tag but that has an *allowed* list of tags? E.g., could allows and and only those? Thanks, Mordy --~--~-~--~~--

Re: SQL Queries over multiple Tables

2007-05-14 Thread James Bennett
On 5/14/07, Sven Herzing <[EMAIL PROTECTED]> wrote: > and I like to get the Products for a specific group and for a specific > company. Given a specific company name and a specific product group name, the following retrieves all the products which belong to that company and that group: >>> acme_

Re: FLV Video Uploader in Django

2007-05-14 Thread badger17
On May 14, 7:17 pm, Matt Dennewitz <[EMAIL PROTECTED]> wrote: > how do you apply the patch? > > dumb question, but ive never applied one before :) something like: change dir to wherever your django install is, in my case: cd /usr/lib/python/site-packages then patch -p1 < patch_name.diff repl

SQL Queries over multiple Tables

2007-05-14 Thread Sven Herzing
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi All, I'm quite new to django and try to solve a problem which I found while I'm writing a little webshop with django. I'm sorry if I ask a too simple question, but sadly, I can't see a solution on my own. I have 3 Classes class Company(models.Mo

Re: Broken pipes with HttpResponseRedirect and Firefox / Trouble in paradise

2007-05-14 Thread veged
I have same problem with broken pipe and Firefox 2.0 (on MacOSX). But i have it in very simple project without HttpResponseRedirect. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to t

Re: Template Tag param=Model

2007-05-14 Thread James Bennett
On 5/14/07, Jimmy <[EMAIL PROTECTED]> wrote: > I have a templatetag that basically fetches archive information for a > specific model, the only thing is I cannot figure out how to convert the > model parameter which is passed in as a string to an actual django Model You want the function 'get_mod

Template Tag param=Model

2007-05-14 Thread Jimmy
I have a templatetag that basically fetches archive information for a specific model, the only thing is I cannot figure out how to convert the model parameter which is passed in as a string to an actual django Model class ArchiveNode(template.Node): def __init__(self, model, date_field):

Re: where to "listen" for backwards incompatible changes in trunk?

2007-05-14 Thread Ramiro Morales
On 5/14/07, Bram - Smartelectronix <[EMAIL PROTECTED]> wrote: > > hey guys, > > > just lost a about an hour trying to figure out why some stuff stopped > working when we noticed someone had done an update of django on our test > server :-) > > Anyway, where do I "listen" to backwards incompatible

Re: ManyToManyField and TypeError using lists

2007-05-14 Thread Milan Andric
On May 14, 11:20 am, Milan Andric <[EMAIL PROTECTED]> wrote: > Hello, > > My Tutorial model has an author field, which can contain many authors: > > class Tutorial(models.Model): > ... > author = models.ManyToManyField(User,limit_choices_to = > {'is_staff' :1}) > > When i try to save : >

ManyToManyField and TypeError using lists

2007-05-14 Thread Milan Andric
Hello, My Tutorial model has an author field, which can contain many authors: class Tutorial(models.Model): ... author = models.ManyToManyField(User,limit_choices_to = {'is_staff' :1}) When i try to save : users=[] users.append(User.objects.get(username='joe')) users.append(User.objec

Re: where to "listen" for backwards incompatible changes in trunk?

2007-05-14 Thread Malcolm Tredinnick
On Mon, 2007-05-14 at 20:07 +0200, Bram - Smartelectronix wrote: > hey guys, > > > just lost a about an hour trying to figure out why some stuff stopped > working when we noticed someone had done an update of django on our test > server :-) > > Anyway, where do I "listen" to backwards incompa

Re: FLV Video Uploader in Django

2007-05-14 Thread Matt Dennewitz
how do you apply the patch? dumb question, but ive never applied one before :) thanks, matt On May 14, 2007, at 9:59 AM, badger17 wrote: > > > On May 14, 3:31 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: >> I'm looking to create a tool that will allow users to upload video >> and

Re: loading Template Tags

2007-05-14 Thread Georgi Stanojevski
badger17 напиша: > At the moment I can only get it load tags from the current app, ie the > one in which the template is being rendered, or from > django.templatetags in the django install location. Is there a way to > make it load tags for example from a different app? > > I have written an app

Full history branch unable to retrieve audit trail information

2007-05-14 Thread jeffhg58
Not sure if many people have used the full history branch. But, I can see the ChangeLog information via the admin site. But, when I try and get information via the shell I get ChangeLog is not defined. Is there something I need to import to be able to recognize the ChangeLog table. Thanks, Jeff

Re: where to "listen" for backwards incompatible changes in trunk?

2007-05-14 Thread James Bennett
On 5/14/07, Bram - Smartelectronix <[EMAIL PROTECTED]> wrote: > Anyway, where do I "listen" to backwards incompatible changes? Is there > an RSS feed? Is there a mailinglist (django dev??)? Watch this wiki page: http://code.djangoproject.com/wiki/BackwardsIncompatibleChanges -- "Bureaucrat Con

where to "listen" for backwards incompatible changes in trunk?

2007-05-14 Thread Bram - Smartelectronix
hey guys, just lost a about an hour trying to figure out why some stuff stopped working when we noticed someone had done an update of django on our test server :-) Anyway, where do I "listen" to backwards incompatible changes? Is there an RSS feed? Is there a mailinglist (django dev??)? If

Re: Can't connect to MySQL

2007-05-14 Thread badger17
>File "/usr/lib/python2.3/site-packages/MySQL_python-1.2.2-py2.3- > linux-i686.egg/MySQLdb/connections.py", line 170, in __init__ > _mysql_exceptions.OperationalError: (2003, "Can't connect to MySQL > server on '127.0.0.1' (111)") > > The user and database referenced in settings.py exists in m

loading Template Tags

2007-05-14 Thread badger17
Can someone explain to me how Django decides where to look for Template Tags? At the moment I can only get it load tags from the current app, ie the one in which the template is being rendered, or from django.templatetags in the django install location. Is there a way to make it load tags for exa

Re: problem uploading, foreign key tabular

2007-05-14 Thread Enquest
python 2.5.1rc1 the one from Ubuntu... How do I upgrade in Ubuntu? On zo, 2007-05-13 at 02:08 +1000, Malcolm Tredinnick wrote: > On Sat, 2007-05-12 at 17:55 +0200, Enquest wrote: > > I use python 2.5 > > Are you really using a Python 2.5 final release, or a pre-release of, > say, Python 2.5.1 th

Can't connect to MySQL

2007-05-14 Thread Mark Phillips
I added some classes per the tutorial. Ran python manage.py syncdb Traceback (most recent call last): File "manage.py", line 11, in ? execute_manager(settings) File "/usr/lib/python2.3/site-packages/django/core/management.py", line 1674, in execute_manager execute_from_command_

RE: urls/generic views/dict question.

2007-05-14 Thread Dmitry Shevchenko
I think you can write something like this: (r'^radio/playlist.xml','django.views.generic.list_detail.object_list', dict(dict(queryset=Song.objects.order_by('?')[:30],allow_empty=true), template_name="radio/playlist.xml")) Regards, Dmitry Shevchenko. -Original Message- From: django-users

Re: loaddata and foreignKey: manage.py silently failing

2007-05-14 Thread Sandro Dentella
> Yes, this seems to be the problem. The serializer doesn't currently > handle to_field as a special case. I'll work on a fix. > > However, there is another way to solve you problem. Are you sure that > you want Nation.code to be unique=True, and not primary_key=True? If > you set primary_key=Tru

Python Django Developer required for London based company

2007-05-14 Thread Rakesh Thakrar
Our client base in London is a ambitious, young and innovative shopping and mobile online company. We are now looking for a competent Web based Python developer to work on both the front and back-end. Ideally you will be experienced with Python, HTML, CSS and JavaScript. Any experience of Django, W

Re: Django, PYTHONPATH and Apache

2007-05-14 Thread badger17
I got a reply to this query after mistakenly emailing someone directly: On Mon, 2007-05-14 at 08:05 -0700, badger17 wrote: >> > > You need the second one because I suspect you are leaving off the >> > > "myproject" part of the import path somewhere inside your code. You >> > > could track those d

Re: assertRedirects

2007-05-14 Thread Jiri Barton
Another thing. I don't know if that's legal or not but I'd also need to check the query: self.client.post('/usermanagement/users/create/', { 'firstname': 'Sherlock', 'lastname': 'Holmes', }) redirects to /usermanagement/users/filter/?edit=1 (I use some search fi

Re: Announcing django_xmlrpc

2007-05-14 Thread Graham Binns
No worries, any time. I'm forever making that mistake (unless PyDev catches it for me of course, which is... well, why I use PyDev :)) Cheers, enjoy, Graham On May 14, 4:50 pm, "patrick k." <[EMAIL PROTECTED]> wrote: > that´s it. sorry. > > thanks for the help. > patrick > > Am 14.05.2007 um 17

Re: Announcing django_xmlrpc

2007-05-14 Thread patrick k.
that´s it. sorry. thanks for the help. patrick Am 14.05.2007 um 17:47 schrieb Graham Binns: > > There's a typo in that list, assuming it's a straight copy and paste: > > 'django.django_xmlrpc,' > > Should read: > > 'django.django_xmlrpc', # The comma was placed /before/ the > closing

Re: Announcing django_xmlrpc

2007-05-14 Thread Graham Binns
There's a typo in that list, assuming it's a straight copy and paste: 'django.django_xmlrpc,' Should read: 'django.django_xmlrpc', # The comma was placed /before/ the closing quote instead of after it. If that doesn't fix it, let me know. Cheers, Graham On May 14, 4:39 pm, "patric

Re: Announcing django_xmlrpc

2007-05-14 Thread patrick k.
INSTALLED_APPS = ( 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.sites', 'django.contrib.admin', 'django.django_xmlrpc,' 'django.contrib.flatpages', 'www.movies', 'www.trailer', 'www.stars', '

Re: Announcing django_xmlrpc

2007-05-14 Thread Graham Binns
That's... bizarre. Could you post the INSTALLED_APPS section of your settings.py here for me? Cheers, Graham On May 14, 2:54 pm, "patrick k." <[EMAIL PROTECTED]> wrote: > 1. no error when importing from the shell, if django.django_xmlrpc is > NOT in the installed apps. > 2. not able to launch

Django, PYTHONPATH and Apache

2007-05-14 Thread badger17
Is it 'correct' when installing Django with Apache to set the PythonPath variable to contain both your 'project' directory, ie where your Django apps live, _and_ the path to the actual application itself, it one level down from the 'project' directory? This is not what is done in the tutorial on t

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread Forest Bond
On Mon, May 14, 2007 at 10:21:28AM -0400, Benjamin Slavin wrote: > I'd recommend doing: > def get_passport(self) > > return k.decString(base64.b64decode(self.passport)) Yes, I think I would normally approach this like: class MyModel(Model): passport = CharField(maxlen

Re: FLV Video Uploader in Django

2007-05-14 Thread badger17
On May 14, 3:31 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > I'm looking to create a tool that will allow users to upload video and > metadata. Once they are uploaded, I will transcode them to FLV and FTP > them off to our Flash Communications Server, keeping a record of the > video and it

Re: Random features in sidebar

2007-05-14 Thread Mordy Ovits
On Monday 14 May 2007 10:54 am, Mordy Ovits wrote: > I think it would make more sense to use random.shuffle() And (after checking the python docs because I still think in Python 1.5.2), random.sample() makes even more sense. Mordy --~--~-~--~~~---~--~~ You recei

Re: Random features in sidebar

2007-05-14 Thread Mordy Ovits
On Friday 11 May 2007 07:03 pm, Benjamin Slavin wrote: > I've just uploaded a template filter called "several_random" to the > django snippets site. > http://www.djangosnippets.org/snippets/230/ The way you're picking indices is inefficient: while len(picked_indices) < arg: candidate = random

Re: urls/generic views/dict question.

2007-05-14 Thread [EMAIL PROTECTED]
Sorry I was unclear... I'm currently using the same song_dict for both podcast and playlist.xml, which is 'queryset': Song.objects.all(), That's fine for the podcast. In the template I reverse sort it on pub_date, and it's perfect. But for playlist I want something like: 'queryset': Song.objec

Re: ImportError: No module named mysite.settings

2007-05-14 Thread ilDave
Check the permissions of the directory where your app lives, it has to be readable by the webserver. On May 14, 4:14 pm, Mark Phillips <[EMAIL PROTECTED]> wrote: > On May 14, 2007, at 2:13 AM, Steven Armstrong wrote: > > > > > ... > > PythonPath "['/usr/local'] + sys.path" > >

Re: Using newforms to show a single form for multiple models

2007-05-14 Thread anders conbere
just remember that a form instance is completely unaware of the model. So in your view you'll want to create a form instance for your list and a form instance for a list item (you can either work on the form instances now in the view to provide unique names for each input or in the template later

Re: Random features in sidebar

2007-05-14 Thread Mordy Ovits
On Friday 11 May 2007 06:18 pm, orestis wrote: > Put in a simple, hard coded python list and use random on this ? Straight-up random will create dupes. My current thinking is to have python code creeate a list of 3 from 7 sidebar features and in the template have INCLUDEDs surrounded by IFs.

FLV Video Uploader in Django

2007-05-14 Thread [EMAIL PROTECTED]
I'm looking to create a tool that will allow users to upload video and metadata. Once they are uploaded, I will transcode them to FLV and FTP them off to our Flash Communications Server, keeping a record of the video and its associated data. Once the raw file is on the server, I'll have a shell s

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread Benjamin Slavin
On 5/14/07, Forest Bond <[EMAIL PROTECTED]> wrote: > You mean: > > decrypted_passport = k.decString(base64.b64decode(self.passport)) > self.passport = decrypted_passport > > Right? Yeah... that's the one ;-) Thanks for catching that, Forest. elemental: Looking at this again, I'm still

Re: loaddata and foreignKey: manage.py silently failing

2007-05-14 Thread Russell Keith-Magee
On 5/14/07, Russell Keith-Magee <[EMAIL PROTECTED]> wrote: > On 5/14/07, sandro dentella <[EMAIL PROTECTED]> wrote: > > > > I produced the example (2 field, 2 models, 2 records!) > > I opened ticket http://code.djangoproject.com/ticket/4288 > > but now I cannot add files due to InternalError of t

Re: ImportError: No module named mysite.settings

2007-05-14 Thread Mark Phillips
On May 14, 2007, at 2:13 AM, Steven Armstrong wrote: > > ... > PythonPath "['/usr/local'] + sys.path" > ... > This worked. I also tried using "/usr/local/mysite" which did eliminate the problem finding mysite.settings but raised another one: no module named mysite.urls.

Re: Bug in django related to sqlite3?

2007-05-14 Thread Jonathan Buchanan
> Indeed I have to use the query/cursor mode. The query is a way more > complex than that and I need some ordering based on calculated fields > (which is not supported at the moment from the QuerySet api). I > simplified the query simply to isolate the problem. > some_id is indeed a foreign key to

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread Forest Bond
On Mon, May 14, 2007 at 09:27:46AM -0400, Benjamin Slavin wrote: > Then the decryption would be: > decrypted_passport = k.decString(self.passport) > self.passport = base64.b64decode(decrypted_passport) You mean: decrypted_passport = k.decString(base64.b64decode(self.passport)) s

Re: Announcing django_xmlrpc

2007-05-14 Thread patrick k.
1. no error when importing from the shell, if django.django_xmlrpc is NOT in the installed apps. 2. not able to launch the shell when django.django_xmlrpc IS in the installed apps. I´ve tried to put the package somewhere else but that doesn´t change anything. thanks, patrick Am 14.05.200

Re: Bug in django related to sqlite3?

2007-05-14 Thread cesco
Indeed I have to use the query/cursor mode. The query is a way more complex than that and I need some ordering based on calculated fields (which is not supported at the moment from the QuerySet api). I simplified the query simply to isolate the problem. some_id is indeed a foreign key to another t

Re: Announcing django_xmlrpc

2007-05-14 Thread CodeDragon
Hi Patrick, I can't seem to reproduce this error myself. Could you try importing django.django_xmlrpc through the interactive shell and reproduce the output for me? Also, it might be worth trying to put the django_xmlrpc package somewhere else in your PYTHONPATH rather than under the Django dire

Re: Bug in django related to sqlite3?

2007-05-14 Thread Martin Winkler
Hi Francesco, Am Mon, 14 May 2007 12:44:46 - schrieb cesco <[EMAIL PROTECTED]>: > query = """SELECT id FROM my_table \ > WHERE my_table.some_id IN %s""" > cursor.execute(query, [(1, 2, 3)]) why are you diving so deep? can't you just use myobjects = MyTable.objects.filter(so

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread Benjamin Slavin
Hi elemental, One thing I noticed is that you're doing two base64 encodings (thus the need to decode twice). You have: raw = base64.b64encode(passport) encPassport = k.encString(raw) self.passport = base64.b64encode(encPassport) I'm not familiar with ezPyCrypto, but you might try:

Re: loaddata and foreignKey: manage.py silently failing

2007-05-14 Thread Russell Keith-Magee
On 5/14/07, sandro dentella <[EMAIL PROTECTED]> wrote: > > I produced the example (2 field, 2 models, 2 records!) > I opened ticket http://code.djangoproject.com/ticket/4288 > but now I cannot add files due to InternalError of the trac system! > So I put it here: http://www.e-den.it/misc/fixture_

Bug in django related to sqlite3?

2007-05-14 Thread cesco
I have to execute the following SQL query: query = """SELECT id FROM my_table \ WHERE my_table.some_id IN %s""" cursor.execute(query, [(1, 2, 3)]) and the aim would be to replace the %s with the tuple (1, 2, 3) but I get the following error: Traceback (most recent call last):

Re: Different django versions on same host

2007-05-14 Thread Paul Rudin
orestis <[EMAIL PROTECTED]> writes: > Hello, > > I think this will be easy to do, but I just want to check: > > Is it possible to have different Django versions on the same host, and > point my sites to different versions ? > > I'd like to use bleeding edge for personal stuff (yay for > experimen

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread elemental
Well, seems like I keep answering my own questions, but I'll post what I found here in case it helps anybody else... The solution: def get_passport(self): secret_key = settings.SECRET_KEY k = ezPyCrypto.key() k.importKey(secret_key)

Re: Custom filter/tag and template inheritance

2007-05-14 Thread James Bennett
On 5/14/07, Olivier Guilyardi <[EMAIL PROTECTED]> wrote: > Is this the expected behaviour? Yes; tag libraries don't persist across blocks or into child templates. You can make a particular tag library "global" by using the (undocumented) function django.template.add_to_builtins, however; somewher

Custom filter/tag and template inheritance

2007-05-14 Thread Olivier Guilyardi
Hi, I have a custom filter which I expect to use in many templates. So instead of adding {% load my_lib.py %} into every template I'd like to put it into base.html which all templates extend. But it doesn't work: when I move the load statement to the parent template and access the child template

Re: Different django versions on same host

2007-05-14 Thread Malcolm Tredinnick
On Mon, 2007-05-14 at 11:09 +, orestis wrote: > Hello, > > I think this will be easy to do, but I just want to check: > > Is it possible to have different Django versions on the same host, and > point my sites to different versions ? > > I'd like to use bleeding edge for personal stuff (yay

Re: Different django versions on same host

2007-05-14 Thread Horst Gutmann
orestis wrote: > Hello, > > I think this will be easy to do, but I just want to check: > > Is it possible to have different Django versions on the same host, and > point my sites to different versions ? > > I'd like to use bleeding edge for personal stuff (yay for > experimentation) but for any

Different django versions on same host

2007-05-14 Thread orestis
Hello, I think this will be easy to do, but I just want to check: Is it possible to have different Django versions on the same host, and point my sites to different versions ? I'd like to use bleeding edge for personal stuff (yay for experimentation) but for any work-related material, I want st

Re: Difficulties with thread locals

2007-05-14 Thread orestis
I see. I noticed this was tricky stuff. I guess that setting the SITE_ID each time will lead to race conditions etc, right ? So it's back to the drawing board. Using sites for multilingual content was cool because it allowed me to use the built in functionality of django.contrib very easily...

Re: excel import

2007-05-14 Thread schmidg
Hello! I import Excel files with pyExcelerator http://sourceforge.net/projects/pyexcelerator It works well with multiple sheets and supports all formats up to office 2003. Yours, Guillaume. On Mon, 2007-05-14 at 06:00 -0400, Todd O'Bryan wrote: > Check out Xlrd. It will import Excel files and

Re: excel import

2007-05-14 Thread Todd O'Bryan
Check out Xlrd. It will import Excel files and change them into a list of lists. http://cheeseshop.python.org/pypi/xlrd/0.5.2 Todd On Mon, 2007-05-14 at 11:25 +0200, Aidas Bendoraitis wrote: > Hello, Dmitry! > > You could save the excel sheet as comma separated values and then read > and parse

IT really works!!!

2007-05-14 Thread Forrest
Good Day! This article I?ve written is all about the fact where I earned an ASTOUNDING amount of money in less than a month and I?ve decided to share the secret with you?(yah you the one reading this message) behind making big bucks in the Mail Order Business. So all money seekers?Read this caref

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread elemental
Hi Malcom, I was unaware of sys.stderr.write, very handy--thanks (obviously, I'm still working my way through python/django). I'm indeed on the development server, and using sys.stderr.write, I can conclude that: - the key is being imported from the settings file - self.passport contains the en

Re: Help with limit_choices_to

2007-05-14 Thread xgdlm
Hello Thank you Malcolm for your fast answer (as usual) > However, you > cannot pass parameters to that function: it's mostly for use with things > like datetime.datetime.now -- where the result of the function does not > depend on "self" in any fashion. Hum, that what I understood, but now I

Re: excel import

2007-05-14 Thread Aidas Bendoraitis
Hello, Dmitry! You could save the excel sheet as comma separated values and then read and parse them line-by-line using python. For each category (which is one of the columns) you can get_or_create a category record in the database and assign that as a foreign key or many to many relationship to

Re: Multiple Profiles

2007-05-14 Thread Bram - Smartelectronix
Amit Upadhyay wrote: > On 5/9/07, *Vinay Sajip* <[EMAIL PROTECTED] > > wrote: > > One simple problem with Amit's approach, as written, is that you have > to deal with "fuser" and "duser", which feels a little kludgy (I > realise he was just demonstrating the

Re: ImportError: No module named mysite.settings

2007-05-14 Thread Malcolm Tredinnick
On Mon, 2007-05-14 at 02:07 -0700, Mark Phillips wrote: > Decided to try a clean slate. Set up Django on SME Server 7.1, which > is based on Centos 4. > Compiled and installed mod_python > Amended httpd.conf as follows: > > LoadModule python_module modules/mod_python.so > > and later on in the

Re: ImportError: No module named mysite.settings

2007-05-14 Thread Steven Armstrong
Mark Phillips wrote on 05/14/07 11:07: > Decided to try a clean slate. Set up Django on SME Server 7.1, which > is based on Centos 4. > Compiled and installed mod_python > Amended httpd.conf as follows: > > LoadModule python_module modules/mod_python.so > > and later on in the file... > >

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread Malcolm Tredinnick
On Mon, 2007-05-14 at 08:59 +, elemental wrote: > Update... > > I think I've fixed the insert issue. The updated model is here: > > http://dpaste.com/10264/ > > Now, I just can't get the passport back out of the database :-) > > I put together a quick view/template, and the passport is bei

ImportError: No module named mysite.settings

2007-05-14 Thread Mark Phillips
Decided to try a clean slate. Set up Django on SME Server 7.1, which is based on Centos 4. Compiled and installed mod_python Amended httpd.conf as follows: LoadModule python_module modules/mod_python.so and later on in the file... SetHandler python-program PythonPath "['/usr/local/m

Re: Help with limit_choices_to

2007-05-14 Thread Malcolm Tredinnick
On Mon, 2007-05-14 at 08:45 +, xgdlm wrote: > Hello all ! > > I have trouble using limit_choices_to on the following modele. I > searched the group and googled but I couldn't find the solution. > > Here is my modeles : > - > cla

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread elemental
Update... I think I've fixed the insert issue. The updated model is here: http://dpaste.com/10264/ Now, I just can't get the passport back out of the database :-) I put together a quick view/template, and the passport is being returned as an empty string, with no errors. The relavent part of

Help with limit_choices_to

2007-05-14 Thread xgdlm
Hello all ! I have trouble using limit_choices_to on the following modele. I searched the group and googled but I couldn't find the solution. Here is my modeles : - class Member(models.Model): login = models.CharField(maxlen

Re: Announcing django_xmlrpc

2007-05-14 Thread patrick k.
thanks for the code, graham. I tried to install django_xmlrpc as described on the google-site. I did the checkout to my django-directory and added django.django_xmlrpc to the installed apps. when I start the dev-server I get the following error-message: AttributeError: 'module' object has no at

Re: ordinal not in range(128) + ezPyCrypto

2007-05-14 Thread elemental
Ben, thanks a lot, some good info here. The Satchmo project is a great reference--I hadn't seen it before. I've followed most of your suggestions, and am getting closer but still not there. For reference, I've posted both my view[0] and my model[1]. The base64 bit seems to have eliminated the ori