Transactions not working

2009-01-14 Thread thomasbecht...@googlemail.com
Hi all, Problem: I want to use Transaction to save data to a postgresql-db. Error: IntegrityError: doppelter Schlüsselwert (double keyvalue) verletzt (harm) Unique-Constraint »measurements_loggerdata_logger_id_key« My Model looks like this: class LoggerData(models.Model): logger = models.Fore

Re: Want to test a file-upload with django.test.client

2009-01-09 Thread thomasbecht...@googlemail.com
I forgot the output for request.FILES. it's: CRITICAL request.FILES: On 9 Jan., 17:21, "thomasbecht...@googlemail.com" wrote: > Hi all, > > i have to replace a php-script with a django-view. The django-view > just get some Post-Data and a file. The view works fin

Want to test a file-upload with django.test.client

2009-01-09 Thread thomasbecht...@googlemail.com
Hi all, i have to replace a php-script with a django-view. The django-view just get some Post-Data and a file. The view works fine. Now, i want to write a test for the upload. My Script looks like this: from django.test.client import Client from django.test import client c = Client() file = ope