[issue6843] No documentation for the module argument to warnings.filterwarnings

2009-09-05 Thread Jean-Paul Calderone

New submission from Jean-Paul Calderone exar...@divmod.com:

None of the documentation seems to cover this parameter.  The test suite
doesn't even seem to exercise it, either.  What does it do?  What kind
of values are expected to be passed for it?

--
assignee: georg.brandl
components: Documentation
messages: 92280
nosy: exarkun, georg.brandl
severity: normal
status: open
title: No documentation for the module argument to warnings.filterwarnings
versions: Python 2.5, Python 2.6, Python 2.7

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6843
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6843] No documentation for the module argument to warnings.filterwarnings

2009-09-05 Thread Georg Brandl

Georg Brandl ge...@python.org added the comment:

The values for a filter entry are documented under the The Warnings
Filter heading.  I've added a link to it from filterwarnings in r74671.

--
resolution:  - fixed
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6843
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6843] No documentation for the module argument to warnings.filterwarnings

2009-09-05 Thread Jean-Paul Calderone

Jean-Paul Calderone exar...@divmod.com added the comment:

Thanks for that Georg.

I'm still having trouble with this.  I'm aware that the issue tracking
isn't the right place to ask for help with writing programs, but I think
that since I still can't get this code to work, even looking at the new
documentation, there is still a documentation issue.  Perhaps there's
something else I'm doing wrong, though.

The code causing the warning to be emitted is here:

http://twistedmatrix.com/trac/browser/trunk/twisted/conch/ssh/filetransfer.py?rev=27062#L829

It's a simple example of the new-in-2.6 BaseException.message
deprecation warning.  I'm trying to suppress this.  My attempt goes
something like this:

warnings.filterwarnings(
'ignore',
message='BaseException.message has been deprecated as of Python 2.6',
category=DeprecationWarning,
module=r'twisted\.conch\.ssh\.filetransfer')

When I remove the module argument from this call, the warning is
suppressed.  When I include it, it is not.  The string given seems to be
a string containing a regular expression that the module name must
match, the meaning the documentation suggests.  Am I just doing
something wrong, or are the docs still not right?

--
status: closed - open

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6843
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6843] No documentation for the module argument to warnings.filterwarnings

2009-09-05 Thread Georg Brandl

Georg Brandl ge...@python.org added the comment:

A simple isolated test here shows that the module argument works as
intended.  I can't help with your problem without more information (but
you probably should debug this somewhere in warnings.py/_warnings.c). 
But you're right, this is not a subject for the bugtracker anymore :)

--
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6843
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com