Re: [Django] #19632: Sample code is wrong in page: "Using the Django authentication system"

2013-02-08 Thread Django
#19632: Sample code is wrong in page: "Using the Django authentication system"
-+-
 Reporter:  grossmanandy@…   |Owner:  charettes
 Type:   |   Status:  closed
  Cleanup/optimization   |  Version:  1.4
Component:  Documentation|   Resolution:  fixed
 Severity:  Normal   | Triage Stage:  Accepted
 Keywords:   |  Needs documentation:  1
Has patch:  1|  Patch needs improvement:  0
  Needs tests:  0|UI/UX:  0
Easy pickings:  1|
-+-

Comment (by Aymeric Augustin ):

 In [changeset:"d90abcc9dad9b239e77aa67bfdd0c431072e2434"]:
 {{{
 #!CommitTicketReference repository=""
 revision="d90abcc9dad9b239e77aa67bfdd0c431072e2434"
 [1.5.x] Fixed #19632 -- Bug in code sample.

 Thanks grossmanandy at bfusa com and Simon Charette.

 Backport of 1dd7492.
 }}}

-- 
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 unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [Django] #19632: Sample code is wrong in page: "Using the Django authentication system"

2013-01-18 Thread Django
#19632: Sample code is wrong in page: "Using the Django authentication system"
-+-
 Reporter:  grossmanandy@…   |Owner:  charettes
 Type:   |   Status:  closed
  Cleanup/optimization   |  Version:  1.4
Component:  Documentation|   Resolution:  fixed
 Severity:  Normal   | Triage Stage:  Accepted
 Keywords:   |  Needs documentation:  1
Has patch:  1|  Patch needs improvement:  0
  Needs tests:  0|UI/UX:  0
Easy pickings:  1|
-+-

Comment (by Aymeric Augustin ):

 In [changeset:"1dd749284325ea8fe747a3728ed92bafef4ff6a0"]:
 {{{
 #!CommitTicketReference repository=""
 revision="1dd749284325ea8fe747a3728ed92bafef4ff6a0"
 Fixed #19632 -- Bug in code sample.

 Thanks grossmanandy at bfusa com and Simon Charette.
 }}}

-- 
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 https://groups.google.com/groups/opt_out.




Re: [Django] #19632: Sample code is wrong in page: "Using the Django authentication system"

2013-01-18 Thread Django
#19632: Sample code is wrong in page: "Using the Django authentication system"
-+-
 Reporter:  grossmanandy@…   |Owner:  charettes
 Type:   |   Status:  closed
  Cleanup/optimization   |  Version:  1.4
Component:  Documentation|   Resolution:  fixed
 Severity:  Normal   | Triage Stage:  Accepted
 Keywords:   |  Needs documentation:  1
Has patch:  1|  Patch needs improvement:  0
  Needs tests:  0|UI/UX:  0
Easy pickings:  1|
-+-
Changes (by Aymeric Augustin ):

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


Comment:

 In [changeset:"d90abcc9dad9b239e77aa67bfdd0c431072e2434"]:
 {{{
 #!CommitTicketReference repository=""
 revision="d90abcc9dad9b239e77aa67bfdd0c431072e2434"
 [1.5.x] Fixed #19632 -- Bug in code sample.

 Thanks grossmanandy at bfusa com and Simon Charette.

 Backport of 1dd7492.
 }}}

-- 
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 https://groups.google.com/groups/opt_out.




Re: [Django] #19632: Sample code is wrong in page: "Using the Django authentication system"

2013-01-18 Thread Django
#19632: Sample code is wrong in page: "Using the Django authentication system"
-+-
 Reporter:  grossmanandy@…   |Owner:  charettes
 Type:   |   Status:  assigned
  Cleanup/optimization   |  Version:  1.4
Component:  Documentation|   Resolution:
 Severity:  Normal   | Triage Stage:  Accepted
 Keywords:   |  Needs documentation:  1
Has patch:  1|  Patch needs improvement:  0
  Needs tests:  0|UI/UX:  0
Easy pickings:  1|
-+-
Changes (by charettes):

 * has_patch:  0 => 1


Comment:

 Added the doc fix.

-- 
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 https://groups.google.com/groups/opt_out.




Re: [Django] #19632: Sample code is wrong in page: "Using the Django authentication system"

2013-01-18 Thread Django
#19632: Sample code is wrong in page: "Using the Django authentication system"
-+-
 Reporter:  grossmanandy@…   |Owner:  charettes
 Type:   |   Status:  assigned
  Cleanup/optimization   |  Version:  1.4
Component:  Documentation|   Resolution:
 Severity:  Normal   | Triage Stage:  Accepted
 Keywords:   |  Needs documentation:  1
Has patch:  0|  Patch needs improvement:  0
  Needs tests:  0|UI/UX:  0
Easy pickings:  1|
-+-

Comment (by charettes):

 Actually looking at
 
[https://github.com/django/django/blob/75ef980e20fc0441aedb0645aa471c9fe606e3b0/django/contrib/auth/decorators.py#L24
 @user_passes_test] the doc should read:

 {{{
 from django.contrib.auth.decorators import user_passes_test

 def email_check(user):
 return '@example.com' in user.email

 @user_passes_test(email_check)
 def my_view(request):
 ...
 }}}

 Since the test function is called with `request.user`.

-- 
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 https://groups.google.com/groups/opt_out.




Re: [Django] #19632: Sample code is wrong in page: "Using the Django authentication system"

2013-01-18 Thread Django
#19632: Sample code is wrong in page: "Using the Django authentication system"
-+-
 Reporter:  grossmanandy@…   |Owner:  charettes
 Type:   |   Status:  assigned
  Cleanup/optimization   |  Version:  1.4
Component:  Documentation|   Resolution:
 Severity:  Normal   | Triage Stage:  Accepted
 Keywords:   |  Needs documentation:  1
Has patch:  0|  Patch needs improvement:  0
  Needs tests:  0|UI/UX:  0
Easy pickings:  1|
-+-
Changes (by charettes):

 * status:  new => assigned
 * needs_better_patch:   => 0
 * needs_tests:   => 0
 * owner:  nobody => charettes
 * needs_docs:   => 1
 * type:  Bug => Cleanup/optimization
 * 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 https://groups.google.com/groups/opt_out.




[Django] #19632: Sample code is wrong in page: "Using the Django authentication system"

2013-01-18 Thread Django
#19632: Sample code is wrong in page: "Using the Django authentication system"
+
 Reporter:  grossmanandy@…  |  Owner:  nobody
 Type:  Bug | Status:  new
Component:  Documentation   |Version:  1.4
 Severity:  Normal  |   Keywords:
 Triage Stage:  Unreviewed  |  Has patch:  0
Easy pickings:  1   |  UI/UX:  0
+
 In https://docs.djangoproject.com/en/dev/topics/auth/default/#auth-web-
 requests

 {{{
 from django.contrib.auth.decorators import user_passes_test

 def email_check(user):
 return '@example.com' in request.user.email

 @user_passes_test(email_check)
 def my_view(request):
 ...
 }}}

 should read


 {{{
 from django.contrib.auth.decorators import user_passes_test

 def email_check(request):
 return '@example.com' in request.user.email

 @user_passes_test(email_check)
 def my_view(request):
 ...
 }}}

-- 
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 https://groups.google.com/groups/opt_out.