Re: [Django] #9696: FileField raises unhandled exception when filename contains non-ascii characters

2009-01-21 Thread Django
#9696: FileField raises unhandled exception when filename contains non-ascii
characters
---+
  Reporter:  magarac   | Owner:  nobody
Status:  reopened  | Milestone:
 Component:  File uploads/storage  |   Version:  1.0   
Resolution:|  Keywords:
 Stage:  Unreviewed| Has_patch:  0 
Needs_docs:  0 |   Needs_tests:  0 
Needs_better_patch:  0 |  
---+
Comment (by aarond10):

 Sorry, I was wrong about the browser in the last report. I thought it was
 Firefox (reported via a customer) but turns out it was Lunascape. I have
 been unable to replicate this problem in Firefox, Chrome or IE7.

 I haven't had a chance to install the browser but I expect its reporting a
 different encoding to the one it is actually sending the filename in
 however I can't find any other reports of this on the web.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #9921: request.urlconf incorrect behavoir

2009-01-21 Thread Django
#9921: request.urlconf incorrect behavoir
+---
  Reporter:  strelnikovdmitrij  | Owner:  nobody 
Status:  reopened   | Milestone: 
 Component:  Core framework |   Version:  1.0
Resolution: |  Keywords:  request.urlconf
 Stage:  Unreviewed | Has_patch:  1  
Needs_docs:  0  |   Needs_tests:  1  
Needs_better_patch:  0  |  
+---
Comment (by SmileyChris):

 I think that #5034 would just fix this transparently.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



[Django] #10093: Table of Contents should show two levels

2009-01-21 Thread Django
#10093: Table of Contents should show two levels
---+
 Reporter:  adrian_nye |   Owner:  nobody
   Status:  new|   Milestone:
Component:  Documentation  | Version:  1.0   
 Keywords:  Table of contents  |   Stage:  Unreviewed
Has_patch:  0  |  
---+
 Currently the TOC shows only top level headings.  For example if you want
 the doc on QuerySets you have to know to click on "Models and Databases"
 and then you see "Making Queries".   The word "Query" does not appear
 anywhere at the top level.   It's unclear that some of the top level
 topics are single files, while others include a whole list of files.

 A two level deep TOC would be better (and it is the standard in technical
 books).  This has several advantages: first it is quicker to get to what
 you need.   Second you can see how the doc is organized in one view.
 Third you see more key topics and it is easier to understand the scope of
 the top level terms.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #7074: MySQL error/warning when 'gt' field lookup with a datetime field and fulltext search.

2009-01-21 Thread Django
#7074: MySQL error/warning when 'gt' field lookup with a datetime field and
fulltext search.
-+--
  Reporter:  anonymous   | Owner:   
  
Status:  new | Milestone:  post-1.0 
  
 Component:  Core framework  |   Version:  SVN  
  
Resolution:  |  Keywords:  qsrf-cleanup mysql, 
fulltext search, gt
 Stage:  Accepted| Has_patch:  0
  
Needs_docs:  0   |   Needs_tests:  0
  
Needs_better_patch:  0   |  
-+--
Changes (by pixelcort):

 * cc: cortl...@apple.com (added)

Comment:

 I'm also expreiencing this issue when using djangosearch r21 with a filter
 on a resulting search; the filter has a gte on a datetime.now.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



[Django] #10092: Reference documentation lowest-level headings too small and lack indents

2009-01-21 Thread Django
#10092: Reference documentation lowest-level headings too small and lack indents
---+
 Reporter:  adrian_nye |   Owner:  nobody
   Status:  new|   Milestone:
Component:  Documentation  | Version:  1.0   
 Keywords:  reference  |   Stage:  Unreviewed
Has_patch:  0  |  
---+
 The reference doc is tough to read because the headings for individual
 functions and methods are the same size as the surrounding text and in a
 less-contrasting color (green) than the surrounding text.   Therefore even
 though they are "bold" they don't stand out.   When "New in Django 1.x" is
 next to one of these headings, it is bigger than the heading.

 In some of the tutorial doc, the descriptive text is indented, and the
 headings stand out better.   For example see "exact" in
 http://docs.djangoproject.com/en/dev/topics/db/queries/
 If this was done in the reference as well it would be better.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



[Django] #10091: QuerySet documentation of slicing syntax misleading/incomplete

2009-01-21 Thread Django
#10091: QuerySet  documentation of slicing syntax misleading/incomplete
---+
 Reporter:  adrian_nye |   Owner:  nobody
   Status:  new|   Milestone:
Component:  Documentation  | Version:  1.0   
 Keywords:  QuerySet   |   Stage:  Unreviewed
Has_patch:  0  |  
---+
 Doc says:  "Use Python's array-slicing syntax to limit your QuerySet to a
 certain number of results."

 Should say:  "Use a subset of Python's array-slicing syntax to limit your
 QuerySet to a certain number of results."

 Should also say:  specifically mention that it doesn't accept negative
 indexes.   [-1] does not work for example.

 Would be nice: give an example of how to return the last (single) item in
 a queryset.   A good example would be: return the item with the most
 recent datetime.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #9696: FileField raises unhandled exception when filename contains non-ascii characters

2009-01-21 Thread Django
#9696: FileField raises unhandled exception when filename contains non-ascii
characters
---+
  Reporter:  magarac   | Owner:  nobody
Status:  reopened  | Milestone:
 Component:  File uploads/storage  |   Version:  1.0   
Resolution:|  Keywords:
 Stage:  Unreviewed| Has_patch:  0 
Needs_docs:  0 |   Needs_tests:  0 
Needs_better_patch:  0 |  
---+
Changes (by aarond10):

  * status:  closed => reopened
  * resolution:  worksforme =>

Comment:

 I am having this problem also. Reared its head in pinax svn version when
 using the avatar upload feature
 . Filename is in Japanese. The file was uploaded via Firefox 3.

 - Aaron

 {{{

 Traceback (most recent call last):

  File "/usr/lib/python2.5/site-packages/django/core/handlers/base.py",
 line 86, in get_response
response = callback(request, *callback_args, **callback_kwargs)

  File "/usr/lib/python2.5/site-
 packages/django/contrib/auth/decorators.py", line 67, in __call__
return self.view_func(request, *args, **kwargs)

  File "/var/www/django/pinax0.5.0/apps/external_apps/avatar/views.py",
 line 48, in change

  File "/usr/lib/python2.5/site-packages/django/core/files/storage.py",
 line 44, in save
name = self.get_available_name(name)

  File "/usr/lib/python2.5/site-packages/django/core/files/storage.py",
 line 66, in get_available_nam
 e
while self.exists(name):

  File "/usr/lib/python2.5/site-packages/django/core/files/storage.py",
 line 188, in exists
return os.path.exists(self.path(name))

  File "/usr/lib/python2.5/posixpath.py", line 171, in exists
st = os.stat(path)

 UnicodeEncodeError: 'ascii' codec can't encode characters in position
 67-69: ordinal not in range(128
 )
 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



[Django] #10090: small error in example code for looping over hidden form fields

2009-01-21 Thread Django
#10090: small error in example code for looping over hidden form fields
---+
 Reporter:  casey  |   Owner:  nobody
   Status:  new|   Milestone:
Component:  Documentation  | Version:  1.0   
 Keywords: |   Stage:  Unreviewed
Has_patch:  0  |  
---+
 
 {% for field in form.visible_fields %}
 

 {# Include the hidden fields in the form #}
 {% if forloop.first %}
 {% for hidden in form.hidden_fields %}
 {{ field }}
 {% endfor %}
 {% endif %}

 {{ field.errors }}
 {{ field.label_tag }}: {{ field }}
 
 {% endfor %}
 
 

 This is from "Looping Over Hidden and Visible Fields" at
 http://docs.djangoproject.com/en/dev/topics/forms/#topics-forms-index.
 There is an error in the inner for loop foir hidden fields. In this loop,
 "{{field}}"" should be "{{hidden}}" to reflect the variable name in the
 inner loop.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #10071: month and day lookup arguments should be integers

2009-01-21 Thread Django
#10071: month and day lookup arguments should be integers
+---
  Reporter:  leosoto| Owner:  nobody
Status:  new| Milestone:
 Component:  Uncategorized  |   Version:  1.0   
Resolution: |  Keywords:  jython
 Stage:  Unreviewed | Has_patch:  1 
Needs_docs:  0  |   Needs_tests:  0 
Needs_better_patch:  0  |  
+---
Changes (by leosoto):

  * needs_better_patch:  => 0
  * needs_tests:  => 0
  * needs_docs:  => 0

Comment:

 As reference, mailing discussion is here: http://groups.google.com/group
 /django-developers/browse_thread/thread/db56e53fac0d1fa6

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #10089: Aggregation breaks QuerySet.count() with empty results

2009-01-21 Thread Django
#10089: Aggregation breaks QuerySet.count() with empty results
---+
  Reporter:  Kyle Fox  | Owner:  david  
  
Status:  assigned  | Milestone:  post-1.0   
  
 Component:  Database layer (models, ORM)  |   Version:  SVN
  
Resolution:|  Keywords:  queryset, 
execute_sql, aggregation, count, filter, in
 Stage:  Unreviewed| Has_patch:  1  
  
Needs_docs:  0 |   Needs_tests:  0  
  
Needs_better_patch:  0 |  
---+
Changes (by david):

  * status:  new => assigned
  * needs_better_patch:  => 0
  * needs_tests:  => 0
  * owner:  nobody => david
  * needs_docs:  => 0
  * has_patch:  0 => 1

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #10088: for_share() as well as for_update() addition to Model.QuerySet

2009-01-21 Thread Django
#10088: for_share() as well as for_update() addition to Model.QuerySet
---+
  Reporter:  epandurski| Owner:  
Status:  new   | Milestone:  post-1.0
 Component:  Database layer (models, ORM)  |   Version:  1.0 
Resolution:|  Keywords:  
 Stage:  Design decision needed| Has_patch:  0   
Needs_docs:  0 |   Needs_tests:  0   
Needs_better_patch:  0 |  
---+
Changes (by mtredinnick):

  * owner:  m...@noris.de, rajeev.sebast...@gmail.com, v...@stream.net.ua,
sebast...@e-ti.net, justin.fi...@gmail.com,
lidaob...@gmail.com, jdem...@gmail.com,
walle...@gmail.com, sebast...@sspaeth.de =>
  * stage:  Unreviewed => Design decision needed

Comment:

 Removing the ''list'' of people in the assigned field.

 This is fairly orthogonal to `for_update()`. Django isn't meant to provide
 wrappers for every database feature under the sun, so we might not do
 this. Worth thinking about, however.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



[Django] #10089: Aggregation breaks QuerySet.count() with empty results

2009-01-21 Thread Django
#10089: Aggregation breaks QuerySet.count() with empty results
---+
 Reporter:  Kyle Fox   |   
Owner:  nobody
   Status:  new|   
Milestone:  post-1.0  
Component:  Database layer (models, ORM)   | 
Version:  SVN   
 Keywords:  queryset, execute_sql, aggregation, count, filter, in  |   
Stage:  Unreviewed
Has_patch:  0  |  
---+
 When calling `count()` after performing an `__in=[]` filter, a TypeError
 is thrown (see example).  This is because
 
[http://code.djangoproject.com/browser/django/trunk/django/db/models/sql/query.py#L262
 BaseQuery.get_aggregation ] is attempting to zip
 `query.execute_sql(SINGLE)` (line 301), which can evaluate to None in
 
[http://code.djangoproject.com/browser/django/trunk/django/db/models/sql/query.py#L1914
 Line 1933]:

 {{{
 # Works, even if the filter returns no results.
 User.objects.filter(id__in=[1,2,3]).count()
 User.objects.filter(id__in=[99,100,101]).count()

 # Breaks: Filtering with an empty list and then calling `count()` throws
 an error.
 User.objects.filter(id__in=[]).count()
 }}}

 I'm not sure how to fix this problem.  I'm assuming that a return value of
 `None` is the intended behavior of `execute_sql` in this case, and that
 `get_aggregation` should be make more robust to handle a result of None.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



[Django] #10088: for_share() as well as for_update() addition to Model.QuerySet

2009-01-21 Thread Django
#10088: for_share() as well as for_update() addition to Model.QuerySet
--+-
 Reporter:  epandurski|   Owner:  m...@noris.de, 
rajeev.sebast...@gmail.com, v...@stream.net.ua, sebast...@e-ti.net, 
justin.fi...@gmail.com, lidaob...@gmail.com, jdem...@gmail.com, 
walle...@gmail.com, sebast...@sspaeth.de
   Status:  new   |   Milestone:  post-1.0  


   
Component:  Database layer (models, ORM)  | Version:  1.0   


   
 Keywords:|   Stage:  Unreviewed


   
Has_patch:  0 |  
--+-
 Ticket #2705 is a very good idea I think.

 PostgreSQL supports SELECT ... FOR SHARE locking mode, which is basically
 the same as FOR UPDATE mode but it does not conflicts with other
 transaction
 having obtained FOR SHARE mode for the row.
 (see http://www.postgresql.org/docs/8.3/static/sql-select.html#SQL-FOR-
 UPDATE-SHARE)
 It very useful if you need to be sure that your selected rows are not
 modified since you have read them (which is true for almost every complex
 transaction).

 I am not sure if MySQL has this feature but in PostgreSQL it first-class
 citizen so
 I believe for_share() and for_update() has to be implemented together.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #10087: Missing models.py in django.contrib.localflavor.fr

2009-01-21 Thread Django
#10087: Missing models.py in django.contrib.localflavor.fr
-+--
  Reporter:  lstep   | Owner:  nobody
Status:  new | Milestone:
 Component:  django.contrib.localflavor  |   Version:  1.0   
Resolution:  |  Keywords:
 Stage:  Unreviewed  | Has_patch:  1 
Needs_docs:  1   |   Needs_tests:  0 
Needs_better_patch:  1   |  
-+--
Changes (by david):

 * cc: david (added)
  * needs_better_patch:  => 1
  * needs_tests:  => 0
  * needs_docs:  => 1

Comment:

 Thanks for adding this, size in db_type methods should be limited to 5 and
 14 respectively (as forms validate those).

 Note that documentation is missing too, do you plan to add it?

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #10088: for_share() as well as for_update() addition to Model.QuerySet

2009-01-21 Thread Django
#10088: for_share() as well as for_update() addition to Model.QuerySet
---+
  Reporter:  epandurski| Owner:  
m...@noris.de, rajeev.sebast...@gmail.com, v...@stream.net.ua, 
sebast...@e-ti.net, justin.fi...@gmail.com, lidaob...@gmail.com, 
jdem...@gmail.com, walle...@gmail.com, sebast...@sspaeth.de
Status:  new   | Milestone:  post-1.0   


  
 Component:  Database layer (models, ORM)  |   Version:  1.0


  
Resolution:|  Keywords: 


  
 Stage:  Unreviewed| Has_patch:  0  


  
Needs_docs:  0 |   Needs_tests:  0  


  
Needs_better_patch:  0 |  
---+
Changes (by epandurski):

  * needs_better_patch:  => 0
  * needs_tests:  => 0
  * needs_docs:  => 0

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #10085: Forms from model documentation: The importance of the "_unicode_" method of a model

2009-01-21 Thread Django
#10085: Forms from model documentation: The importance of the "_unicode_" 
method of
a model
+---
  Reporter:  olimination| Owner:  nobody 
Status:  closed | Milestone: 
 Component:  Documentation  |   Version:  1.0
Resolution:  wontfix|  Keywords:  forms model
 Stage:  Unreviewed | Has_patch:  0  
Needs_docs:  0  |   Needs_tests:  0  
Needs_better_patch:  0  |  
+---
Changes (by olimination):

  * status:  new => closed
  * resolution:  => wontfix

Comment:

 Your posted link was exactly that, what I had needed at that time, I just
 haven't found it :-).
 I have coded a small application for administrating persons, grades and
 modules for an university of applied sciences.
 I had created a PersonForm class which had inherited from the
 forms.ModelForm and which had a Location-object as a foreignkey. I had
 forgotten then to set the _unicode_ method in the Location-model. In the
 template then, the html-select-field was empty and no errors or warnings
 occured.
 If you are interested to see the code:
 
http://svn.origo.ethz.ch/wsvn/sunas/branches/0.9-beta/src/sunas/persons/models.py
 (but since then we have changed already a lot..).

 I think you can close the ticket, because the stuff is documented.

 Thanks!

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #10037: id column is created in ManyToMany link (relation) table

2009-01-21 Thread Django
#10037: id column is created in ManyToMany link (relation) table
---+
  Reporter:  powerfox  | Owner:  nobody 

Status:  new   | Milestone: 

 Component:  Database layer (models, ORM)  |   Version:  SVN

Resolution:|  Keywords:  
ManyToManyField
 Stage:  Unreviewed| Has_patch:  1  

Needs_docs:  0 |   Needs_tests:  0  

Needs_better_patch:  1 |  
---+
Changes (by powerfox):

  * needs_better_patch:  0 => 1

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #10037: id column is created in ManyToMany link (relation) table

2009-01-21 Thread Django
#10037: id column is created in ManyToMany link (relation) table
---+
  Reporter:  powerfox  | Owner:  nobody 

Status:  new   | Milestone: 

 Component:  Database layer (models, ORM)  |   Version:  SVN

Resolution:|  Keywords:  
ManyToManyField
 Stage:  Unreviewed| Has_patch:  1  

Needs_docs:  0 |   Needs_tests:  0  

Needs_better_patch:  0 |  
---+
Changes (by powerfox):

  * needs_better_patch:  => 0
  * needs_tests:  => 0
  * needs_docs:  => 0

Comment:

 There is one more place there, where id is used and I didn't fix that.
 Nnow I see that it might be done intentionally.
 Wayting for responce.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #5609: newforms-admin: input fields do not regard field class

2009-01-21 Thread Django
#5609: newforms-admin: input fields do not regard field class
---+
  Reporter:  anonymous | Owner:  brosner   
Status:  reopened  | Milestone:  1.0 beta  
 Component:  django.contrib.admin  |   Version:  SVN   
Resolution:|  Keywords:  length input class
 Stage:  Accepted  | Has_patch:  1 
Needs_docs:  0 |   Needs_tests:  1 
Needs_better_patch:  0 |  
---+
Changes (by jacmkno):

  * status:  closed => reopened
  * resolution:  duplicate =>
  * needs_tests:  0 => 1

Comment:

 I don't think the #8163 has a solution for this that thicked was supposed
 to be fixed but it still does not work in the current dev version.
 This ticket has to be re-opened.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



[Django] #10087: Missing models.py in django.contrib.localflavor.fr

2009-01-21 Thread Django
#10087: Missing models.py in django.contrib.localflavor.fr
+---
 Reporter:  lstep   |   Owner:  nobody
   Status:  new |   Milestone:
Component:  django.contrib.localflavor  | Version:  1.0   
 Keywords:  |   Stage:  Unreviewed
Has_patch:  1   |  
+---
 To use french flavored PhoneNumberField in models, one need the models.py
 file like in django.contrib.localflavor.us.
 Here's the diff to add it.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #5306: ImageField upload_to - New Web Forms

2009-01-21 Thread Django
#5306: ImageField upload_to - New Web Forms
--+-
  Reporter:  danielrubio  | Owner:  nobody  
Status:  closed   | Milestone:  
 Component:  Forms|   Version:  SVN 
Resolution:  fixed|  Keywords:  Image field upload_to, fs-rf
 Stage:  Unreviewed   | Has_patch:  0   
Needs_docs:  0|   Needs_tests:  0   
Needs_better_patch:  0|  
--+-
Comment (by kmtracey):

 Replying to [comment:4 mtredinnick]:
 >
 > Form file fields are, per se, broken, ...

 Just to clarify, this is missing an important 'not'.  Form file fields are
 not, per se, broken, since they work in admin, etc.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #10085: Forms from model documentation: The importance of the "_unicode_" method of a model

2009-01-21 Thread Django
#10085: Forms from model documentation: The importance of the "_unicode_" 
method of
a model
+---
  Reporter:  olimination| Owner:  nobody 
Status:  new| Milestone: 
 Component:  Documentation  |   Version:  1.0
Resolution: |  Keywords:  forms model
 Stage:  Unreviewed | Has_patch:  0  
Needs_docs:  0  |   Needs_tests:  0  
Needs_better_patch:  0  |  
+---
Changes (by kmtracey):

  * needs_better_patch:  => 0
  * needs_tests:  => 0
  * needs_docs:  => 0

Comment:

 I am not sure where you think this mention will be helpful?  The doc for
 !ModelChoiceField already notes that `__unicode__` is what is used to
 populate the select box dropdown list:

 http://docs.djangoproject.com/en/dev/ref/forms/fields/#modelchoicefield

 Also I'm puzzled by your experience with neglecting to include a
 `__unicode__` method causing nothing to be displayed.  If I remove the
 `__unicode__` method from a model (Authors) and then go to the admin for a
 related model that has an Authors !ForeignKey, I see a drop-down list that
 is populated with "Authors object" entries, not an empty select box.  So
 more information on what you had, exactly (and what exact level of Django
 you are running), might help track down what caused an empty select box in
 your case.  I think it had to be more than lack of a `__unicode__` method.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #5306: ImageField upload_to - New Web Forms

2009-01-21 Thread Django
#5306: ImageField upload_to - New Web Forms
--+-
  Reporter:  danielrubio  | Owner:  nobody  
Status:  closed   | Milestone:  
 Component:  Forms|   Version:  SVN 
Resolution:  fixed|  Keywords:  Image field upload_to, fs-rf
 Stage:  Unreviewed   | Has_patch:  0   
Needs_docs:  0|   Needs_tests:  0   
Needs_better_patch:  0|  
--+-
Changes (by mtredinnick):

  * status:  reopened => closed
  * resolution:  => fixed

Comment:

 The form field wouldn't be expected to take an `upload_to` parameter,
 since forms, by default, don't save any data. That's up to either the view
 function or, more typically, the model. So model fields take `upload_to`.

 Form file fields are, per se, broken, since, for example, they work in the
 admin. So you might wish to post some details about your situation on
 django-users or #django to get some help to clarify the situation. If
 there really is a problem here, please open a new ticket, since this
 ticket was about something that has already been fixed (it's not clear
 that it was a bug in the first place, since, again, normal forms aren't
 responsible for saving data).

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #5306: ImageField upload_to - New Web Forms

2009-01-21 Thread Django
#5306: ImageField upload_to - New Web Forms
--+-
  Reporter:  danielrubio  | Owner:  nobody  
Status:  reopened | Milestone:  
 Component:  Forms|   Version:  SVN 
Resolution:   |  Keywords:  Image field upload_to, fs-rf
 Stage:  Unreviewed   | Has_patch:  0   
Needs_docs:  0|   Needs_tests:  0   
Needs_better_patch:  0|  
--+-
Changes (by Loststylus):

  * status:  closed => reopened
  * resolution:  duplicate =>

Comment:

 Still having trouble here. Django 1.0.2, forms.ImageField doesn't accept
 upload_to and uploading doesn't work.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #10086: select_related and annotate weird behaviour

2009-01-21 Thread Django
#10086: select_related and annotate weird behaviour
---+
  Reporter:  pa...@fragstore.net   | Owner:  nobody 

Status:  new   | Milestone: 

 Component:  Database layer (models, ORM)  |   Version:  SVN

Resolution:|  Keywords:  
select_related,annotate
 Stage:  Unreviewed| Has_patch:  0  

Needs_docs:  0 |   Needs_tests:  0  

Needs_better_patch:  0 |  
---+
Changes (by pa...@fragstore.net):

  * needs_better_patch:  => 0
  * needs_tests:  => 0
  * needs_docs:  => 0

Comment:

 Sorry for the bad formatting, here are the queries reformatted:
 {{{

 bestBlogs = BlogEntry.objects.select_related("user",
 "BlogEntryCommentBlogEntry__comment",
 "BlogEntryCommentBlogEntry__comment__author").filter(datetime__gte =
 
lastWeek).annotate(Count("BlogEntryCommentBlogEntry")).order_by("-BlogEntryCommentBlogEntry__count")[:settings.NUM_HOME_SIDEBAR_COMMUNITY_TOPBLOGS]
 print dir(bestBlogs[0].user), bestBlogs[0].user.username

 bestBlogs =
 BlogEntry.objects.select_related("BlogEntryCommentBlogEntry__comment",
 "BlogEntryCommentBlogEntry__comment__author").filter(datetime__gte =
 
lastWeek).annotate(Count("BlogEntryCommentBlogEntry")).order_by("-BlogEntryCommentBlogEntry__count")[:settings.NUM_HOME_SIDEBAR_COMMUNITY_TOPBLOGS]
 print dir(bestBlogs[0].user), bestBlogs[0].user.username

 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



[Django] #10086: select_related and annotate weird behaviour

2009-01-21 Thread Django
#10086: select_related and annotate weird behaviour
--+-
 Reporter:  pa...@fragstore.net   |   Owner:  nobody
   Status:  new   |   Milestone:
Component:  Database layer (models, ORM)  | Version:  SVN   
 Keywords:  select_related,annotate   |   Stage:  Unreviewed
Has_patch:  0 |  
--+-
 Considering the following Models:
 {{{
 class BlogEntry(models.Model):
 user = models.ForeignKey(User, related_name="BlogEntryUser")
 datetime = models.DateTimeField(auto_now_add=True)
 datetimeModified = models.DateTimeField(null=True, blank=True)
 title = models.CharField(max_length=255)
 titleSlug = models.SlugField(editable=False)
 text = models.TextField()
 hitCount = models.IntegerField("Zugriffe", default=0, blank=True,
 null=True, editable=False)
 visitors = models.ManyToManyField(User, null=True, blank=True,
 related_name="BlogEntryVisitorsUser")

 class BlogEntryComment(models.Model):
 comment = models.ForeignKey(Comment, verbose_name="Comment",
 related_name="BlogEntryCommentComment")
 motherModel = models.ForeignKey(BlogEntry, verbose_name="Blog
 Eintrag", related_name="BlogEntryCommentBlogEntry")

 class Comment(models.Model):
 text = models.TextField("Inhalt")
 author   = models.ForeignKey(User, related_name="CommentAuthorUser",
 verbose_name="Autor")
 datetime = models.DateTimeField("Geschrieben um", editable=False)
 lastedit = models.DateTimeField("Zuletzt editiert am", editable=False,
 null=True, blank=True)
 lastedit_by = models.ForeignKey(User,
 related_name="CommentLastEditUser", verbose_name="Autor", editable=False,
 null=True, blank=True)
 }}}

 # Using the following annotated query:
 lastWeek = datetime.date.today() - datetime.timedelta(days=7)
 bestBlogs = BlogEntry.objects.select_related("user",
 "BlogEntryCommentBlogEntry__comment",
 "BlogEntryCommentBlogEntry__comment__author").filter(datetime__gte =
 
lastWeek).annotate(Count("BlogEntryCommentBlogEntry")).order_by("-BlogEntryCommentBlogEntry__count")[:settings.NUM_HOME_SIDEBAR_COMMUNITY_TOPBLOGS]

 # then doing
 print dir(bestBlogs[0].user), bestBlogs[0].user.username

 # results in
 ['AdminNoticeUser', 'AdminUserNoteUser', 'BlogEntryUser',
 'BlogEntryVisitorsUser', 'CommentAuthorUser', 'CommentLastEditUser',
 'DoesNotExist', 'ForumThreadUser', 'MultipleObjectsReturned',
 'PickRoomClient1User', 'PickRoomClient2User', 'PickRoomMasterCreator',
 'PickRoomMasterUser', 'PlayerFanClubMemberUser', 'PublicGalleryItems',
 'TeamFanClubMemberUser', 'UserBetUser', 'UserFlatPage', 'UserNoteAdmin',
 '__class__', '__delattr__', '__dict__', '__doc__', '__eq__',
 '__getattribute__', '__hash__', '__init__', '__metaclass__', '__module__',
 '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__',
 '__setattr__', '__str__', '__unicode__', '__weakref__',
 '_collect_sub_objects', '_default_manager', '_get_FIELD_display',
 '_get_next_or_previous_by_FIELD', '_get_next_or_previous_in_order',
 '_get_pk_val', '_meta', '_set_pk_val', 'article_set', 'check_password',
 'date_joined', 'delete', 'email', 'email_user', 'first_name',
 'get_absolute_url', 'get_all_permissions', 'get_and_delete_messages',
 'get_full_name', 'get_group_permissions', 'get_next_by_date_joined',
 'get_next_by_last_login', 'get_previous_by_date_joined',
 'get_previous_by_last_login', 'get_profile', 'groups', 'has_module_perms',
 'has_perm', 'has_perms', 'has_usable_password', 'id', 'is_active',
 'is_anonymous', 'is_authenticated', 'is_staff', 'is_superuser',
 'last_login', 'last_name', 'logentry_set', 'message_set', 'objects',
 'password', 'pk', 'registrationprofile_set', 'save', 'save_base',
 'serializable_value', 'set_password', 'set_unusable_password',
 'user_permissions', 'username', 'userprofile_set'] 3

 Notice the "3" in user.username.

 Issuing the query without "user" in the select_related() clause results
 in:
 ['AdminNoticeUser', 'AdminUserNoteUser', 'BlogEntryUser',
 'BlogEntryVisitorsUser', 'CommentAuthorUser', 'CommentLastEditUser',
 'DoesNotExist', 'ForumThreadUser', 'MultipleObjectsReturned',
 'PickRoomClient1User', 'PickRoomClient2User', 'PickRoomMasterCreator',
 'PickRoomMasterUser', 'PlayerFanClubMemberUser', 'PublicGalleryItems',
 'TeamFanClubMemberUser', 'UserBetUser', 'UserFlatPage', 'UserNoteAdmin',
 '__class__', '__delattr__', '__dict__', '__doc__', '__eq__',
 '__getattribute__', '__hash__', '__init__', '__metaclass__', '__module__',
 '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__',
 '__setattr__', '__str__', '__unicode__', '__weakref__',
 '_collect_sub_objects', '_default_manager', '_get_FIELD_display',
 '_get_next_or_previous_by_FIELD', '_get_next_or_previous_in_order',
 '_get_pk_val', '_meta', '_set_pk_val', 'article_set', 'check_password',
 'date_joined', 

Re: [Django] #4339: Override an existing file, using Model.save_FIELD_file method,

2009-01-21 Thread Django
#4339: Override an existing file, using Model.save_FIELD_file method,
---+
  Reporter:  elaat...@gmail.com| Owner:  Gulopine   

Status:  reopened  | Milestone: 

 Component:  Database layer (models, ORM)  |   Version:  SVN

Resolution:|  Keywords:  FileField 
db fs-rf-docs
 Stage:  Design decision needed| Has_patch:  1  

Needs_docs:  1 |   Needs_tests:  0  

Needs_better_patch:  1 |  
---+
Comment (by elaatifi):

 With Django's new file access API there is more flexibity to deal with
 such problems.

 I think it's not a good idea to override get_available_name since it's a
 public methode
 that shouldn't have a side effect (I suppose) due to his name

 {{{class OverwriteStorage(FileSystemStorage):
 def _save(self, name, content):
 if self.exists(name):
 self.delete(name)
 return super(OverwriteStorage, self)._save(name, content)
 }}}

 Thank you

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



[Django] #10085: Forms from model documentation: The importance of the "_unicode_" method of a model

2009-01-21 Thread Django
#10085: Forms from model documentation: The importance of the "_unicode_" 
method of
a model
---+
 Reporter:  olimination|   Owner:  nobody
   Status:  new|   Milestone:
Component:  Documentation  | Version:  1.0   
 Keywords:  forms model|   Stage:  Unreviewed
Has_patch:  0  |  
---+
 Though you note in the "First steps"-tutorial that the "_unicode-" method
 is a quite often used method for the Django admin,etc. it would be nice,
 if you document this in the "Forms from model" documentation too, because
 the "ModelChoiceField" is using the "_unicode_" method for showing the
 model items in the html-select-field. If you don't provide this method,
 the html-select-field will be emtpy. No warnings or similar is showed by
 Django, its then a bit confusing for a newbie like me :-).

 For a newbie like me, it took almost a day to figure this out, because no
 error/warning have be thrown by Django.

 I think it will be helpful for other starting newbies that this behaviour
 should be explicit documented for the forms documentation.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #9962: Add a tutorial for the testing framework

2009-01-21 Thread Django
#9962: Add a tutorial for the testing framework
+---
  Reporter:  russellm   | Owner:  nobody
Status:  new| Milestone:
 Component:  Documentation  |   Version:  1.0   
Resolution: |  Keywords:
 Stage:  Accepted   | Has_patch:  0 
Needs_docs:  0  |   Needs_tests:  0 
Needs_better_patch:  0  |  
+---
Comment (by oduvan):

 http://docs.djangoproject.com/en/dev/topics/testing/#using-different-
 testing-frameworks

 it's not enough? What section must be added?

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---



Re: [Django] #811: [patch] IPv6 address field support

2009-01-21 Thread Django
#811: [patch] IPv6 address field support
-+--
  Reporter:  mattimust...@gmail.com  | Owner:  adrian
Status:  reopened| Milestone:
 Component:  Core framework  |   Version:  SVN   
Resolution:  |  Keywords:
 Stage:  Ready for checkin   | Has_patch:  1 
Needs_docs:  0   |   Needs_tests:  0 
Needs_better_patch:  0   |  
-+--
Comment (by jqueuniet):

 Previous patch updated for current trunk, revision 9781. Nothing was
 changed, I just moved code around and deleted all the oldforms cruft from
 pre-1.0.

 Don't know why but Trac won't show the patch as it usually does. Download
 as original format seems to work though, so I'll just leave it as it is.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~--~~~~--~~--~--~---