Re: PROBLEM

2018-12-05 Thread Carlton Gibson
Hi David, This group is for "Contributions to Django itself". You need to head over to Django Users for support questions. (But it looks like you didn't save your urls.py — the `polls/` route isn't shown as being searched.) Good luck!

Re: Problem in makemigration

2018-03-20 Thread utpalbrahma1995
sorry sir. -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-developers+unsubscr...@googlegroups.com. To post to this

Re: Problem in makemigration

2018-03-20 Thread Adam Johnson
This mailing list is for the development of Django itself, not for support. Use the django-users mailing list for that, or IRC #django on freenode, or a site like Stack Overflow. On 20 March 2018 at 13:26, wrote: > Django is unable to detect new changes i have made in my models.py.I even > delet

Re: Problem with running tests with mysql database.

2017-03-11 Thread Josh Smeaton
If you're having issues with specific environments and configuring all of the dependencies, you can try using https://github.com/django/django-box which is a Vagrant virtual machine running on Virtualbox. It has postgres, mysql, sqlite, and all of the pythons Django uses for testing. You could

Re: Problem with running tests with mysql database.

2017-03-11 Thread Adam Johnson
For the lock wait timeout errors, it's probable something (another test run?) is still connected to the database and holding the locks. Try restarting mysql. And if you are still having problems, knowing the version of MySQL you're using, plus how you installed it, would be helpful. On 10 March 2

Re: Problem with running tests with mysql database.

2017-03-10 Thread Tim Graham
For the error, "Database returned an invalid datetime value. Are time zone definitions for your database installed?", see https://docs.djangoproject.com/en/dev/ref/databases/#time-zone-definitions. Adding this to the 'default' and 'other' dictionaries in DATABASES may solve some of the encoding

Re: Problem UnicodeDecodeError when run createsuperuser

2017-02-05 Thread Florian Apolloner
Please show the output of the locale command and your full settings. On Saturday, February 4, 2017 at 10:58:28 PM UTC+1, Lucas Simon Rodrigues Magalhaes wrote: > > Hello everyone, > > I have a problem when run createsuperuser.py command in python 3.4. How > can I solve it definitely? > > Look th

Re: Problem UnicodeDecodeError when run createsuperuser

2017-02-05 Thread Bhanu jamwal
or see indentation error On Sunday, February 5, 2017 at 3:28:28 AM UTC+5:30, Lucas Simon Rodrigues Magalhaes wrote: > > Hello everyone, > > I have a problem when run createsuperuser.py command in python 3.4. How > can I solve it definitely? > > Look the code: > > https://gist.github.com/lucassi

Re: Problem with caching template loader

2016-07-07 Thread Preston Timmons
Yep, that looks wrong. Looks like it was added in this commit: https://github.com/django/django/commit/f33db5a09acfc3df3085235a5712c46094eb9a0d The test case could be improved also by checking the appropriate key is set. Preston -- You received this message because you are subscribed to the Go

Re: Problem with profile picture and mysql. URGENT !!

2014-08-08 Thread Tim Graham
This mailing list is for the development of Django. Please direct questions about how to use Django to the django-users mailing list. On Friday, August 8, 2014 12:41:52 AM UTC-4, Swathi Rajanna wrote: > > My app does not use South as it keeps giving me django.core.management > Improperly Configu

Re: Problem migrating from South to Django migrations for Linux distributions

2014-07-25 Thread Raphael Hertzog
Hi Brian, On Fri, 25 Jul 2014, Brian May wrote: > I can't help but think this might be unrealistic (?). Changes required for > new versions of Django often break compatibility with old versions, and > 1.4.5 is really old now. Just because many packages don't have versioned > dependencies on Django

Re: Problem migrating from South to Django migrations for Linux distributions

2014-07-25 Thread Raphael Hertzog
Hi Andrew, thanks for your quick answer. On Thu, 24 Jul 2014, Andrew Godwin wrote: > There is no way around this; it's unfortunate that the packaging situation > means that Django will get auto-upgraded as part of a distribution upgrade; > I'm surprised that Debian hasn't had this with packages

Re: Problem migrating from South to Django migrations for Linux distributions

2014-07-24 Thread Andrew Godwin
So, South migrations will not work with Django 1.7. Period. There is no way around this; it's unfortunate that the packaging situation means that Django will get auto-upgraded as part of a distribution upgrade; I'm surprised that Debian hasn't had this with packages before? (Version upgrades that

Re: Problem migrating from South to Django migrations for Linux distributions

2014-07-24 Thread Michael Manfre
On Thu, Jul 24, 2014 at 4:44 PM, Joseph Curtin <4...@jbcurtin.io> wrote: > > My question now would be, can django migrations and south migrations > co-exist and can I turn off django migrations? > No, migrations is a required feature of Django and cannot be turned off. The best you could do is gene

Re: Problem migrating from South to Django migrations for Linux distributions

2014-07-24 Thread Joseph Curtin
Normally, in development with south. If the migrations get to the point were they're out of sync. The lead Dev removed the conflicting migrations and runs the schema migration command. As for the django 1.7 flow of migrations, I cannot comment on it, but I would go into this problem with the assum

Re: Problem in doing Calcultion in django Application

2014-06-18 Thread Daniele Procida
On Wed, Jun 18, 2014, Muskan arora wrote: >I have a problem in calculating Sum. > my models.py is as follows :- You'll get answers to your questions on the django-users email list, - the web interface is . The list you've posted to is dj

Re: problem with testing for DeprecationWarning

2014-03-01 Thread Aymeric Augustin
On 1 mars 2014, at 10:51, Erik Romijn wrote: > Curiously, when I run this test independently, or when I run utils_tests > independently, this test succeeds. Perhaps there is some interaction with > other tests in the suite? If that's the problem, ./runtests.py --bisect utils_tests should tell

Re: Problem with number format when not using L10N

2013-12-20 Thread Yonel Ceruto González
In conclusion one could say that if USE_L10N is not True then no thousands separator is displayed, of course, only thru the configuration of django. El viernes, 20 de diciembre de 2013 08:15:58 UTC-5, Yonel Ceruto González escribió: > > Ok no problem, > > Although the documentation may be incons

Re: Problem with number format when not using L10N

2013-12-20 Thread Yonel Ceruto González
Ok no problem, Although the documentation may be inconsistent, I think the comment https://code.djangoproject.com/ticket/21544 # comment: 8, discloses a particular case where I customize the THOUSAND_SEPARATOR with USE_L10N = False. This is the source of my problem, because he expects to see

Re: Problem with number format when not using L10N

2013-12-19 Thread Curtis Maloney
I recall helping someone on #django with something similar to this, where the documentation, logical expectations and actual code went in rather different directions. There was a condition where despite the setting being observed at one layer, a lower layer then went and ignored it anyway... will

Re: Problem with number format when not using L10N

2013-12-19 Thread Shai Berger
Hi, On Thursday 19 December 2013 05:25:11 Yonel Ceruto González wrote: > Forgive me if at some point was arrogant, it was not my intention to impose > my judgment or criticize, for me, the best framework that exists. Maybe I > was not regarded with good intentions and therefore I believe the answe

Re: Problem with number format when not using L10N

2013-12-19 Thread Yonel Ceruto González
Forgive me if at some point was arrogant, it was not my intention to impose my judgment or criticize, for me, the best framework that exists. Maybe I was not regarded with good intentions and therefore I believe the answers were focused to dodge my proposal.Most likely I knew not express well, b

Re: Problem with number format when not using L10N

2013-12-03 Thread Yonel Ceruto González
It is understood that if I have enabled the thousands separator USE_THOUSAND_SEPARATOR = True and NUMBER_GROUPING > 0 to display all numbers with the pattern: #THOUSAND_SEPARATOR###DECIMAL_SEPARATOR## If is enabled or not USE_L10N only determines the "values" of DECIMAL_SEPARATOR and THOUS

Re: Problem with number format when not using L10N

2013-12-03 Thread Claude Paroz
This is the topic of https://code.djangoproject.com/ticket/21544 where you can read my position. -- You received this message because you are subscribed to the Google Groups "Django developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-dev

Re: Problem with number format when not using L10N

2013-12-03 Thread Yonel Ceruto González
I think the configuration of the variable USE_L10N aims at in this case, determine the format of number and not condition the use of the grouping of thousands. -- You received this message because you are subscribed to the Google Groups "Django developers" group. To unsubscribe from this group

Re: Problem with number format when not using L10N

2013-12-03 Thread Yonel Ceruto González
Rectify the frontline: I want to use the grouping of thousands in my numeric formats, for which I use the "floatformat" filter. El martes, 3 de diciembre de 2013 08:13:21 UTC-5, Yonel Ceruto González escribió: > > Deseo usar la agrupación de millares en mis formatos numéricos, for which > I

Re: Problem with creating a one-to-one instance

2013-04-19 Thread Carsten Fuchs
Hi Jacob, hi Florian, Am 19.04.2013 18:18, schrieb Jacob Kaplan-Moss: Unfortunately, we can't help you. Django-developers isn't a "second level" for django-users; they're completely different lists. The purpose of this list is to discuss the development of Django itself, not answer user question

Re: Problem with creating a one-to-one instance

2013-04-19 Thread Florian Apolloner
Hi Carsten, first of all, django-dev is not a second level support list, so for the future please refrain from posting here just because you get no answer on the user list. As for the issue on hand, try accessing ma.vbp_id after you assign the instance, this should give you some clues. Cheers,

Re: Problem with creating a one-to-one instance

2013-04-19 Thread Jacob Kaplan-Moss
Hi Carsten - On Fri, Apr 19, 2013 at 10:43 AM, Carsten Fuchs wrote: > sorry to bother you here, but I posted to django-users first > (https://groups.google.com/d/msg/django-users/WHnCxHkEVjE/9puR4youvwsJ) and > there was no reply, so please let me re-try here: Unfortunately, we can't help you. D

Re: PROBLEM WITH MY CUSTOMIZED save() method

2013-02-16 Thread Karen Tracey
Please ask questions about using Django on django-users. This list is for the discussion of developing Django itself. Thanks, Karen -- You received this message because you are subscribed to the Google Groups "Django developers" group. To unsubscribe from this group and stop receiving emails fr

Re: Problem with Custom Manage.py command and Crontab

2013-02-06 Thread Karen Tracey
Please ask questions about using Django on django-users. The topic of this list is the development of Django itself. Thanks, Karen -- You received this message because you are subscribed to the Google Groups "Django developers" group. To unsubscribe from this group and stop receiving emails fro

Re: Problem with writing custom field to work with inherit models

2011-04-06 Thread Russell Keith-Magee
On Thu, Apr 7, 2011 at 4:21 AM, Sebastian Bauer wrote: > Hi, could you explain to us why this isn't working? > https://github.com/humanfromearth/django-stdimage/issues/11 Not in this forum. You've posted to django-developers, which is a forum for discussing the development of django itself. It l

Re: Problem with DECIMAL_SEPARATOR

2011-03-10 Thread Łukasz Rekucki
On 10 March 2011 21:49, Siara wrote: > Hi > I'm writing application which return json with data for another app. > I'm from Poland so I set LANGUAGE_CODE = 'pl', the problem is that we > are using coma instead of dot in float numbers, and setting language > to polish changing dot for coma in jsons

Re: Problem due to contenttype cache

2011-03-07 Thread Rahul
Hi carl, I have file a ticket for this. For details please find it on http://code.djangoproject.com/ticket/15568 Thanks, Rahul Priyadarshi On Mar 5, 9:27 am, Carl Meyer wrote: > On Mar 4, 5:55 am, Rahul wrote: > > > > > When i ran test cases of multiple_databases model of regressiontests > > t

Re: Problem due to contenttype cache

2011-03-04 Thread Carl Meyer
On Mar 4, 5:55 am, Rahul wrote: > When i ran test cases of multiple_databases model of regressiontests > then "test_generic_key_deletion" test case gave Error at the point > where it was trying to create Review object using "other" db, > but when i ran "test_generic_key_deletion" test case only

Re: Problem with ``Model.objects.create``

2011-01-08 Thread Dan Watson
On Wednesday, January 5, 2011 3:30:42 AM UTC-5, Valts wrote: > > Just my $0.02: I think that such feature would be useful when using > get_or_create() when I don't want the object to be saved into the > database if it does not validate. There could be added another special > keyword argument "fu

Re: Problem with ``Model.objects.create``

2011-01-05 Thread Valts
On Jan 4, 8:46 pm, Waylan Limberg wrote: > That being said, it does strike me as being a little odd that there is > no way to validate your data when using create() or get_or_create(). > In fact, the docs [1] describe both those methods as shortcuts. But if > you're writing an app that always need

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Yo-Yo Ma
On Jan 4, 4:43 pm, Jacob Kaplan-Moss wrote: > On Tue, Jan 4, 2011 at 3:37 PM, Yo-Yo Ma wrote: > > What's with all the hostility here? I've heard about this from others. > > Let's just stop this, right now. There's no hostility in Marty's tone > -- if you're reading that, then take the night off a

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Jacob Kaplan-Moss
On Tue, Jan 4, 2011 at 3:37 PM, Yo-Yo Ma wrote: > What's with all the hostility here? I've heard about this from others. Let's just stop this, right now. There's no hostility in Marty's tone -- if you're reading that, then take the night off and come back to django-dev tomorrow. This discussion

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Yo-Yo Ma
Waylan: > Therefore, don't use Person.objects.create() Marty: > Developer mistakes can ruin your data. Full stop. > Unfortunately, this is one of the many issues where "X doesn't work > the way I think it should" gets confused with "X doesn't work the way > it should" or even "X doesn't work.

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Marty Alchin
On Tue, Jan 4, 2011 at 3:10 PM, Yo-Yo Ma wrote: > Simple question (A or B): Would you rather A) have a > SomeDjangoException come up where you don't expect it and a visitor > see a 500 page, or B) have your data ruined by a developer mistake? Developer mistakes can ruin your data. Full stop. Tha

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Yo-Yo Ma
>> ...*before* writing to the db. Therefore, don't use >> Person.objects.create() >> ...it does strike me as being a little odd that there is no way to validate >> your data... Let me get this straight: I just shouldn't "use Person.objects.create()", if I ever want to to take advantage

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Waylan Limberg
On Tue, Jan 4, 2011 at 10:54 AM, Yo-Yo Ma wrote: [snip] > The difference in Django is that instantiation doesn't represent > "creation". Saving to the database does, and since the ORM is an > abstraction of the database, you don't care that the DB is ok with an > empty VARCHAR value. You only care

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Yo-Yo Ma
> duplicate key, etc." [1] Since the creation of a model instance > doesn't affect the database, it should definitely not raise an This isn't correct. Model instantiation doesn't affect the database. Model creation (ie, the use of ``Model.create()`` does. I'm not arguing that instantiation should

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Stephen Burrows
Just to clarify, an IntegrityError is raised if "the relational integrity of the database is affected, e.g. a foreign key check fails, duplicate key, etc." [1] Since the creation of a model instance doesn't affect the database, it should definitely not raise an IntegrityError. Additionally, blank=T

Re: Problem with validating ModelForm

2011-01-03 Thread Robert W?glarek
Oh, sorry. -- You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-develop...@googlegroups.com. To unsubscribe from this group, send email to django-developers+unsubscr...@googlegroups.com. For more opti

Re: Problem with validating ModelForm

2011-01-03 Thread Shawn Milochik
Please post your question to the django-users mailing list. This list is for developers of Django itself. -- You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-develop...@googlegroups.com. To unsubscr

Re: Problem with ``Model.objects.create``

2011-01-03 Thread Yo-Yo Ma
Oh, sorry for the confusion, and thanks for the explaination. I thought that Django raised an IntegrityError in this case, and when it didn't happen I figured it was a bug. I will make a recommendation (observation). To provide a blank value a a model and have it validate with full_clean, you have

Re: Problem with ``Model.objects.create``

2011-01-02 Thread Russell Keith-Magee
On Mon, Jan 3, 2011 at 7:46 AM, Yo-Yo Ma wrote: > I apologize ahead of time, if this bug is rather a user error. > > If you have a model: > > class Foo(Model): >    spam= CharField(max_length=30) >    xyz= CharField(max_length=30) > >    def __unicode__(self): >        return self.xyz > > and you

Re: Problem with ``Model.objects.create``

2011-01-02 Thread nasp
This is a user error, validation checks are performed on model.clean() . This mailing list is for development purpose, please use django-usersmailing list or #django irc . --

Re: problem to run server

2010-12-14 Thread NavaTux
python manage.py syncdb also shows this error only.import django in python shell works; i am using postgres every thing is fine it seems in postgres. -- You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to djan

Re: problem to run server

2010-12-14 Thread Łukasz Rekucki
Hi, This list for developing Django itself, not developing with Django. Please move this discussion to django-users. Thanks. --- Łukasz Rekucki On 14 December 2010 13:55, Tonton wrote: > i presume that in your file you have write > > from django*... import  .  is there the trouble

Re: problem to run server

2010-12-14 Thread Tonton
i presume that in your file you have write from django*... import . is there the trouble .. may be in your settings with database does your manage.py syncdb has work ? On Tue, Dec 14, 2010 at 8:16 AM, NavaTux wrote: > I want to test django application so when i created the project > "dja

Re: Problem with randrange in django/middleware/csrf.py

2010-07-09 Thread DanEE
After all it was a misconfiguration of my system and not a problem of Python or Django. Somehow the special files /dev/random and /dev/urandom got screwed up. I suppose it was the outcome of a bad update of the udev package on my Archlinux system. When I recreated the node of /dev/urandom manually

Re: Problem with randrange in django/middleware/csrf.py

2010-07-08 Thread Ramiro Morales
On Thu, Jul 8, 2010 at 4:09 PM, DanEE wrote: > The problems with randrange also occur when I run it directly from a > normal python prompt. > >[...] > So it doesn't seem to be a django problem, but it still is very > annoying. > >> If the host has not enough entropy, Django shouldn't fix it, an >>

Re: Problem with randrange in django/middleware/csrf.py

2010-07-08 Thread DanEE
The problems with randrange also occur when I run it directly from a normal python prompt. >>> random.randrange(0, 2<<63) instantly returns me the random numbers. whereas >>> random.SystemRandom().randrange(0, 2<<63) Takes forever to run. I cancelled the execution after about 10 minutes. As an i

Re: Problem with randrange in django/middleware/csrf.py

2010-07-08 Thread stefanw
> >> By playing around in a python session it seems that the call to the > >> system randrange with random.SystemRandom().randrange(0, > >> _MAX_CSRF_KEY) never stops (or doesn't seem to stop in less than 30 > >> minutes) whereas a call to the "normal" randrange with randrange(0, > >> _MAX_CSRF_KE

Re: Problem with randrange in django/middleware/csrf.py

2010-07-08 Thread Alex Gaynor
On Thu, Jul 8, 2010 at 8:39 AM, Russell Keith-Magee wrote: > On Thu, Jul 8, 2010 at 3:17 PM, DanEE wrote: >> Hello >> >> I posted this already in django-user. But because it is rather an >> internal django/python problem I will repost it here >> >> I experienced a strange behaviour with my django

Re: Problem with randrange in django/middleware/csrf.py

2010-07-08 Thread Russell Keith-Magee
On Thu, Jul 8, 2010 at 3:17 PM, DanEE wrote: > Hello > > I posted this already in django-user. But because it is rather an > internal django/python problem I will repost it here > > I experienced a strange behaviour with my django application when I > wanted to deploy and test on my apache instanc

Re: problem in modeladmin response_action

2010-03-01 Thread Karen Tracey
On Mon, Mar 1, 2010 at 9:47 AM, Luca Sbardella wrote: > Hi there, > > I just switch from 1.2 beta 1 to svn version and the > ModelAdmin.response_action is not working as before Yes, this has been reported at least twice in the tracker (see http://code.djangoproject.com/ticket/12962) and at least

Re: problem with spatial data in sqlite

2010-01-31 Thread Vladimir Sidorenko
Hi You have to reinstall pysqlite2 with specific flag: http://geodjango.org/docs/install.html#pysqlite2 31 янв. 2010, в 09:48, Alexis Selves написал(а): > Hello, > I have serious problem with my geodjango and spatial data in DB. I > create my models and then I want to sync my db and it doesn't

Re: problem with spatial data in sqlite

2010-01-31 Thread Karen Tracey
Please post questions about using Django to django-users. django-developers is for discussion of developing Django itself. Karen -- You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-develop...@google

Re: Problem with history view in admin page

2010-01-07 Thread Mario Briggs
> > I'm not sure what you're asking me. "Blockers" of what? > I meant, for sure we know that the backend can switch the lookup to the hidden column (from the original column) by overriding - 'field_cast_sql(self, db_type):' The backend also needs to execute the SQL to create the hidden column du

Re: Problem with history view in admin page

2010-01-06 Thread Russell Keith-Magee
On Thu, Jan 7, 2010 at 2:02 PM, Mario Briggs wrote: > Russ, > > The indexing that Oracle is supporting is 'index-on-expression'. DB2 > also supports that, but it isnt enabled for character long columns, > since they hadnt had a request for that. I talked to the DB2 server > folks about these use-c

Re: Problem with history view in admin page

2010-01-06 Thread Mario Briggs
Russ, The indexing that Oracle is supporting is 'index-on-expression'. DB2 also supports that, but it isnt enabled for character long columns, since they hadnt had a request for that. I talked to the DB2 server folks about these use-cases and they have agreed to support this via index-on-expressio

Re: Problem with history view in admin page

2009-12-10 Thread Mario Briggs
> The *only* reason that we are even talking about adding this field is > because DB2 can't index on the datatype that is the natural match for > a length-unlimited TextField. > Oracle's indexing imposes an > implicit limit of 4000 characters; that sounds to me like as good a > number as any. Rus

Re: Problem with history view in admin page

2009-12-09 Thread Russell Keith-Magee
On Wed, Dec 9, 2009 at 8:17 PM, Mario Briggs wrote: > I was too harsh on the GenericKeyField. How about GenericKeyField > (length=x). I think the reason i put length in there is obvious, but i > can explain if need be. Well, you may have to, because the reason that it doesn't need a length is als

Re: Problem with history view in admin page

2009-12-09 Thread Mario Briggs
I was too harsh on the GenericKeyField. How about GenericKeyField (length=x). I think the reason i put length in there is obvious, but i can explain if need be. In post #14 on this thread you suggested - " I'm not wild about the idea of having underlying datatypes change based on attributes in a f

Re: Problem with history view in admin page

2009-12-03 Thread Russell Keith-Magee
On Thu, Dec 3, 2009 at 12:59 PM, Mario Briggs wrote: > Russ, > > I dont agree to the *it works* theory here - Ian rightly said 'If you > ask me, > anybody foolish enough to use a TextField as a primary key deserves > what they get' and you agreed  'Your comment about foolishness is > definitely co

Re: Problem with history view in admin page

2009-12-02 Thread Mario Briggs
Russ, I dont agree to the *it works* theory here - Ian rightly said 'If you ask me, anybody foolish enough to use a TextField as a primary key deserves what they get' and you agreed 'Your comment about foolishness is definitely correct ' Putting it in context, this is in the 'user control area'

Re: Problem with history view in admin page

2009-11-28 Thread Russell Keith-Magee
On Fri, Nov 27, 2009 at 3:22 PM, Yuri Baburov wrote: > Hi Russell, > > On Thu, Nov 26, 2009 at 1:47 PM, Russell Keith-Magee > wrote: >> On Wed, Nov 25, 2009 at 4:24 PM, Yuri Baburov wrote: >>> Hi Russell, >>> >>> is it possible to introduce some new field type >>> ShortTextField for that purpose

Re: Problem with history view in admin page

2009-11-27 Thread Russell Keith-Magee
On Fri, Nov 27, 2009 at 4:21 PM, Mario Briggs wrote: > Russ, > >> With a different coat of paint, it might be more palatable. A name >> like ShortTextField presupposes the storage implementation, but tells >> you nothing about the appropriate usage. However, a different name - >> something like Ge

Re: Problem with history view in admin page

2009-11-27 Thread Mario Briggs
Richard, > I don't know why a user should have .filter(object_id='1') > fail, as that breaks the ORM abstraction. Maybe that's not what you're > suggesting? I am saying exactly what i am saying. So here's my example that does the same thing in a java ORM // Here's the model @Entity public class

Re: Problem with history view in admin page

2009-11-26 Thread Yuri Baburov
Hi Russell, On Thu, Nov 26, 2009 at 1:47 PM, Russell Keith-Magee wrote: > On Wed, Nov 25, 2009 at 4:24 PM, Yuri Baburov wrote: >> Hi Russell, >> >> is it possible to introduce some new field type >> ShortTextField for that purpose, that will be by default >> `varchar(4000)` on Oracle and DB2 who

Re: Problem with history view in admin page

2009-11-25 Thread Russell Keith-Magee
On Wed, Nov 25, 2009 at 4:24 PM, Yuri Baburov wrote: > Hi Russell, > > is it possible to introduce some new field type > ShortTextField for that purpose, that will be by default > `varchar(4000)` on Oracle and DB2 who supports long varchars, and > `text` on other backends like it was before, excep

Re: Problem with history view in admin page

2009-11-25 Thread Yuri Baburov
Hi Russell, is it possible to introduce some new field type ShortTextField for that purpose, that will be by default `varchar(4000)` on Oracle and DB2 who supports long varchars, and `text` on other backends like it was before, excepting 'smalltext' instead of 'longtext' for mysql? I think this is

Re: Problem with history view in admin page

2009-11-24 Thread Richard Laager
On Tue, 2009-11-24 at 20:54 -0800, Mario Briggs wrote: > Instead we will let users run into errors when they do a '=' compare > of a Django Text type, and then let them ponder whether they need that > column as a CLOB in the backend. Shouldn't something be changing that = into a LIKE (and escaping

Re: Problem with history view in admin page

2009-11-24 Thread Mario Briggs
Russell, > >> Well, Django doesn't make the decision to use CLOB - that's in the > >> hands of your backend. In the same circumstances, SQLite and Postgres > >> use 'text'. MySQL uses 'longtext'. Oracle uses 'NCLOB' I understand that the decision to what 'Text' should be mapped to is the choice o

Re: Problem with history view in admin page

2009-11-24 Thread Karen Tracey
On Tue, Nov 24, 2009 at 7:09 PM, Russell Keith-Magee wrote: > This is a slightly moot point, though; Django defines the admin log > object_id using a TextField, and changing this would be a big > backwards incompatibility. > > Also I believe there's at least one other place in Django that does si

Re: Problem with history view in admin page

2009-11-24 Thread Russell Keith-Magee
On Wed, Nov 25, 2009 at 1:25 AM, Ian Kelly wrote: > On Mon, Nov 23, 2009 at 11:00 PM, Russell Keith-Magee > wrote: >> On Tue, Nov 24, 2009 at 1:07 PM, Mario Briggs >> wrote: >>> I agree that INTEGER is not the right choice, but then so too is CLOB. >>> How long is this string-serialized represe

Re: Problem with history view in admin page

2009-11-24 Thread Ian Kelly
On Mon, Nov 23, 2009 at 11:00 PM, Russell Keith-Magee wrote: > On Tue, Nov 24, 2009 at 1:07 PM, Mario Briggs wrote: >> I agree that INTEGER is not the right choice, but then so too is CLOB. >> How long is this string-serialized representation going to be? greater >> than 4000 characters ? Varchar

Re: Problem with history view in admin page

2009-11-23 Thread Russell Keith-Magee
On Tue, Nov 24, 2009 at 1:07 PM, Mario Briggs wrote: >>> > What is stored in this field is a string-serialized representation of > the > primary key value. > << > > I agree that INTEGER is not the right choice, but then so too is CLOB. > How long is this string-serialized representation going to b

Re: Problem with history view in admin page

2009-11-23 Thread Mario Briggs
>> What is stored in this field is a string-serialized representation of the primary key value. << I agree that INTEGER is not the right choice, but then so too is CLOB. How long is this string-serialized representation going to be? greater than 4000 characters ? Varchar(X) where X is > 4000 or s

Re: Problem with history view in admin page

2009-11-23 Thread Karen Tracey
Note Oracle had the same problem: http://code.djangoproject.com/ticket/5087 I can't actually read Oracle but I think the fix involves adding a cast that extracts the first 4000 chars of data from the field for comparison. They override the field_cast_sql method in the Oracle DatabaseOperations t

Re: Problem with history view in admin page

2009-11-23 Thread Russell Keith-Magee
On Mon, Nov 23, 2009 at 9:12 PM, Rahul wrote: > Hi All, > > There is a problem reported for history view in admin page. > For history view there is a sql query generated, which trying to do > exact look-up on OBJECT_ID column (LogEntry model, DJANGO_ADMIN_LOG > table). > > "TextField" is responsib

Re: Problem with admin after moving to another machine

2009-07-07 Thread diogobaeder
Russ: yes, I must be out of my mind. Yes, I will post in the other group. Sorry for this unbrained programmer... I'll try to drink less Coca- Cola and see if my attention comes back... :-P Thanks! And congrats for the great support! :-) Diogo On Jul 7, 11:58 pm, Russell Keith-Magee wrote: >

Re: Problem with admin after moving to another machine

2009-07-07 Thread Russell Keith-Magee
On Wed, Jul 8, 2009 at 10:16 AM, Diogo Baeder wrote: > > Hi there, > > I started to have this error: > http://dpaste.com/64355/ > while trying to access my admin site, after I moved my website from one > machine (my desktop) to the other (my laptop). I already restored my > PostgreSQL database, an

Re: problem django admin

2009-01-20 Thread Russell Keith-Magee
On Wed, Jan 21, 2009 at 12:14 PM, Karen Tracey wrote: > On Tue, Jan 20, 2009 at 10:08 PM, Harryanto Ie > wrote: >> >> [snip] >> >> File >> "c:\python25\Lib\site-packages\django\db\backends\sqlite3\base.py", >> line 167, in execute >> return Database.Cursor.execute(self, query, params) >> >>

Re: problem django admin

2009-01-20 Thread Karen Tracey
On Tue, Jan 20, 2009 at 10:08 PM, Harryanto Ie wrote: > [snip] File > "c:\python25\Lib\site-packages\django\db\backends\sqlite3\base.py", > line 167, in execute > return Database.Cursor.execute(self, query, params) > > OperationalError: no such table: django_session > > i've put django.contri

Re: Problem with ORM

2009-01-17 Thread Malcolm Tredinnick
On Fri, 2009-01-16 at 00:38 +0100, Sebastian Bauer wrote: > I think ORM supposed to have save insert and update: > > save(force_insert=False,force_update=False) > update() == save(force_update=True) > insert() == save(force_insert=True) There was a long discussion a couple of years ago about whe

Re: Problem with ORM

2009-01-16 Thread Sebastian Bauer
W dniu 16.01.2009 16:34, varikin pisze: > > On Jan 15, 5:38 pm, Sebastian Bauer wrote: > >> I think ORM supposed to have save insert and update: >> >> save(force_insert=False,force_update=False) >> update() == save(force_update=True) >> insert() == save(force_insert=True) >> >> in that situati

Re: Problem with ORM

2009-01-16 Thread varikin
On Jan 15, 5:38 pm, Sebastian Bauer wrote: > I think ORM supposed to have save insert and update: > > save(force_insert=False,force_update=False) > update() == save(force_update=True) > insert() == save(force_insert=True) > > in that situation we could have clean code and we know that update is

Re: Problem with ORM

2009-01-15 Thread Jacob Kaplan-Moss
> Because I deleted that object. Delete method should be non-reversible > (except in transactions) like "del" statement in Python. Or anybody > knows any reason, why it should be reversible? You didn't delete the object. That'd be spelled ``del instance``. You called a method called ``delete`` on

Re: Problem with ORM

2009-01-15 Thread Sebastian Bauer
I think ORM supposed to have save insert and update: save(force_insert=False,force_update=False) update() == save(force_update=True) insert() == save(force_insert=True) in that situation we could have clean code and we know that update is realy update on DB i now we can have save(force_update=T

Re: Problem with ORM

2009-01-15 Thread Jan Bednařík
On Thu, Jan 15, 2009 at 11:11 PM, Collin Grady wrote: > On Thu, Jan 15, 2009 at 2:09 PM, Jan Bednařík wrote: >> That should not happen. >> >> instance.delete() >> instance.save() >> >> should raise ObjectDoesNotExist exception. Any other behavior is bug. > > Why? You have a perfectly valid objec

Re: Problem with ORM

2009-01-15 Thread Collin Grady
On Thu, Jan 15, 2009 at 2:09 PM, Jan Bednařík wrote: > That should not happen. > > instance.delete() > instance.save() > > should raise ObjectDoesNotExist exception. Any other behavior is bug. Why? You have a perfectly valid object instance, and you're then saving it. Just like if you had instan

Re: Problem with ORM

2009-01-15 Thread Jan Bednařík
2009/1/15 Ian Kelly : > On Thu, Jan 15, 2009 at 1:58 AM, Jan Bednařík wrote: >> >> On Wed, Jan 14, 2009 at 6:51 PM, Sebastian Bauer wrote: >>> >>> Hi >>> >>> I think it's a bug, but maybe im wrong: >>> >>> >>> print Categories.objects.count() >>> >>0 >>> new_obj = Categories.objects.create(name

Re: Problem with ORM

2009-01-15 Thread Ian Kelly
On Thu, Jan 15, 2009 at 1:58 AM, Jan Bednařík wrote: > > On Wed, Jan 14, 2009 at 6:51 PM, Sebastian Bauer wrote: >> >> Hi >> >> I think it's a bug, but maybe im wrong: >> >> >> print Categories.objects.count() >> >>0 >> new_obj = Categories.objects.create(name="test") >> instance_1 = Categories

Re: Problem with ORM

2009-01-15 Thread James Bennett
On Thu, Jan 15, 2009 at 2:58 AM, Jan Bednařík wrote: > this is happening, because Django ORM is not working as what you > expect from ORM. > > In real ORM, this: No... I don't think you mean "real ORM", I think you mean "identity-mapping ORM". Those terms are not the same. -- "Bureaucrat Conra

Re: Problem with ORM

2009-01-15 Thread Jan Bednařík
On Wed, Jan 14, 2009 at 6:51 PM, Sebastian Bauer wrote: > > Hi > > I think it's a bug, but maybe im wrong: > > > print Categories.objects.count() > >>0 > new_obj = Categories.objects.create(name="test") > instance_1 = Categories.objects.get(pk=new_obj.pk) > instance_2 = Categories.objects.get(p

  1   2   >