Re: [Django] #25999: Document why Django makes its deprecation warnings loud by default and how to silence them

2015-12-30 Thread Django
#25999: Document why Django makes its deprecation warnings loud by default and 
how
to silence them
--+
 Reporter:  timgraham |Owner:  nobody
 Type:  Cleanup/optimization  |   Status:  new
Component:  Documentation |  Version:  master
 Severity:  Normal|   Resolution:
 Keywords:| Triage Stage:  Accepted
Has patch:  0 |  Needs documentation:  0
  Needs tests:  0 |  Patch needs improvement:  0
Easy pickings:  0 |UI/UX:  0
--+

Comment (by timgraham):

 I [https://groups.google.com/d/msg/django-
 developers/ZWy2Esj46nE/DEv8O1znDwAJ raised a proposal] to discontinue
 making RemovedInNextVersionWarning loud by default.

--
Ticket URL: <https://code.djangoproject.com/ticket/25999#comment:1>
Django <https://code.djangoproject.com/>
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/067.03c57e504ad138b80e7224cb406fb02b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


[Django] #25999: Document why Django makes its deprecation warnings loud by default and how to silence them

2015-12-29 Thread Django
#25999: Document why Django makes its deprecation warnings loud by default and 
how
to silence them
+
   Reporter:  timgraham |  Owner:  nobody
   Type:  Cleanup/optimization  | Status:  new
  Component:  Documentation |Version:  master
   Severity:  Normal|   Keywords:
   Triage Stage:  Accepted  |  Has patch:  0
Needs documentation:  0 |Needs tests:  0
Patch needs improvement:  0 |  Easy pickings:  0
  UI/UX:  0 |
+
 See #18985 for the background of why we route warnings through logging.

 A developer can selectively silence warnings using something like this in
 an app's `AppConfig.ready()` method:
 {{{
 import warnings
 from django.utils.deprecation import RemovedInNextVersionWarning
 warnings.simplefilter("ignore", RemovedInNextVersionWarning)
 }}}
 This example can be improved to show how to silence a particular warning
 instead of all warnings.

 This works because `AppConfig.ready()` methods are called after
 `django.utils.log.configure_logging()` (which does
 `warnings.simplefilter("default", RemovedInNextVersionWarning)`) in
 `django.setup()`.

--
Ticket URL: <https://code.djangoproject.com/ticket/25999>
Django <https://code.djangoproject.com/>
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/052.7dac1c7f54e1442a19701557bf547661%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.