This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author nnorwitz
Recipients
Date 2007-04-23.06:15:08
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
I'm not sure why all the code was in there to begin with it was ancient history.  Hopefully Guido remembers.  Guido, do you see any particular issue with this approach (ie, removing all the gyrations in warnings and using f_code.co_filename?

There is a difference in behaviour.  If a module modifies its __file__, the old code would pick up the modified version.  This new code will find the real file.  I'm not sure if that's a bug or a feature though. :-)  Similarly with __name__.

Adam, I like adding the warning_guard using a with statement.  Although I don't think comment should be completely removed.  Could you add a comment about why the guard is necessary (ie, the repeated calls/-R part)?

Have you tested with -R and with -u all?  ie:

  ./python -E -tt ./Lib/test/regrtest.py -R 4:3:
and
  ./python -E -tt ./Lib/test/regrtest.py -u all

(two separate runs).

In the last test case you are replacing (the old spam7), why does "sys" become "no context"?
History
Date User Action Args
2007-08-23 15:57:52adminlinkissue1692664 messages
2007-08-23 15:57:52admincreate