Re: [Django] #12776: get_profile() may throw AttributeError instead of SiteProfileNotAvailable

2010-02-22 Thread Django
#12776: get_profile() may throw AttributeError instead of 
SiteProfileNotAvailable
+---
  Reporter:  master | Owner:  nobody 
Status:  closed | Milestone:  1.2
 Component:  Authentication |   Version:  1.1
Resolution:  fixed  |  Keywords:  profile
 Stage:  Ready for checkin  | Has_patch:  1  
Needs_docs:  0  |   Needs_tests:  0  
Needs_better_patch:  0  |  
+---
Changes (by anonymous):

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

Comment:

 Fixed in r12506.

-- 
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-upda...@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] #12776: get_profile() may throw AttributeError instead of SiteProfileNotAvailable

2010-02-22 Thread Django
#12776: get_profile() may throw AttributeError instead of 
SiteProfileNotAvailable
+---
  Reporter:  master | Owner:  nobody 
Status:  new| Milestone:  1.2
 Component:  Authentication |   Version:  1.1
Resolution: |  Keywords:  profile
 Stage:  Ready for checkin  | Has_patch:  1  
Needs_docs:  0  |   Needs_tests:  0  
Needs_better_patch:  0  |  
+---
Changes (by Alex):

  * stage:  Accepted => Ready for checkin

-- 
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-upda...@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] #12776: get_profile() may throw AttributeError instead of SiteProfileNotAvailable

2010-02-22 Thread Django
#12776: get_profile() may throw AttributeError instead of 
SiteProfileNotAvailable
-+--
  Reporter:  master  | Owner:  nobody 
Status:  new | Milestone:  1.2
 Component:  Authentication  |   Version:  1.1
Resolution:  |  Keywords:  profile
 Stage:  Accepted| Has_patch:  1  
Needs_docs:  0   |   Needs_tests:  0  
Needs_better_patch:  0   |  
-+--
Comment (by brutasse):

 Added a patch with tests. The patch adds some more human-friendly errors
 as well, to be reviewed by a native English speaker.

-- 
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-upda...@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] #12776: get_profile() may throw AttributeError instead of SiteProfileNotAvailable

2010-02-10 Thread Django
#12776: get_profile() may throw AttributeError instead of 
SiteProfileNotAvailable
-+--
  Reporter:  master  | Owner:  nobody 
Status:  new | Milestone:  1.2
 Component:  Authentication  |   Version:  1.1
Resolution:  |  Keywords:  profile
 Stage:  Accepted| Has_patch:  1  
Needs_docs:  0   |   Needs_tests:  0  
Needs_better_patch:  0   |  
-+--
Changes (by russellm):

  * needs_better_patch:  => 0
  * needs_docs:  => 0
  * stage:  Unreviewed => Accepted
  * needs_tests:  => 0
  * milestone:  => 1.2

-- 
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-upda...@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] #12776: get_profile() may throw AttributeError instead of SiteProfileNotAvailable

2010-02-04 Thread Django
#12776: get_profile() may throw AttributeError instead of 
SiteProfileNotAvailable
+---
 Reporter:  master  |   Owner:  nobody
   Status:  new |   Milestone:
Component:  Authentication  | Version:  1.1   
 Keywords:  profile |   Stage:  Unreviewed
Has_patch:  1   |  
+---
 I didn't find a case to fire:[[BR]]
 except (ImportError, ImproperlyConfigured)

 But some others cases :

 In AUTH_PROFILE_MODULE, if:

 - you don't provide a '.': 'accountsUserProfile'[[BR]]
 ==> ValueError

 - you mispell or forget the app_label part or the model_name part:
 'accounts.', 'accXXXounts.UserProfile'[[BR]]
 No exception is raised and the variable 'model' is returned as None.[[BR]]
 ==> AttributeError on following line: 'NoneType' object has no attribute
 '_default_manager'

 I needed something similar for my own code, that I wrote as:

 {{{
 try:
 ...
 model = ...
 if not model:
 raise SiteProfileNotAvailable
 ...
 except ValueError:
 raise SiteProfileNotAvailable
 }}}

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