Re: [Django] #15672: wsgi handler bug in 1.3

2011-07-29 Thread Django
#15672: wsgi handler bug in 1.3
-+-
   Reporter:  vkryachko  |  Owner:  vkryachko
   Type:  Bug| Status:  closed
  Milestone: |  Component:  Core (Other)
Version:  1.3|   Severity:  Release blocker
 Resolution:  fixed  |   Keywords:
   Triage Stage:  Design |  Has patch:  1
  decision needed|Needs tests:  0
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by kmtracey):

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


Comment:

 This ticket was about a straightforward bug: use of a variable before it
 had been set. The recent comments and re-opening of this ticket don't seem
 related to that simple bug, which has been fixed. If you think this area
 of the code has some other problem please open a new ticket to track that.
 Reclosing this ticket as fixed, because the !UnboundLocalError has been
 fixed.

-- 
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] #16539: ModelForms ignore default values when value is not supplied

2011-07-29 Thread Django
#16539: ModelForms ignore default values when value is not supplied
--+
   Reporter:  semarjt@…   |  Owner:  nobody
   Type:  Bug | Status:  new
  Milestone:  |  Component:  Forms
Version:  1.3 |   Severity:  Normal
 Resolution:  |   Keywords:  Model|Form
   Triage Stage:  Unreviewed  |  Has patch:  0
Needs documentation:  0   |Needs tests:  0
Patch needs improvement:  0   |  Easy pickings:  1
  UI/UX:  0   |
--+
Changes (by anonymous):

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


Comment:

 Replying to [ticket:16539 semarjt@…]:
 > A model with boolean fields has values set to False, regardless of
 default in model declaration.
 >
 > This is only if ModelForms are used to create the instance
 >
 > There is a working example here:
 https://github.com/joelsemar/formapp.git
 >
 > this is a simple base case, easily runnable.


 bad url: https://github.com/joelsemar/formapp

 sorry

-- 
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] #16539: ModelForms ignore default values when value is not supplied

2011-07-29 Thread Django
#16539: ModelForms ignore default values when value is not supplied
+
 Reporter:  semarjt@…   |  Owner:  nobody
 Type:  Bug | Status:  new
Milestone:  |  Component:  Forms
  Version:  1.3 |   Severity:  Normal
 Keywords:  Model|Form  |   Triage Stage:  Unreviewed
Has patch:  0   |  Easy pickings:  1
UI/UX:  0   |
+
 A model with boolean fields has values set to False, regardless of default
 in model declaration.

 This is only if ModelForms are used to create the instance

 There is a working example here: https://github.com/joelsemar/formapp.git

 this is a simple base case, easily runnable.

-- 
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] #16538: Models fail to sync when using multiple app_label in same models.py

2011-07-29 Thread Django
#16538: Models fail to sync when using multiple app_label in same models.py
-+-
   Reporter:  echos  |  Owner:  nobody
   Type:  Bug| Status:  closed
  Milestone: |  Component:  Database layer
Version:  1.3|  (models, ORM)
 Resolution:  needsinfo  |   Severity:  Normal
   Triage Stage: |   Keywords:
  Unreviewed |  Has patch:  0
Needs documentation:  0  |Needs tests:  0
Patch needs improvement:  0  |  Easy pickings:  0
  UI/UX:  0  |
-+-
Changes (by ramiro):

 * status:  new => closed
 * needs_docs:   => 0
 * resolution:   => needsinfo
 * needs_tests:   => 0
 * needs_better_patch:   => 0


Comment:

 What's the use case of having models from one models module in more than
 one app? What's the name of the app containing these models?. With the
 data given in the report, seems to me like stretching that `app_label`
 facility too far and possibly using it for something too different from
 what it has been created for.

-- 
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] #16538: Models fail to sync when using multiple app_label in same models.py

2011-07-29 Thread Django
#16538: Models fail to sync when using multiple app_label in same models.py
---+--
 Reporter:  echos  |  Owner:  nobody
 Type:  Bug| Status:  new
Milestone: |  Component:  Database layer (models, ORM)
  Version:  1.3|   Severity:  Normal
 Keywords: |   Triage Stage:  Unreviewed
Has patch:  0  |  Easy pickings:  0
UI/UX:  0  |
---+--
 {{{#!python
 from django.db import models

 class ModelOne(models.Model):
 # fields

 class Meta:
 app_label = 'app_one'

 class ModelTwo(models.Model):
 # fields

 class Meta:
 app_label = 'app_two'
 }}}

 In the above example !ModelOne will not create a table in the database but
 !ModelTwo will.

-- 
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] #16368: Custom sites model overridden by contrib.sites.model.Site

2011-07-29 Thread Django
#16368: Custom sites model overridden by contrib.sites.model.Site
-+-
   Reporter: |  Owner:  nobody
  briehan.lombaard@… | Status:  reopened
   Type:  Bug|  Component:  contrib.sites
  Milestone: |   Severity:  Normal
Version:  SVN|   Keywords:
 Resolution: |  Has patch:  0
   Triage Stage:  Accepted   |Needs tests:  0
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-

Comment (by ramiro):

 Some findings and notes:

 Bisection betwen 1.2 and 1.3 (the two releases the OP reports things
 changed from working to not working e.g. the custom Sites model gets
 replaced by the `contrib.sites` app one even when that app isn't listed in
 INSTALLED_APPS) shows the changeset where that change in behavior appeared
 is r14769.

 (Conditions are: Using the simple `foobar` project attached to this ticket
 and adding `django.contrib.contenttypes import generic` to its
 `sites/models.py`)

 I don't think the changes from that commit in particular are wrong
 regarding this issue. Looking at the traceback in comment:12 IMHO what's
 the culprit of this unexpected behavior is the fact that
 `django.contrib.contenttypes.generic` contains both the definitions of the
 model-related generic stuff (!GenericForeignKey, etc.) AND the admin app-
 related specialized inlines (!GenericInlineModelAdmin,
 !GenericStackedInline, !GenericTabularInline.)

 So, for example, if you import `django.contrib.contenttypes.generic` from
 your `models.py` because you need !GenericForeignKey then the
 Generic*Inline* sutff imports `django.contrib.admin` and it in its own
 turn imports `contrib.sites` causing the observed failure. Again, the
 Sites framework isn't listed in INSTALLED_APPS and what is worth: The
 admin app isn't either (!).

 Maybe it's time we move !GenericInlineModelAdmin, !GenericStackedInline,
 !GenericTabularInline from `django.contrib.contenttypes.generic` to, say,
 `django.contrib.contenttypes.generic_admin`? (of course this would need a
 deprecation path)

-- 
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] #16537: layermapping spatial ref check not checking against alternate DB

2011-07-29 Thread Django
#16537: layermapping spatial ref check not checking against alternate DB
---+
 Reporter:  shifflett.shane@…  |  Owner:  nobody
 Type:  Bug| Status:  new
Milestone: |  Component:  GIS
  Version:  1.3|   Severity:  Normal
 Keywords: |   Triage Stage:  Unreviewed
Has patch:  1  |  Easy pickings:  1
UI/UX:  0  |
---+
 django/contrib/gis/utils/layermapping.py uses alternate database to save
 geometries however when checking the SRID against the SPATIAL REF table it
 does not check against an alternate database if the user specifies one.
 For a user to experience this error they must have two databases and the
 default database cannot store shape data.

 issue occurs in django/contrib/gis/utils/layermapping.py line 432

 OLD CODE (SRID lookup will fail if user has an alternate database storing
 shape data):
 target_srs = SpatialRefSys.objects.get(srid=self.geo_field.srid).srs

 PROPOSED FIX (SRID lookup succeeds and functions similar to SAVE
 function):
 target_srs =
 SpatialRefSys.objects.using(self.using).get(srid=self.geo_field.srid).srs

-- 
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] #16536: inspectdb with numerical column names

2011-07-29 Thread Django
#16536: inspectdb with numerical column names
-+
 Reporter:  danodonovan  |  Owner:  nobody
 Type:  Bug  | Status:  new
Milestone:   |  Component:  Core (Management commands)
  Version:  SVN  |   Severity:  Normal
 Keywords:  inspectdb|   Triage Stage:  Unreviewed
Has patch:  0|  Easy pickings:  0
UI/UX:  0|
-+
 inspectdb produces model fields with numerical values for fieldnames when
 running with a (MySQL at least) DB with numerical column labels. For
 example, sql with column names 1 and 2 results in invalid python code:


 {{{
 1 = models.CharField()
 2 = models.CharField()
 }}}


 I would submit a patch, but I don't want to suggest a default prefix name
 for these fields without advice. Would suggest 'number_%d' % db_column or
 similar.

-- 
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] #15672: wsgi handler bug in 1.3

2011-07-29 Thread Django
#15672: wsgi handler bug in 1.3
-+-
   Reporter:  vkryachko  |  Owner:  vkryachko
   Type:  Bug| Status:  reopened
  Milestone: |  Component:  Core (Other)
Version:  1.3|   Severity:  Release blocker
 Resolution: |   Keywords:
   Triage Stage:  Design |  Has patch:  1
  decision needed|Needs tests:  0
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by kinpoo):

 * status:  closed => reopened
 * resolution:  fixed =>
 * stage:  Accepted => Design decision needed


-- 
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] #16535: UnicodeEncodeError

2011-07-29 Thread Django
#16535: UnicodeEncodeError
--+---
   Reporter:  direct@…|  Owner:  nobody
   Type:  Bug | Status:  closed
  Milestone:  |  Component:  contrib.admin
Version:  1.3 |   Severity:  Normal
 Resolution:  invalid |   Keywords:  codec
   Triage Stage:  Unreviewed  |  Has patch:  0
Needs documentation:  0   |Needs tests:  0
Patch needs improvement:  0   |  Easy pickings:  0
  UI/UX:  0   |
--+---
Changes (by kmtracey):

 * status:  new => closed
 * needs_better_patch:   => 0
 * needs_tests:   => 0
 * needs_docs:   => 0
 * resolution:   => invalid


Old description:

> TemplateSyntaxError at /admin/restaurant/restaurant/
>
> Caught UnicodeEncodeError while rendering: 'ascii' codec can't encode
> characters in position 0-7: ordinal not in range(128)
>
> Request Method: GET
> Request URL: http://127.0.0.1:8000/admin/restaurant/restaurant/
> Django Version: 1.3
> Exception Type: TemplateSyntaxError
> Exception Value:
>
> Caught UnicodeEncodeError while rendering: 'ascii' codec can't encode
> characters in position 0-7: ordinal not in range(128)
>
> Exception Location: /usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
> packages/Django-1.3-py2.7.egg/django/utils/functional.py in __str_cast,
> line 209
> Python Executable:  /usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/bin/python
> Python Version: 2.7.1
> Python Path:
>
> ['/home/user/workspace/eshkin/eshkin',
>  '/home/user/workspace/eshkin/eshkin',
>  '/home/user/workspace/eshkin/eshkin',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
> packages/setuptools-0.6c11-py2.7.egg',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
> packages/pip-1.0.1-py2.7.egg',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
> packages/Django-1.3-py2.7.egg',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
> packages/MySQL_python-1.2.3-py2.7-linux-i686.egg',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
> packages/PIL-1.1.7-py2.7-linux-i686.egg',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
> packages/docutils-0.8-py2.7.egg',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python27.zip',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/plat-linux2',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/lib-tk',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/lib-old',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/lib-dynload',
>  '/usr/lib/python2.7',
>  '/usr/lib/python2.7/plat-linux2',
>  '/usr/lib/python2.7/lib-tk',
>  '/usr/lib/python2.7/site-
> packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
> packages']
>
> COMMENT: The error was discovered only at the opening of the
> administrative interface, please help

New description:

 {{{
 TemplateSyntaxError at /admin/restaurant/restaurant/

 Caught UnicodeEncodeError while rendering: 'ascii' codec can't encode
 characters in position 0-7: ordinal not in range(128)

 Request Method: GET
 Request URL: http://127.0.0.1:8000/admin/restaurant/restaurant/
 Django Version: 1.3
 Exception Type: TemplateSyntaxError
 Exception Value:

 Caught UnicodeEncodeError while rendering: 'ascii' codec can't encode
 characters in position 0-7: ordinal not in range(128)

 Exception Location: /usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/Django-1.3-py2.7.egg/django/utils/functional.py in __str_cast,
 line 209
 Python Executable:  /usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/bin/python
 Python Version: 2.7.1
 Python Path:

 ['/home/user/workspace/eshkin/eshkin',
  '/home/user/workspace/eshkin/eshkin',
  '/home/user/workspace/eshkin/eshkin',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/setuptools-0.6c11-py2.7.egg',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/pip-1.0.1-py2.7.egg',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/Django-1.3-py2.7.egg',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1

Re: [Django] #15672: wsgi handler bug in 1.3

2011-07-29 Thread Django
#15672: wsgi handler bug in 1.3
-+-
   Reporter:  vkryachko  |  Owner:  vkryachko
   Type:  Bug| Status:  closed
  Milestone: |  Component:  Core (Other)
Version:  1.3|   Severity:  Release blocker
 Resolution:  fixed  |   Keywords:
   Triage Stage:  Accepted   |  Has patch:  1
Needs documentation:  0  |Needs tests:  0
Patch needs improvement:  0  |  Easy pickings:  0
  UI/UX:  0  |
-+-
Changes (by kinpoo):

 * cc: kinpoo (added)
 * ui_ux:   => 0


Comment:

 1. I think it might be handle as a bad URL and output 404 not found, but
 not 400 bad request.

 2. Sometimes, add some unnecessary information in URL for SEO reason,
 example: "/123-外贸", encoded as "/123-%E5%A4%96%E8%B4%B8", if it broken,
 looks like "/123-%E5", I can also get the correct resource and redirect to
 correct url.

-- 
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] #16535: UnicodeEncodeError

2011-07-29 Thread Django
#16535: UnicodeEncodeError
--+---
 Reporter:  direct@…  |  Owner:  nobody
 Type:  Bug   | Status:  new
Milestone:|  Component:  contrib.admin
  Version:  1.3   |   Severity:  Normal
 Keywords:  codec |   Triage Stage:  Unreviewed
Has patch:  0 |  Easy pickings:  0
UI/UX:  0 |
--+---
 TemplateSyntaxError at /admin/restaurant/restaurant/

 Caught UnicodeEncodeError while rendering: 'ascii' codec can't encode
 characters in position 0-7: ordinal not in range(128)

 Request Method: GET
 Request URL: http://127.0.0.1:8000/admin/restaurant/restaurant/
 Django Version: 1.3
 Exception Type: TemplateSyntaxError
 Exception Value:

 Caught UnicodeEncodeError while rendering: 'ascii' codec can't encode
 characters in position 0-7: ordinal not in range(128)

 Exception Location: /usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/Django-1.3-py2.7.egg/django/utils/functional.py in __str_cast,
 line 209
 Python Executable:  /usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/bin/python
 Python Version: 2.7.1
 Python Path:

 ['/home/user/workspace/eshkin/eshkin',
  '/home/user/workspace/eshkin/eshkin',
  '/home/user/workspace/eshkin/eshkin',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/setuptools-0.6c11-py2.7.egg',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/pip-1.0.1-py2.7.egg',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/Django-1.3-py2.7.egg',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/MySQL_python-1.2.3-py2.7-linux-i686.egg',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/PIL-1.1.7-py2.7-linux-i686.egg',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages/docutils-0.8-py2.7.egg',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python27.zip',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/plat-linux2',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/lib-tk',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/lib-old',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/lib-dynload',
  '/usr/lib/python2.7',
  '/usr/lib/python2.7/plat-linux2',
  '/usr/lib/python2.7/lib-tk',
  '/usr/lib/python2.7/site-
 packages/virtualenv-1.6.1-py2.7.egg/ENVESHKIN/lib/python2.7/site-
 packages']

 COMMENT: The error was discovered only at the opening of the
 administrative interface, please help

-- 
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] #12990: New Field Type: JSONField

2011-07-29 Thread Django
#12990: New Field Type: JSONField
-+-
   Reporter:  paltman|  Owner:  nobody
   Type:  New| Status:  new
  feature|  Component:  Database layer
  Milestone: |  (models, ORM)
Version:  1.2-beta   |   Severity:  Normal
 Resolution: |   Keywords:
   Triage Stage:  Design |  Has patch:  1
  decision needed|Needs tests:  1
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  1  |
  UI/UX:  0  |
-+-

Comment (by radbrad182+djangoproject@…):

 JSON fields are also a great way to store basic, dynamic, typed data.
 Being able to store Key Value data in the DB would be useful:

 {{{
 class Key(models.Model):
user = models.ForeignKey(User)
name = models.CharField()
value = models.JSONField()

 user.key_set.create(name="an_integer", value=4)
 user.key_set.create(name="a_list", value=['a','b','c'])
 }}}

 Normally to get this kind of basic data typing you would need to store
 another field for value_type, and then parse manually.

 Arguing that this should be stored in a K/V store is not ideal as it adds
 dependency on another datastore type, and you lose out on
 user.key_set.get(name='something').

-- 
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] #3615: Can't define forward references in fixtures using MySQL with InnoDB

2011-07-29 Thread Django
#3615: Can't define forward references in fixtures using MySQL with InnoDB
-+-
   Reporter:  russellm   |  Owner:  nobody
   Type:  Bug| Status:  new
  Milestone: |  Component:  Database layer
Version:  SVN|  (models, ORM)
 Resolution: |   Severity:  Normal
   Triage Stage:  Accepted   |   Keywords:  mysql innodb myisam
Needs documentation:  0  |  reference fixture
Patch needs improvement:  1  |  Has patch:  1
  UI/UX:  0  |Needs tests:  0
 |  Easy pickings:  0
-+-

Comment (by jsdalton):

 @russelm - Okay, I've tried to address your concerns about the behavior of
 SET CONSTRAINTS in the following Python script:
 http://paste.pocoo.org/show/448792/ . To run, just create a Postgres
 database called "testdb" or change the dbname to something else in lines 5
 and 6.

 Basically we are trying to demonstrate the hypothesis that the SET
 CONSTRAINTS statements will in no way alter of affect the constraint
 policies on an existing table. In my script I tried running through SET
 CONSTRAINTS both inside and outside a transaction and at every step print
 the deferrability of an existing table column. No change whatsoever. I
 tried to throw a variety of things at it to ensure a thorough
 demonstration. The script should be pretty self explanatory.

 This pretty much demonstrates the behavior of SET CONSTRAINTS as described
 in the Postgresql docs. SET CONSTRAINTS only affects constraint checking
 within the given transaction; it has no affect on anything outside the
 transaction.

 If anyone remains unconvinced that SET CONSTRAINTS does not affect
 anything aside from constraint checks within the current transaction, let
 me know your objection and I'll attempt to demonstrate it. I believe this
 is the only remaining obstacle for this ticket to be committed.

-- 
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] #16534: DjangoTestSuiteRunner API makes re-use difficult.

2011-07-29 Thread Django
#16534: DjangoTestSuiteRunner API makes re-use difficult.
-+-
   Reporter: |  Owner:  tomchristie
  tomchristie| Status:  new
   Type: |  Component:  Testing framework
  Cleanup/optimization   |   Severity:  Normal
  Milestone: |   Keywords:
Version:  1.3|  Has patch:  1
 Resolution: |Needs tests:  1
   Triage Stage:  Accepted   |  Easy pickings:  1
Needs documentation:  1  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-

Comment (by tomchristie):

 Being able to override the test loader too would be even 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.



Re: [Django] #16534: DjangoTestSuiteRunner API makes re-use difficult.

2011-07-29 Thread Django
#16534: DjangoTestSuiteRunner API makes re-use difficult.
-+-
   Reporter: |  Owner:  tomchristie
  tomchristie| Status:  new
   Type: |  Component:  Testing framework
  Cleanup/optimization   |   Severity:  Normal
  Milestone: |   Keywords:
Version:  1.3|  Has patch:  1
 Resolution: |Needs tests:  1
   Triage Stage:  Accepted   |  Easy pickings:  1
Needs documentation:  1  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

 * stage:  Unreviewed => Accepted


-- 
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] #16534: DjangoTestSuiteRunner API makes re-use difficult.

2011-07-29 Thread Django
#16534: DjangoTestSuiteRunner API makes re-use difficult.
-+-
   Reporter: |  Owner:  tomchristie
  tomchristie| Status:  new
   Type: |  Component:  Testing framework
  Cleanup/optimization   |   Severity:  Normal
  Milestone: |   Keywords:
Version:  1.3|  Has patch:  1
 Resolution: |Needs tests:  1
   Triage Stage: |  Easy pickings:  1
  Unreviewed |
Needs documentation:  1  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

 * needs_docs:  0 => 1
 * needs_tests:  0 => 1


Comment:

 Sounds like a reasonable idea.

-- 
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] #16534: DjangoTestSuiteRunner API makes re-use difficult.

2011-07-29 Thread Django
#16534: DjangoTestSuiteRunner API makes re-use difficult.
-+-
   Reporter: |  Owner:  tomchristie
  tomchristie| Status:  new
   Type: |  Component:  Testing framework
  Cleanup/optimization   |   Severity:  Normal
  Milestone: |   Keywords:
Version:  1.3|  Has patch:  1
 Resolution: |Needs tests:  0
   Triage Stage: |  Easy pickings:  1
  Unreviewed |
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by tomchristie):

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


Comment:

 NB: Note the same pattern in unittest2 -
 http://hg.python.org/unittest2/file/d2be68aedc8e/unittest2/runner.py#l129

-- 
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] #16534: DjangoTestSuiteRunner API makes re-use difficult.

2011-07-29 Thread Django
#16534: DjangoTestSuiteRunner API makes re-use difficult.
--+---
 Reporter:  tomchristie   |  Owner:  tomchristie
 Type:  Cleanup/optimization  | Status:  new
Milestone:|  Component:  Testing framework
  Version:  1.3   |   Severity:  Normal
 Keywords:|   Triage Stage:  Unreviewed
Has patch:  1 |  Easy pickings:  1
UI/UX:  0 |
--+---
 Would be better if it allowed the test suite class and test runner class
 to be overridden.

-- 
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] #14288: Template filter: linebreaksbr doesn't normalize newlines

2011-07-29 Thread Django
#14288: Template filter: linebreaksbr doesn't normalize newlines
-+-
   Reporter: |  Owner:  nobody
  michiel_1981   | Status:  closed
   Type:  Bug|  Component:  Template system
  Milestone: |   Severity:  Normal
Version:  SVN|   Keywords:
 Resolution:  fixed  |  Has patch:  1
   Triage Stage:  Ready for  |Needs tests:  0
  checkin|  Easy pickings:  0
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16573]:
 {{{
 #!CommitTicketReference repository="" revision="16573"
 Fixed #14288 -- Fixed linebreaksbr template filter to normalize newlines
 first. Thanks, Julien Phalip.
 }}}

-- 
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.



[Changeset] r16573 - in django/trunk: django/template django/utils tests/regressiontests/defaultfilters

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 03:22:25 -0700 (Fri, 29 Jul 2011)
New Revision: 16573

Modified:
   django/trunk/django/template/defaultfilters.py
   django/trunk/django/utils/html.py
   django/trunk/tests/regressiontests/defaultfilters/tests.py
Log:
Fixed #14288 -- Fixed linebreaksbr template filter to normalize newlines first. 
Thanks, Julien Phalip.

Modified: django/trunk/django/template/defaultfilters.py
===
--- django/trunk/django/template/defaultfilters.py  2011-07-29 10:20:16 UTC 
(rev 16572)
+++ django/trunk/django/template/defaultfilters.py  2011-07-29 10:22:25 UTC 
(rev 16573)
@@ -19,6 +19,7 @@
 from django.utils.safestring import mark_safe, SafeData, mark_for_escaping
 from django.utils.timesince import timesince, timeuntil
 from django.utils.translation import ugettext, ungettext
+from django.utils.text import normalize_newlines
 
 register = Library()
 
@@ -421,13 +422,16 @@
 return mark_safe(linebreaks(value, autoescape))
 linebreaks_filter.is_safe = True
 linebreaks_filter.needs_autoescape = True
+linebreaks = stringfilter(linebreaks)
 
 def linebreaksbr(value, autoescape=None):
 """
 Converts all newlines in a piece of plain text to HTML line breaks
 ().
 """
-if autoescape and not isinstance(value, SafeData):
+autoescape = autoescape and not isinstance(value, SafeData)
+value = normalize_newlines(value)
+if autoescape:
 value = escape(value)
 return mark_safe(value.replace('\n', ''))
 linebreaksbr.is_safe = True

Modified: django/trunk/django/utils/html.py
===
--- django/trunk/django/utils/html.py   2011-07-29 10:20:16 UTC (rev 16572)
+++ django/trunk/django/utils/html.py   2011-07-29 10:22:25 UTC (rev 16573)
@@ -7,6 +7,7 @@
 from django.utils.encoding import force_unicode
 from django.utils.functional import allow_lazy
 from django.utils.http import urlquote
+from django.utils.text import normalize_newlines
 
 # Configuration for urlize() function.
 LEADING_PUNCTUATION  = ['(', '<', '<']
@@ -70,7 +71,7 @@
 
 def linebreaks(value, autoescape=False):
 """Converts newlines into  and s."""
-value = re.sub(r'\r\n|\r|\n', '\n', force_unicode(value)) # normalize 
newlines
+value = normalize_newlines(value)
 paras = re.split('\n{2,}', value)
 if autoescape:
 paras = [u'%s' % escape(p).replace('\n', '') for p in 
paras]

Modified: django/trunk/tests/regressiontests/defaultfilters/tests.py
===
--- django/trunk/tests/regressiontests/defaultfilters/tests.py  2011-07-29 
10:20:16 UTC (rev 16572)
+++ django/trunk/tests/regressiontests/defaultfilters/tests.py  2011-07-29 
10:22:25 UTC (rev 16573)
@@ -266,7 +266,19 @@
 self.assertEqual(linebreaks(u'line 1'), u'line 1')
 self.assertEqual(linebreaks(u'line 1\nline 2'),
   u'line 1line 2')
+self.assertEqual(linebreaks(u'line 1\rline 2'),
+  u'line 1line 2')
+self.assertEqual(linebreaks(u'line 1\r\nline 2'),
+  u'line 1line 2')
 
+def test_linebreaksbr(self):
+self.assertEqual(linebreaksbr(u'line 1\nline 2'),
+  u'line 1line 2')
+self.assertEqual(linebreaksbr(u'line 1\rline 2'),
+  u'line 1line 2')
+self.assertEqual(linebreaksbr(u'line 1\r\nline 2'),
+  u'line 1line 2')
+
 def test_removetags(self):
 self.assertEqual(removetags(u'some html with alert'\
 u'("You smell") disallowed  tags', 'script img'),

-- 
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.



[Changeset] r16572 - in django/trunk: . django/contrib/localflavor/mx docs/ref/contrib tests/regressiontests/forms tests/regressiontests/forms/localflavor tests/regressiontests/forms/tests tests/regr

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 03:20:16 -0700 (Fri, 29 Jul 2011)
New Revision: 16572

Added:
   django/trunk/django/contrib/localflavor/mx/models.py
   django/trunk/tests/regressiontests/forms/localflavor/mx.py
   django/trunk/tests/regressiontests/localflavor/mx/
   django/trunk/tests/regressiontests/localflavor/mx/__init__.py
   django/trunk/tests/regressiontests/localflavor/mx/forms.py
   django/trunk/tests/regressiontests/localflavor/mx/models.py
   django/trunk/tests/regressiontests/localflavor/mx/tests.py
Modified:
   django/trunk/AUTHORS
   django/trunk/django/contrib/localflavor/mx/forms.py
   django/trunk/django/contrib/localflavor/mx/mx_states.py
   django/trunk/docs/ref/contrib/localflavor.txt
   django/trunk/tests/regressiontests/forms/localflavortests.py
   django/trunk/tests/regressiontests/forms/tests/__init__.py
   django/trunk/tests/regressiontests/localflavor/mk/models.py
   django/trunk/tests/regressiontests/localflavor/tests.py
   django/trunk/tests/regressiontests/localflavor/us/forms.py
   django/trunk/tests/regressiontests/localflavor/us/models.py
Log:
Fixed #16497 -- Added new form and model fields to the Mexican local flavor. 
Many thanks to Andr?\195?\169s Torres Marroqu?\195?\173n and Gerardo Orozco.

Modified: django/trunk/AUTHORS
===
--- django/trunk/AUTHORS2011-07-29 09:48:05 UTC (rev 16571)
+++ django/trunk/AUTHORS2011-07-29 10:20:16 UTC (rev 16572)
@@ -340,6 +340,7 @@
 Nuno Mariz 
 m...@junklight.com
 Orestis Markou 
+Andrés Torres Marroquín 
 Takashi Matsuo 
 Zlatko Mašek 
 Yasushi Masuda 
@@ -380,6 +381,7 @@
 Neal Norwitz 
 Todd O'Bryan 
 Selwin Ong 
+Gerardo Orozco 
 Christian Oudard 
 oggie rob 
 oggy 

Modified: django/trunk/django/contrib/localflavor/mx/forms.py
===
--- django/trunk/django/contrib/localflavor/mx/forms.py 2011-07-29 09:48:05 UTC 
(rev 16571)
+++ django/trunk/django/contrib/localflavor/mx/forms.py 2011-07-29 10:20:16 UTC 
(rev 16572)
@@ -1,14 +1,225 @@
+# -*- coding: utf-8 -*-
 """
 Mexican-specific form helpers.
 """
+import re
 
-from django.forms.fields import Select
+from django.forms import ValidationError
+from django.forms.fields import Select, RegexField
+from django.utils.translation import ugettext_lazy as _
+from django.core.validators import EMPTY_VALUES
+from django.contrib.localflavor.mx.mx_states import STATE_CHOICES
 
+DATE_RE = 
r'\d{2}((01|03|05|07|08|10|12)(0[1-9]|[12]\d|3[01])|02(0[1-9]|[12]\d)|(04|06|09|11)(0[1-9]|[12]\d|30))'
+
+"""
+This is the list of inconvenient words according to the `Anexo IV` of the
+document described in the next link:
+
http://www.sisi.org.mx/jspsi/documentos/2005/seguimiento/06101/0610100162005_065.doc
+"""
+
+RFC_INCONVENIENT_WORDS = [
+u'BUEI', u'BUEY', u'CACA', u'CACO', u'CAGA', u'CAGO', u'CAKA', u'CAKO',
+u'COGE', u'COJA', u'COJE', u'COJI', u'COJO', u'CULO', u'FETO', u'GUEY',
+u'JOTO', u'KACA', u'KACO', u'KAGA', u'KAGO', u'KOGE', u'KOJO', u'KAKA',
+u'KULO', u'MAME', u'MAMO', u'MEAR', u'MEAS', u'MEON', u'MION', u'MOCO',
+u'MULA', u'PEDA', u'PEDO', u'PENE', u'PUTA', u'PUTO', u'QULO', u'RATA',
+u'RUIN',
+]
+
+"""
+This is the list of inconvenient words according to the `Anexo 2` of the
+document described in the next link:
+
http://portal.veracruz.gob.mx/pls/portal/url/ITEM/444112558A57C6E0E040A8C02E00695C
+"""
+CURP_INCONVENIENT_WORDS = [
+   u'BACA', u'BAKA', u'BUEI', u'BUEY', u'CACA', u'CACO', u'CAGA', u'CAGO',
+   u'CAKA', u'CAKO', u'COGE', u'COGI', u'COJA', u'COJE', u'COJI', u'COJO',
+   u'COLA', u'CULO', u'FALO', u'FETO', u'GETA', u'GUEI', u'GUEY', u'JETA',
+   u'JOTO', u'KACA', u'KACO', u'KAGA', u'KAGO', u'KAKA', u'KAKO', u'KOGE',
+   u'KOGI', u'KOJA', u'KOJE', u'KOJI', u'KOJO', u'KOLA', u'KULO', u'LILO',
+   u'LOCA', u'LOCO', u'LOKA', u'LOKO', u'MAME', u'MAMO', u'MEAR', u'MEAS',
+   u'MEON', u'MIAR', u'MION', u'MOCO', u'MOKO', u'MULA', u'MULO', u'NACA',
+   u'NACO', u'PEDA', u'PEDO', u'PENE', u'PIPI', u'PITO', u'POPO', u'PUTA',
+   u'PUTO', u'QULO', u'RATA', u'ROBA', u'ROBE', u'ROBO', u'RUIN', u'SENO',
+   u'TETA', u'VACA', u'VAGA', u'VAGO', u'VAKA', u'VUEI', u'VUEY', u'WUEI',
+   u'WUEY',
+]
+
 class MXStateSelect(Select):
 """
 A Select widget that uses a list of Mexican states as its choices.
 """
 def __init__(self, attrs=None):
-from mx_states import STATE_CHOICES
 super(MXStateSelect, self).__init__(attrs, choices=STATE_CHOICES)
 
+
+class MXZipCodeField(RegexField):
+"""
+A form field that accepts a Mexican Zip Code.
+
+More info about this:
+http://en.wikipedia.org/wiki/List_of_postal_codes_in_Mexico
+"""
+default_error_messages = {
+'invalid': _(u'Enter a valid zip code in the format X.'),
+}
+
+def __init__(self, *args, **kwargs):
+zip_code_re = ur'^(0[1-9]|[1][0-6]|[2-9]\

Re: [Django] #16497: Adding MXFields to contrib.localflavor

2011-07-29 Thread Django
#16497: Adding MXFields to contrib.localflavor
-+-
   Reporter:  srpoder|  Owner:  nobody
   Type:  New| Status:  closed
  feature|  Component:  contrib.localflavor
  Milestone:  1.4|   Severity:  Normal
Version:  1.3|   Keywords:  mexican localflavor
 Resolution:  fixed  |  Has patch:  1
   Triage Stage:  Accepted   |Needs tests:  0
Needs documentation:  1  |  Easy pickings:  0
Patch needs improvement:  1  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16572]:
 {{{
 #!CommitTicketReference repository="" revision="16572"
 Fixed #16497 -- Added new form and model fields to the Mexican local
 flavor. Many thanks to Andrés Torres Marroquín and Gerardo Orozco.
 }}}

-- 
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.



[Changeset] r16571 - in django/branches/releases/1.3.X/django: contrib/gis/db/backends views/generic

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:48:05 -0700 (Fri, 29 Jul 2011)
New Revision: 16571

Modified:
   django/branches/releases/1.3.X/django/contrib/gis/db/backends/base.py
   django/branches/releases/1.3.X/django/views/generic/dates.py
Log:
[1.3.X] Fixed #16531 -- Fixed various instances of "undefined name" issues. 
Thanks, Bruno Reni?\195?\169.

Backport from trunk (r16557).

Modified: django/branches/releases/1.3.X/django/contrib/gis/db/backends/base.py
===
--- django/branches/releases/1.3.X/django/contrib/gis/db/backends/base.py   
2011-07-29 09:41:14 UTC (rev 16570)
+++ django/branches/releases/1.3.X/django/contrib/gis/db/backends/base.py   
2011-07-29 09:48:05 UTC (rev 16571)
@@ -122,7 +122,7 @@
 raise NotImplementedError('Aggregate support not implemented for this 
spatial backend.')
 
 def spatial_lookup_sql(self, lvalue, lookup_type, value, field):
-raise NotImplmentedError
+raise NotImplementedError
 
 # Routines for getting the OGC-compliant models.
 def geometry_columns(self):

Modified: django/branches/releases/1.3.X/django/views/generic/dates.py
===
--- django/branches/releases/1.3.X/django/views/generic/dates.py
2011-07-29 09:41:14 UTC (rev 16570)
+++ django/branches/releases/1.3.X/django/views/generic/dates.py
2011-07-29 09:48:05 UTC (rev 16571)
@@ -211,9 +211,9 @@
 
 date_list = queryset.dates(date_field, date_type)[::-1]
 if date_list is not None and not date_list and not allow_empty:
-raise Http404(_(u"No %(verbose_name_plural)s available") % {
-'verbose_name_plural': 
force_unicode(qs.model._meta.verbose_name_plural)
-})
+name = force_unicode(queryset.model._meta.verbose_name_plural)
+raise Http404(_(u"No %(verbose_name_plural)s available") %
+  {'verbose_name_plural': name})
 
 return date_list
 

-- 
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] #16531: [patch] fix various "undefined name" issues

2011-07-29 Thread Django
#16531: [patch] fix various "undefined name" issues
-+-
   Reporter:  brutasse   |  Owner:  nobody
   Type: | Status:  closed
  Cleanup/optimization   |  Component:  Core (Other)
  Milestone: |   Severity:  Normal
Version:  1.3|   Keywords:
 Resolution:  fixed  |  Has patch:  1
   Triage Stage:  Ready for  |Needs tests:  0
  checkin|  Easy pickings:  0
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-

Comment (by jezdez):

 In [16571]:
 {{{
 #!CommitTicketReference repository="" revision="16571"
 [1.3.X] Fixed #16531 -- Fixed various instances of "undefined name"
 issues. Thanks, Bruno Renié.

 Backport from trunk (r16557).
 }}}

-- 
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] #8013: Localflavor for Colombia and Ecuador

2011-07-29 Thread Django
#8013: Localflavor for Colombia and Ecuador
-+-
   Reporter:  ikks   |  Owner:  nobody
   Type:  New| Status:  closed
  feature|  Component:  contrib.localflavor
  Milestone: |   Severity:  Normal
Version:  SVN|   Keywords:  Colombia Ecuador
 Resolution:  fixed  |  Has patch:  1
   Triage Stage:  Ready for  |Needs tests:  0
  checkin|  Easy pickings:  0
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16570]:
 {{{
 #!CommitTicketReference repository="" revision="16570"
 Fixed #8013 -- Added Columbian and Ecuadorian local flavor. Thanks, ikks
 and Bernhard Essl.
 }}}

-- 
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.



[Changeset] r16570 - in django/trunk: django/contrib/localflavor django/contrib/localflavor/co django/contrib/localflavor/ec docs/ref/contrib tests/regressiontests/forms tests/regressiontests/forms/l

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:41:14 -0700 (Fri, 29 Jul 2011)
New Revision: 16570

Added:
   django/trunk/django/contrib/localflavor/co/
   django/trunk/django/contrib/localflavor/co/__init__.py
   django/trunk/django/contrib/localflavor/co/co_departments.py
   django/trunk/django/contrib/localflavor/co/forms.py
   django/trunk/django/contrib/localflavor/ec/
   django/trunk/django/contrib/localflavor/ec/__init__.py
   django/trunk/django/contrib/localflavor/ec/ec_provinces.py
   django/trunk/django/contrib/localflavor/ec/forms.py
   django/trunk/tests/regressiontests/forms/localflavor/co.py
   django/trunk/tests/regressiontests/forms/localflavor/ec.py
Modified:
   django/trunk/docs/ref/contrib/localflavor.txt
   django/trunk/tests/regressiontests/forms/localflavortests.py
   django/trunk/tests/regressiontests/forms/tests/__init__.py
Log:
Fixed #8013 -- Added Columbian and Ecuadorian local flavor. Thanks, ikks and 
Bernhard Essl.

Added: django/trunk/django/contrib/localflavor/co/__init__.py
===
Added: django/trunk/django/contrib/localflavor/co/co_departments.py
===
--- django/trunk/django/contrib/localflavor/co/co_departments.py
(rev 0)
+++ django/trunk/django/contrib/localflavor/co/co_departments.py
2011-07-29 09:41:14 UTC (rev 16570)
@@ -0,0 +1,44 @@
+# -*- coding: utf-8 -*-
+"""
+A list of Colombian departaments as `choices` in a
+formfield.
+
+This exists in this standalone file so that it's only
+imported into memory when explicitly needed.
+"""
+
+DEPARTMENT_CHOICES = (
+('AMA', u'Amazonas'),
+('ANT', u'Antioquia'),
+('ARA', u'Arauca'),
+('ATL', u'Atlántico'),
+('DC',  u'Bogotá'),
+('BOL', u'Bolívar'),
+('BOY', u'Boyacá'),
+('CAL', u'Caldas'),
+('CAQ', u'Caquetá'),
+('CAS', u'Casanare'),
+('CAU', u'Cauca'),
+('CES', u'Cesar'),
+('CHO', u'Chocó'),
+('COR', u'Córdoba'),
+('CUN', u'Cundinamarca'),
+('GUA', u'Guainía'),
+('GUV', u'Guaviare'),
+('HUI', u'Huila'),
+('LAG', u'La Guajira'),
+('MAG', u'Magdalena'),
+('MET', u'Meta'),
+('NAR', u'Nariño'),
+('NSA', u'Norte de Santander'),
+('PUT', u'Putumayo'),
+('QUI', u'Quindío'),
+('RIS', u'Risaralda'),
+('SAP', u'San Andrés and Providencia'),
+('SAN', u'Santander'),
+('SUC', u'Sucre'),
+('TOL', u'Tolima'),
+('VAC', u'Valle del Cauca'),
+('VAU', u'Vaupés'),
+('VID', u'Vichada'),
+)

Added: django/trunk/django/contrib/localflavor/co/forms.py
===
--- django/trunk/django/contrib/localflavor/co/forms.py 
(rev 0)
+++ django/trunk/django/contrib/localflavor/co/forms.py 2011-07-29 09:41:14 UTC 
(rev 16570)
@@ -0,0 +1,13 @@
+"""
+Colombian-specific form helpers.
+"""
+
+from django.forms.fields import Select
+
+class CODepartmentSelect(Select):
+"""
+A Select widget that uses a list of Colombian states as its choices.
+"""
+def __init__(self, attrs=None):
+from co_departments import DEPARTMENT_CHOICES
+super(CODepartmentSelect, self).__init__(attrs, 
choices=DEPARTMENT_CHOICES)

Added: django/trunk/django/contrib/localflavor/ec/__init__.py
===
Added: django/trunk/django/contrib/localflavor/ec/ec_provinces.py
===
--- django/trunk/django/contrib/localflavor/ec/ec_provinces.py  
(rev 0)
+++ django/trunk/django/contrib/localflavor/ec/ec_provinces.py  2011-07-29 
09:41:14 UTC (rev 16570)
@@ -0,0 +1,35 @@
+# -*- coding: utf-8 -*-
+"""
+A list of Ecuador departaments as `choices` in a
+formfield.
+
+This exists in this standalone file so that it's only
+imported into memory when explicitly needed.
+"""
+
+PROVINCE_CHOICES = (
+('A', u'Azuay'),
+('B', u'Bolívar'),
+('F', u'Cañar'),
+('C', u'Carchi'),
+('H', u'Chimborazo'),
+('X', u'Cotopaxi'),
+('O', u'El Oro'),
+('E', u'Esmeraldas'),
+('W', u'Galápagos'),
+('G', u'Guayas'),
+('I', u'Imbabura'),
+('L', u'Loja'),
+('R', u'Los Ríos'),
+('M', u'Manabí'),
+('S', u'Morona Santiago'),
+('N', u'Napo'),
+('D', u'Orellana'),
+('Y', u'Pastaza'),
+('P', u'Pichincha'),
+('SE', u'Santa Elena'),
+('SD', u'Santo Domingo de los Tsáchilas'),
+('U', u'Sucumbíos'),
+('T', u'Tungurahua'),
+('Z', u'Zamora Chinchipe'),
+)

Added: django/trunk/django/contrib/localflavor/ec/forms.py
===
--- django/trunk/django/contrib/localflavor/ec/forms.py 
(rev 0)
+++ django/trunk/django/contrib/localflavor/ec/forms.py 2011-07-29 09:41:14 UTC 
(rev 16570)
@@ -0,0 +1,13 @@
+"""
+Ecuador-specific form helpers.
+"""
+

[Changeset] r16569 - in django/trunk: django/views/generic docs/ref docs/releases tests/regressiontests/generic_views

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:41:00 -0700 (Fri, 29 Jul 2011)
New Revision: 16569

Modified:
   django/trunk/django/views/generic/detail.py
   django/trunk/docs/ref/class-based-views.txt
   django/trunk/docs/releases/1.4.txt
   django/trunk/tests/regressiontests/generic_views/detail.py
   django/trunk/tests/regressiontests/generic_views/urls.py
Log:
Fixed #16101 -- Added parameters to SingleObjectMixin to override the name of 
the URL keyword arguments used for pk and slug. Thanks, Andrew Ingram and 
Julien Phalip.

Modified: django/trunk/django/views/generic/detail.py
===
--- django/trunk/django/views/generic/detail.py 2011-07-29 09:40:50 UTC (rev 
16568)
+++ django/trunk/django/views/generic/detail.py 2011-07-29 09:41:00 UTC (rev 
16569)
@@ -13,6 +13,8 @@
 queryset = None
 slug_field = 'slug'
 context_object_name = None
+slug_url_kwarg = 'slug'
+pk_url_kwarg = 'pk'
 
 def get_object(self, queryset=None):
 """
@@ -27,8 +29,8 @@
 queryset = self.get_queryset()
 
 # Next, try looking up by primary key.
-pk = self.kwargs.get('pk', None)
-slug = self.kwargs.get('slug', None)
+pk = self.kwargs.get(self.pk_url_kwarg, None)
+slug = self.kwargs.get(self.slug_url_kwarg, None)
 if pk is not None:
 queryset = queryset.filter(pk=pk)
 

Modified: django/trunk/docs/ref/class-based-views.txt
===
--- django/trunk/docs/ref/class-based-views.txt 2011-07-29 09:40:50 UTC (rev 
16568)
+++ django/trunk/docs/ref/class-based-views.txt 2011-07-29 09:41:00 UTC (rev 
16569)
@@ -136,6 +136,20 @@
 The name of the field on the model that contains the slug. By default,
 ``slug_field`` is ``'slug'``.
 
+.. attribute:: slug_url_kwarg
+
+.. versionadded:: 1.4
+
+The name of the URLConf keyword argument that contains the slug. By
+default, ``slug_url_kwarg`` is ``'slug'``.
+
+.. attribute:: pk_url_kwarg
+
+.. versionadded:: 1.4
+
+The name of the URLConf keyword argument that contains the primary key.
+By default, ``pk_url_kwarg`` is ``'pk'``.
+
 .. attribute:: context_object_name
 
 Designates the name of the variable to use in the context.
@@ -146,10 +160,11 @@
 ``queryset`` is provided, that queryset will be used as the
 source of objects; otherwise,
 :meth:`~SingleObjectMixin.get_queryset` will be used.
-:meth:`~SingleObjectMixin.get_object` looks for a ``pk``
-argument in the arguments to the view; if ``pk`` is found,
-this method performs a primary-key based lookup using that
-value. If no ``pk`` argument is found, it looks for a ``slug``
+``get_object()`` looks for a
+:attr:`SingleObjectMixin.pk_url_kwarg` argument in the arguments
+to the view; if this argument is found, this method performs a
+primary-key based lookup using that value. If this argument is not
+found, it looks for a :attr:`SingleObjectMixin.slug_url_kwarg`
 argument, and performs a slug lookup using the
 :attr:`SingleObjectMixin.slug_field`.
 

Modified: django/trunk/docs/releases/1.4.txt
===
--- django/trunk/docs/releases/1.4.txt  2011-07-29 09:40:50 UTC (rev 16568)
+++ django/trunk/docs/releases/1.4.txt  2011-07-29 09:41:00 UTC (rev 16569)
@@ -153,6 +153,16 @@
 sequence ("..."). See the :tfilter:`truncatechars docs ` for
 more details.
 
+Customizable ``SingleObjectMixin`` URLConf kwargs
+~
+
+Two new attributes,
+:attr:`pk_url_kwarg`
 and
+:attr:`slug_url_kwarg`,
+have been added to :class:`django.views.generic.detail.SingleObjectMixin` to
+enable the customization of URLConf keyword arguments used for single
+object generic views.
+
 CSRF improvements
 ~
 

Modified: django/trunk/tests/regressiontests/generic_views/detail.py
===
--- django/trunk/tests/regressiontests/generic_views/detail.py  2011-07-29 
09:40:50 UTC (rev 16568)
+++ django/trunk/tests/regressiontests/generic_views/detail.py  2011-07-29 
09:41:00 UTC (rev 16569)
@@ -21,6 +21,13 @@
 self.assertEqual(res.context['author'], Author.objects.get(pk=1))
 self.assertTemplateUsed(res, 'generic_views/author_detail.html')
 
+def test_detail_by_custom_pk(self):
+res = self.client.get('/detail/author/bycustompk/1/')
+self.assertEqual(res.status_code, 200)
+self.assertEqual(res.context['object'], Author.objects.get(pk=1))
+self.assertEqual(res.context['author'], Author.objects.get(pk=1))
+self.assertTemplateUsed(res, 'generic_views/author_detail.html')
+
 def test_detail_by_slug(self):
 res = self.client.get('/detail/author/bys

Re: [Django] #16101: SingleObjectMixin should accept parameters for overriding the URL keywords for pk and slug

2011-07-29 Thread Django
#16101: SingleObjectMixin should accept parameters for overriding the URL 
keywords
for pk and slug
-+-
   Reporter: |  Owner:  nobody
  AndrewIngram   | Status:  closed
   Type:  New|  Component:  Generic views
  feature|   Severity:  Normal
  Milestone: |   Keywords:
Version:  1.3|  Has patch:  1
 Resolution:  fixed  |Needs tests:  0
   Triage Stage:  Ready for  |  Easy pickings:  0
  checkin|
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16569]:
 {{{
 #!CommitTicketReference repository="" revision="16569"
 Fixed #16101 -- Added parameters to SingleObjectMixin to override the name
 of the URL keyword arguments used for pk and slug. Thanks, Andrew Ingram
 and Julien Phalip.
 }}}

-- 
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] #16326: Un-pickled TemplateResponse objects can't be re-pickled

2011-07-29 Thread Django
#16326: Un-pickled TemplateResponse objects can't be re-pickled
-+-
   Reporter:  natrius|  Owner:  nobody
   Type:  Bug| Status:  closed
  Milestone: |  Component:  Template system
Version:  1.3|   Severity:  Normal
 Resolution:  fixed  |   Keywords:
   Triage Stage:  Ready for  |  Has patch:  1
  checkin|Needs tests:  0
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16568]:
 {{{
 #!CommitTicketReference repository="" revision="16568"
 Fixed #16326 -- Fixed re-pickling of unpickled TemplateResponse instances.
 Thanks, natrius and lrekucki.
 }}}

-- 
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.



[Changeset] r16568 - in django/trunk: django/template tests/regressiontests/templates

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:40:50 -0700 (Fri, 29 Jul 2011)
New Revision: 16568

Modified:
   django/trunk/django/template/response.py
   django/trunk/tests/regressiontests/templates/response.py
Log:
Fixed #16326 -- Fixed re-pickling of unpickled TemplateResponse instances. 
Thanks, natrius and lrekucki.

Modified: django/trunk/django/template/response.py
===
--- django/trunk/django/template/response.py2011-07-29 09:40:43 UTC (rev 
16567)
+++ django/trunk/django/template/response.py2011-07-29 09:40:50 UTC (rev 
16568)
@@ -1,22 +1,28 @@
 from django.http import HttpResponse
 from django.template import loader, Context, RequestContext
 
+
 class ContentNotRenderedError(Exception):
 pass
 
+
+class DiscardedAttributeError(AttributeError):
+pass
+
+
 class SimpleTemplateResponse(HttpResponse):
+rendering_attrs = ['template_name', 'context_data', 
'_post_render_callbacks']
 
 def __init__(self, template, context=None, mimetype=None, status=None,
 content_type=None):
 # It would seem obvious to call these next two members 'template' and
-# 'context', but those names are reserved as part of the test Client 
API.
-# To avoid the name collision, we use
-# tricky-to-debug problems
+# 'context', but those names are reserved as part of the test Client
+# API. To avoid the name collision, we use tricky-to-debug problems
 self.template_name = template
 self.context_data = context
 
-# _is_rendered tracks whether the template and context has been baked 
into
-# a final response.
+# _is_rendered tracks whether the template and context has been
+# baked into a final response.
 self._is_rendered = False
 
 self._post_render_callbacks = []
@@ -36,13 +42,21 @@
 """
 obj_dict = self.__dict__.copy()
 if not self._is_rendered:
-raise ContentNotRenderedError('The response content must be 
rendered before it can be pickled.')
-del obj_dict['template_name']
-del obj_dict['context_data']
-del obj_dict['_post_render_callbacks']
+raise ContentNotRenderedError('The response content must be '
+  'rendered before it can be pickled.')
+for attr in self.rendering_attrs:
+if attr in obj_dict:
+del obj_dict[attr]
 
 return obj_dict
 
+def __getattr__(self, name):
+if name in self.rendering_attrs:
+raise DiscardedAttributeError('The %s attribute was discarded '
+  'when this %s class was pickled.' %
+  (name, self.__class__.__name__))
+return super(SimpleTemplateResponse, self).__getattr__(name)
+
 def resolve_template(self, template):
 "Accepts a template object, path-to-template or list of paths"
 if isinstance(template, (list, tuple)):
@@ -53,7 +67,7 @@
 return template
 
 def resolve_context(self, context):
-"""Convert context data into a full Context object
+"""Converts context data into a full Context object
 (assuming it isn't already a Context object).
 """
 if isinstance(context, Context):
@@ -76,9 +90,10 @@
 return content
 
 def add_post_render_callback(self, callback):
-"""Add a new post-rendering callback.
+"""Adds a new post-rendering callback.
 
-If the response has already been rendered, invoke the callback 
immediately.
+If the response has already been rendered,
+invoke the callback immediately.
 """
 if self._is_rendered:
 callback(self)
@@ -86,7 +101,7 @@
 self._post_render_callbacks.append(callback)
 
 def render(self):
-"""Render (thereby finalizing) the content of the response.
+"""Renders (thereby finalizing) the content of the response.
 
 If the content has already been rendered, this is a no-op.
 
@@ -101,20 +116,25 @@
 retval = newretval
 return retval
 
-is_rendered = property(lambda self: self._is_rendered)
+@property
+def is_rendered(self):
+return self._is_rendered
 
 def __iter__(self):
 if not self._is_rendered:
-raise ContentNotRenderedError('The response content must be 
rendered before it can be iterated over.')
+raise ContentNotRenderedError('The response content must be '
+  'rendered before it can be iterated 
over.')
 return super(SimpleTemplateResponse, self).__iter__()
 
 def _get_content(self):
 if not self._is_rendered:
-raise ContentNotRenderedError('The response content must be 
rendered before it can be accessed.')
+raise ContentNotRenderedError('The response co

[Changeset] r16567 - django/trunk/docs/ref/contrib/admin

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:40:43 -0700 (Fri, 29 Jul 2011)
New Revision: 16567

Modified:
   django/trunk/docs/ref/contrib/admin/actions.txt
Log:
Fixed #16377 -- Fixed docs about how to disable the admin actions conditionally 
to match the current code. Thanks, Aymeric Augustin.

Modified: django/trunk/docs/ref/contrib/admin/actions.txt
===
--- django/trunk/docs/ref/contrib/admin/actions.txt 2011-07-29 09:40:35 UTC 
(rev 16566)
+++ django/trunk/docs/ref/contrib/admin/actions.txt 2011-07-29 09:40:43 UTC 
(rev 16567)
@@ -343,7 +343,8 @@
 def get_actions(self, request):
 actions = super(MyModelAdmin, self).get_actions(request)
 if request.user.username[0].upper() != 'J':
-del actions['delete_selected']
+if 'delete_selected' in actions:
+del actions['delete_selected']
 return actions
 
 

-- 
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] #16377: "Conditionally disabling actions" documentation needs updating

2011-07-29 Thread Django
#16377: "Conditionally disabling actions" documentation needs updating
-+-
   Reporter: |  Owner:  nobody
  pgullekson@…   | Status:  closed
   Type: |  Component:  Documentation
  Cleanup/optimization   |   Severity:  Normal
  Milestone: |   Keywords:
Version:  1.3|  Has patch:  1
 Resolution:  fixed  |Needs tests:  0
   Triage Stage:  Ready for  |  Easy pickings:  1
  checkin|
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16567]:
 {{{
 #!CommitTicketReference repository="" revision="16567"
 Fixed #16377 -- Fixed docs about how to disable the admin actions
 conditionally to match the current code. Thanks, Aymeric Augustin.
 }}}

-- 
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.



[Changeset] r16566 - django/trunk/docs/ref

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:40:35 -0700 (Fri, 29 Jul 2011)
New Revision: 16566

Modified:
   django/trunk/docs/ref/class-based-views.txt
Log:
Fixed #16394 -- Corrected documentation of the allow_empty option of the 
BaseDateListView view. Thanks, Aymeric Augustin.

Modified: django/trunk/docs/ref/class-based-views.txt
===
--- django/trunk/docs/ref/class-based-views.txt 2011-07-29 09:40:28 UTC (rev 
16565)
+++ django/trunk/docs/ref/class-based-views.txt 2011-07-29 09:40:35 UTC (rev 
16566)
@@ -775,9 +775,9 @@
 .. attribute:: allow_empty
 
 A boolean specifying whether to display the page if no objects are
-available. If this is ``False`` and no objects are available, the view
-will raise a 404 instead of displaying an empty page. By default, this
-is ``True``.
+available. If this is ``True`` and no objects are available, the view
+will display an empty page instead of raising a 404. By default, this
+is ``False``.
 
 .. method:: get_dated_items():
 

-- 
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] #16394: BaseDateListView has allow_empty = False, documentation claims allow_empty = True

2011-07-29 Thread Django
#16394: BaseDateListView has allow_empty = False, documentation claims 
allow_empty
= True
-+-
   Reporter: |  Owner:  nobody
  r.tirrell@…| Status:  closed
   Type:  Bug|  Component:  Documentation
  Milestone: |   Severity:  Normal
Version:  1.3|   Keywords:
 Resolution:  fixed  |  Has patch:  1
   Triage Stage:  Ready for  |Needs tests:  0
  checkin|  Easy pickings:  1
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16566]:
 {{{
 #!CommitTicketReference repository="" revision="16566"
 Fixed #16394 -- Corrected documentation of the allow_empty option of the
 BaseDateListView view. Thanks, Aymeric Augustin.
 }}}

-- 
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] #16437: Outdated comment

2011-07-29 Thread Django
#16437: Outdated comment
-+-
   Reporter:  jonash |  Owner:  teraom
   Type: | Status:  closed
  Cleanup/optimization   |  Component:  Testing framework
  Milestone: |   Severity:  Normal
Version:  1.3|   Keywords:  minor
 Resolution:  fixed  |  Has patch:  1
   Triage Stage:  Ready for  |Needs tests:  0
  checkin|  Easy pickings:  1
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16565]:
 {{{
 #!CommitTicketReference repository="" revision="16565"
 Fixed #16437 -- Removed old code comment from testcases module. Thanks,
 teraom.
 }}}

-- 
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.



[Changeset] r16565 - django/trunk/django/test

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:40:28 -0700 (Fri, 29 Jul 2011)
New Revision: 16565

Modified:
   django/trunk/django/test/testcases.py
Log:
Fixed #16437 -- Removed old code comment from testcases module. Thanks, teraom.

Modified: django/trunk/django/test/testcases.py
===
--- django/trunk/django/test/testcases.py   2011-07-29 09:40:22 UTC (rev 
16564)
+++ django/trunk/django/test/testcases.py   2011-07-29 09:40:28 UTC (rev 
16565)
@@ -544,7 +544,6 @@
 if func is None:
 return context
 
-# Basically emulate the `with` statement here.
 with context:
 func(*args, **kwargs)
 

-- 
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] #16467: Little typo in the Formset docu

2011-07-29 Thread Django
#16467: Little typo in the Formset docu
-+-
   Reporter: |  Owner:  teraom
  hannes.hapke@… | Status:  closed
   Type: |  Component:  Documentation
  Cleanup/optimization   |   Severity:  Normal
  Milestone: |   Keywords:  form inital value
Version:  1.3|  Has patch:  1
 Resolution:  fixed  |Needs tests:  0
   Triage Stage:  Ready for  |  Easy pickings:  0
  checkin|
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16564]:
 {{{
 #!CommitTicketReference repository="" revision="16564"
 Fixed #16467 -- Corrected formset code example. Thanks, teraom.
 }}}

-- 
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.



[Changeset] r16564 - django/trunk/docs/topics/forms

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:40:22 -0700 (Fri, 29 Jul 2011)
New Revision: 16564

Modified:
   django/trunk/docs/topics/forms/formsets.txt
Log:
Fixed #16467 -- Corrected formset code example. Thanks, teraom.

Modified: django/trunk/docs/topics/forms/formsets.txt
===
--- django/trunk/docs/topics/forms/formsets.txt 2011-07-29 09:40:15 UTC (rev 
16563)
+++ django/trunk/docs/topics/forms/formsets.txt 2011-07-29 09:40:22 UTC (rev 
16564)
@@ -59,10 +59,10 @@
 example::
 
 >>> ArticleFormSet = formset_factory(ArticleForm, extra=2)
->>> formset = ArticleFormSet(initial=[
-... {'title': u'Django is now open source',
-...  'pub_date': datetime.date.today()},
-... ])
+>>> formset = ArticleFormSet(initial={
+...  'title': u'Django is now open source',
+...  'pub_date': datetime.date.today(),
+... })
 
 >>> for form in formset:
 ... print form.as_table()

-- 
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.



[Changeset] r16563 - django/trunk/docs/ref

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:40:15 -0700 (Fri, 29 Jul 2011)
New Revision: 16563

Modified:
   django/trunk/docs/ref/class-based-views.txt
Log:
Fixed #16464 -- Fixed the reference docs of the DateDetailView view. Thanks, 
Julien Phalip.

Modified: django/trunk/docs/ref/class-based-views.txt
===
--- django/trunk/docs/ref/class-based-views.txt 2011-07-29 09:40:09 UTC (rev 
16562)
+++ django/trunk/docs/ref/class-based-views.txt 2011-07-29 09:40:15 UTC (rev 
16563)
@@ -1288,8 +1288,8 @@
 .. class:: TodayArchiveView()
 
 A day archive page showing all objects for *today*. This is exactly the
-same as ``archive_day``, except the ``year``/``month``/``day`` arguments
-are not used,
+same as :class:`django.views.generic.dates.DayArchiveView`, except today's
+date is used instead of the ``year``/``month``/``day`` arguments.
 
 :class:`~django.views.generic.dates.BaseTodayArchiveView` implements the
 same behavior as :class:`~django.views.generic.dates.TodayArchiveView`, but
@@ -1298,7 +1298,8 @@
 
 **Mixins**
 
-* :class:`django.views.generic.dates.DayArchiveView`
+* 
:class:`django.views.generic.list.MultipleObjectTemplateResponseMixin`
+* :class:`django.views.generic.dates.BaseDayArchiveView`
 
 DateDetailView
 ~~
@@ -1316,8 +1317,9 @@
 
 **Mixins**
 
-* 
:class:`django.views.generic.list.MultipleObjectTemplateResponseMixin`
+* 
:class:`django.views.generic.detail.SingleObjectTemplateResponseMixin`
+* :class:`django.views.generic.detail.BaseDetailView`
+* :class:`django.views.generic.dates.DateMixin`
 * :class:`django.views.generic.dates.YearMixin`
 * :class:`django.views.generic.dates.MonthMixin`
 * :class:`django.views.generic.dates.DayMixin`
-* :class:`django.views.generic.dates.BaseDateListView`

-- 
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] #16464: Ref for DateDetailView lists wrong mixins

2011-07-29 Thread Django
#16464: Ref for DateDetailView lists wrong mixins
-+-
   Reporter:  michal@…   |  Owner:  teraom
   Type:  Bug| Status:  closed
  Milestone: |  Component:  Documentation
Version:  SVN|   Severity:  Normal
 Resolution:  fixed  |   Keywords:
   Triage Stage:  Ready for  |  Has patch:  1
  checkin|Needs tests:  0
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16563]:
 {{{
 #!CommitTicketReference repository="" revision="16563"
 Fixed #16464 -- Fixed the reference docs of the DateDetailView view.
 Thanks, Julien Phalip.
 }}}

-- 
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.



[Changeset] r16562 - django/trunk/django/db/models

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:40:09 -0700 (Fri, 29 Jul 2011)
New Revision: 16562

Modified:
   django/trunk/django/db/models/query.py
Log:
Fixed #16472 -- Removed stale code in the query code. Thanks, f...@chtd.org.

Modified: django/trunk/django/db/models/query.py
===
--- django/trunk/django/db/models/query.py  2011-07-29 09:40:02 UTC (rev 
16561)
+++ django/trunk/django/db/models/query.py  2011-07-29 09:40:09 UTC (rev 
16562)
@@ -226,7 +226,6 @@
 only_load = self.query.get_loaded_field_names()
 if not fill_cache:
 fields = self.model._meta.fields
-pk_idx = self.model._meta.pk_index()
 
 load_fields = []
 # If only/defer clauses have been specified,
@@ -235,9 +234,6 @@
 for field, model in self.model._meta.get_fields_with_model():
 if model is None:
 model = self.model
-if field == self.model._meta.pk:
-# Record the index of the primary key when it is found
-pk_idx = len(load_fields)
 try:
 if field.name in only_load[model]:
 # Add a field that has been explicitly included
@@ -276,7 +272,6 @@
 else:
 if skip:
 row_data = row[index_start:aggregate_start]
-pk_val = row_data[pk_idx]
 obj = model_cls(**dict(zip(init_list, row_data)))
 else:
 # Omit aggregates in object creation.

-- 
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] #16472: cleaning django.db.models.query.iterator code

2011-07-29 Thread Django
#16472: cleaning django.db.models.query.iterator code
-+-
   Reporter:  fva@…  |  Owner:  nobody
   Type: | Status:  closed
  Cleanup/optimization   |  Component:  Database layer
  Milestone: |  (models, ORM)
Version:  1.3|   Severity:  Normal
 Resolution:  fixed  |   Keywords:  query iterator
   Triage Stage:  Ready for  |  Has patch:  1
  checkin|Needs tests:  0
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16562]:
 {{{
 #!CommitTicketReference repository="" revision="16562"
 Fixed #16472 -- Removed stale code in the query code. Thanks,
 f...@chtd.org.
 }}}

-- 
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] #16477: "dumpdata" --help for the --database option is wrong

2011-07-29 Thread Django
#16477: "dumpdata" --help for the --database option is wrong
-+-
   Reporter:  charettes  |  Owner:  nobody
   Type: | Status:  closed
  Cleanup/optimization   |  Component:  Core (Management
  Milestone: |  commands)
Version:  1.3|   Severity:  Normal
 Resolution:  fixed  |   Keywords:  dumpdata
   Triage Stage:  Ready for  |  Has patch:  1
  checkin|Needs tests:  0
Needs documentation:  0  |  Easy pickings:  1
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16561]:
 {{{
 #!CommitTicketReference repository="" revision="16561"
 Fixed #16477 -- Correct help text of an option of the dumpdata management
 command. Thanks, charettes.
 }}}

-- 
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.



[Changeset] r16561 - django/trunk/django/core/management/commands

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:40:02 -0700 (Fri, 29 Jul 2011)
New Revision: 16561

Modified:
   django/trunk/django/core/management/commands/dumpdata.py
Log:
Fixed #16477 -- Correct help text of an option of the dumpdata management 
command. Thanks, charettes.

Modified: django/trunk/django/core/management/commands/dumpdata.py
===
--- django/trunk/django/core/management/commands/dumpdata.py2011-07-29 
09:39:55 UTC (rev 16560)
+++ django/trunk/django/core/management/commands/dumpdata.py2011-07-29 
09:40:02 UTC (rev 16561)
@@ -13,8 +13,8 @@
 make_option('--indent', default=None, dest='indent', type='int',
 help='Specifies the indent level to use when pretty-printing 
output'),
 make_option('--database', action='store', dest='database',
-default=DEFAULT_DB_ALIAS, help='Nominates a specific database to 
load '
-'fixtures into. Defaults to the "default" database.'),
+default=DEFAULT_DB_ALIAS, help='Nominates a specific database to 
dump '
+'fixtures from. Defaults to the "default" database.'),
 make_option('-e', '--exclude', dest='exclude',action='append', 
default=[],
 help='An appname or appname.ModelName to exclude (use multiple 
--exclude to exclude multiple apps/models).'),
 make_option('-n', '--natural', action='store_true', 
dest='use_natural_keys', default=False,

-- 
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] #16498: GenericIPAddressField Documentation Error

2011-07-29 Thread Django
#16498: GenericIPAddressField Documentation Error
-+-
   Reporter:  JshWright  |  Owner:  nobody
   Type:  Bug| Status:  closed
  Milestone: |  Component:  Documentation
Version:  SVN|   Severity:  Normal
 Resolution:  fixed  |   Keywords:
   Triage Stage:  Ready for  |  Has patch:  1
  checkin|Needs tests:  0
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16559]:
 {{{
 #!CommitTicketReference repository="" revision="16559"
 Fixed #16498 -- Fixed typo in GenericIPAddressField docs. Thanks,
 JshWright.
 }}}

-- 
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] #16482: 16545 security doc grammar fix introduced a typo

2011-07-29 Thread Django
#16482: 16545 security doc grammar fix introduced a typo
-+-
   Reporter:  charettes  |  Owner:  nobody
   Type: | Status:  closed
  Cleanup/optimization   |  Component:  Documentation
  Milestone: |   Severity:  Normal
Version:  1.3|   Keywords:
 Resolution:  fixed  |  Has patch:  1
   Triage Stage:  Ready for  |Needs tests:  0
  checkin|  Easy pickings:  1
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16560]:
 {{{
 #!CommitTicketReference repository="" revision="16560"
 Fixes #16482 -- Fixes typo in security docs. Thanks, charettes.
 }}}

-- 
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.



[Changeset] r16560 - django/trunk/docs/topics

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:39:55 -0700 (Fri, 29 Jul 2011)
New Revision: 16560

Modified:
   django/trunk/docs/topics/security.txt
Log:
Fixes #16482 -- Fixes typo in security docs. Thanks, charettes.

Modified: django/trunk/docs/topics/security.txt
===
--- django/trunk/docs/topics/security.txt   2011-07-29 09:39:49 UTC (rev 
16559)
+++ django/trunk/docs/topics/security.txt   2011-07-29 09:39:55 UTC (rev 
16560)
@@ -15,7 +15,7 @@
 XSS attacks allow a user to inject client side scripts into the browsers of
 other users. This is usually achieved by storing the malicious scripts in the
 database where it will be retrieved and displayed to other users, or by getting
-users to click a link which will cause the attacker's javascript to be 
executred
+users to click a link which will cause the attacker's javascript to be executed
 by the user's browser. However, XSS attacks can originate from any untrusted
 source of data, such as cookies or web services, whenever the data is not
 sufficiently sanitized before including in a page.

-- 
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.



[Changeset] r16559 - django/trunk/docs/ref/models

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:39:49 -0700 (Fri, 29 Jul 2011)
New Revision: 16559

Modified:
   django/trunk/docs/ref/models/fields.txt
Log:
Fixed #16498 -- Fixed typo in GenericIPAddressField docs. Thanks, JshWright.

Modified: django/trunk/docs/ref/models/fields.txt
===
--- django/trunk/docs/ref/models/fields.txt 2011-07-29 09:39:42 UTC (rev 
16558)
+++ django/trunk/docs/ref/models/fields.txt 2011-07-29 09:39:49 UTC (rev 
16559)
@@ -769,7 +769,7 @@
 ``GenericIPAddressField``
 -
 
-.. class:: GenericIPAddressField([protocols=both, unpack_ipv4=False, 
**options])
+.. class:: GenericIPAddressField([protocol=both, unpack_ipv4=False, **options])
 
 .. versionadded:: 1.4
 

-- 
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] #16520: Updated locale formats for hungarian language

2011-07-29 Thread Django
#16520: Updated locale formats for hungarian language
-+-
   Reporter:  slink  |  Owner:  nobody
   Type:  Bug| Status:  closed
  Milestone: |  Component:
Version:  1.3|  Internationalization
 Resolution:  fixed  |   Severity:  Normal
   Triage Stage:  Ready for  |   Keywords:  locale, formats
  checkin|  Has patch:  1
Needs documentation:  0  |Needs tests:  0
Patch needs improvement:  0  |  Easy pickings:  0
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16558]:
 {{{
 #!CommitTicketReference repository="" revision="16558"
 Fixed #16520 -- Fixed typo in Hungarian localization formats introduced in
 r16429. Thanks, slink.
 }}}

-- 
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.



[Changeset] r16558 - django/trunk/django/conf/locale/hu

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:39:42 -0700 (Fri, 29 Jul 2011)
New Revision: 16558

Modified:
   django/trunk/django/conf/locale/hu/formats.py
Log:
Fixed #16520 -- Fixed typo in Hungarian localization formats introduced in 
r16429. Thanks, slink.

Modified: django/trunk/django/conf/locale/hu/formats.py
===
--- django/trunk/django/conf/locale/hu/formats.py   2011-07-29 09:39:35 UTC 
(rev 16557)
+++ django/trunk/django/conf/locale/hu/formats.py   2011-07-29 09:39:42 UTC 
(rev 16558)
@@ -23,7 +23,7 @@
 '%H.%M',# '14.30'
 )
 DATETIME_INPUT_FORMATS = (
-'%Y.%m.%d. %H.%m.%S',   # '2006.10.25. 14.30.59'
+'%Y.%m.%d. %H.%M.%S',   # '2006.10.25. 14.30.59'
 '%Y.%m.%d. %H.%M',  # '2006.10.25. 14.30'
 '%Y.%m.%d.',# '2006.10.25.'
 )

-- 
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] #16531: [patch] fix various "undefined name" issues

2011-07-29 Thread Django
#16531: [patch] fix various "undefined name" issues
-+-
   Reporter:  brutasse   |  Owner:  nobody
   Type: | Status:  closed
  Cleanup/optimization   |  Component:  Core (Other)
  Milestone: |   Severity:  Normal
Version:  1.3|   Keywords:
 Resolution:  fixed  |  Has patch:  1
   Triage Stage:  Ready for  |Needs tests:  0
  checkin|  Easy pickings:  0
Needs documentation:  0  |
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16557]:
 {{{
 #!CommitTicketReference repository="" revision="16557"
 Fixed #16531 -- Fixed various instances of "undefined name" issues.
 Thanks, Bruno Renié.
 }}}

-- 
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.



[Changeset] r16557 - in django/trunk/django: contrib/gis/db/backends db/models/fields views views/generic

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:39:35 -0700 (Fri, 29 Jul 2011)
New Revision: 16557

Modified:
   django/trunk/django/contrib/gis/db/backends/base.py
   django/trunk/django/db/models/fields/__init__.py
   django/trunk/django/views/debug.py
   django/trunk/django/views/generic/dates.py
Log:
Fixed #16531 -- Fixed various instances of "undefined name" issues. Thanks, 
Bruno Reni?\195?\169.

Modified: django/trunk/django/contrib/gis/db/backends/base.py
===
--- django/trunk/django/contrib/gis/db/backends/base.py 2011-07-29 09:39:23 UTC 
(rev 16556)
+++ django/trunk/django/contrib/gis/db/backends/base.py 2011-07-29 09:39:35 UTC 
(rev 16557)
@@ -121,7 +121,7 @@
 raise NotImplementedError('Aggregate support not implemented for this 
spatial backend.')
 
 def spatial_lookup_sql(self, lvalue, lookup_type, value, field):
-raise NotImplmentedError
+raise NotImplementedError
 
 # Routines for getting the OGC-compliant models.
 def geometry_columns(self):

Modified: django/trunk/django/db/models/fields/__init__.py
===
--- django/trunk/django/db/models/fields/__init__.py2011-07-29 09:39:23 UTC 
(rev 16556)
+++ django/trunk/django/db/models/fields/__init__.py2011-07-29 09:39:35 UTC 
(rev 16557)
@@ -967,7 +967,7 @@
 if value and ':' in value:
 try:
 return clean_ipv6_address(value, self.unpack_ipv4)
-except ValidationError:
+except exceptions.ValidationError:
 pass
 return value
 

Modified: django/trunk/django/views/debug.py
===
--- django/trunk/django/views/debug.py  2011-07-29 09:39:23 UTC (rev 16556)
+++ django/trunk/django/views/debug.py  2011-07-29 09:39:35 UTC (rev 16557)
@@ -5,6 +5,7 @@
 import types
 
 from django.conf import settings
+from django.core.exceptions import ImproperlyConfigured
 from django.http import (HttpResponse, HttpResponseServerError,
 HttpResponseNotFound, HttpRequest, build_request_repr)
 from django.template import (Template, Context, TemplateDoesNotExist,
@@ -79,7 +80,7 @@
 try:
 default_exception_reporter_filter = getattr(mod, classname)()
 except AttributeError:
-raise exceptions.ImproperlyConfigured('Default exception reporter 
filter module "%s" does not define a "%s" class' % (modname, classname))
+raise ImproperlyConfigured('Default exception reporter filter 
module "%s" does not define a "%s" class' % (modname, classname))
 if request:
 return getattr(request, 'exception_reporter_filter', 
default_exception_reporter_filter)
 else:

Modified: django/trunk/django/views/generic/dates.py
===
--- django/trunk/django/views/generic/dates.py  2011-07-29 09:39:23 UTC (rev 
16556)
+++ django/trunk/django/views/generic/dates.py  2011-07-29 09:39:35 UTC (rev 
16557)
@@ -210,9 +210,9 @@
 
 date_list = queryset.dates(date_field, date_type)[::-1]
 if date_list is not None and not date_list and not allow_empty:
-raise Http404(_(u"No %(verbose_name_plural)s available") % {
-'verbose_name_plural': 
force_unicode(qs.model._meta.verbose_name_plural)
-})
+name = force_unicode(queryset.model._meta.verbose_name_plural)
+raise Http404(_(u"No %(verbose_name_plural)s available") %
+  {'verbose_name_plural': name})
 
 return date_list
 

-- 
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.



[Changeset] r16556 - in django/trunk: django/core/cache/backends tests/regressiontests/cache

2011-07-29 Thread noreply
Author: jezdez
Date: 2011-07-29 02:39:23 -0700 (Fri, 29 Jul 2011)
New Revision: 16556

Modified:
   django/trunk/django/core/cache/backends/memcached.py
   django/trunk/tests/regressiontests/cache/tests.py
Log:
Fixed #16533 -- Stopped the memcache cache backend from raising an exception if 
the timeout value isn't an integer. Thanks, Jeff Balogh.

Modified: django/trunk/django/core/cache/backends/memcached.py
===
--- django/trunk/django/core/cache/backends/memcached.py2011-07-28 
22:10:27 UTC (rev 16555)
+++ django/trunk/django/core/cache/backends/memcached.py2011-07-29 
09:39:23 UTC (rev 16556)
@@ -46,7 +46,7 @@
 #
 # This means that we have to switch to absolute timestamps.
 timeout += int(time.time())
-return timeout
+return int(timeout)
 
 def add(self, key, value, timeout=0, version=None):
 key = self.make_key(key, version=version)

Modified: django/trunk/tests/regressiontests/cache/tests.py
===
--- django/trunk/tests/regressiontests/cache/tests.py   2011-07-28 22:10:27 UTC 
(rev 16555)
+++ django/trunk/tests/regressiontests/cache/tests.py   2011-07-29 09:39:23 UTC 
(rev 16556)
@@ -408,6 +408,11 @@
 self.assertEqual(self.cache.get('key3'), 'sausage')
 self.assertEqual(self.cache.get('key4'), 'lobster bisque')
 
+def test_float_timeout(self):
+# Make sure a timeout given as a float doesn't crash anything.
+self.cache.set("key1", "spam", 100.2)
+self.assertEqual(self.cache.get("key1"), "spam")
+
 def perform_cull_test(self, initial_count, final_count):
 """This is implemented as a utility method, because only some of the 
backends
 implement culling. The culling algorithm also varies slightly, so the 
final

-- 
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] #16533: pylibmc cache backend raises an exception for float timeouts

2011-07-29 Thread Django
#16533: pylibmc cache backend raises an exception for float timeouts
-+-
   Reporter:  jbalogh|  Owner:  jbalogh
   Type:  Bug| Status:  closed
  Milestone:  1.4|  Component:  Core (Cache system)
Version:  1.3|   Severity:  Normal
 Resolution:  fixed  |   Keywords:
   Triage Stage:  Ready for  |  Has patch:  1
  checkin|Needs tests:  0
Needs documentation:  0  |  Easy pickings:  0
Patch needs improvement:  0  |
  UI/UX:  0  |
-+-
Changes (by jezdez):

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


Comment:

 In [16556]:
 {{{
 #!CommitTicketReference repository="" revision="16556"
 Fixed #16533 -- Stopped the memcache cache backend from raising an
 exception if the timeout value isn't an integer. Thanks, Jeff Balogh.
 }}}

-- 
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.