[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-06 Thread Roundup Robot
Roundup Robot added the comment: New changeset 94966dfd3bd3 by Larry Hastings in branch '3.5': Issue #24305: Prevent import subsystem stack frames from being counted https://hg.python.org/cpython/rev/94966dfd3bd3 -- nosy: +python-dev ___ Python tracke

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-06 Thread Nathaniel Smith
Nathaniel Smith added the comment: ok -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.or

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-06 Thread Larry Hastings
Larry Hastings added the comment: Unless I'm overruled, yes. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-06 Thread Nathaniel Smith
Nathaniel Smith added the comment: Also just checked searchcode.com, which allows more fine-grained queries, and it reports ~6500 hits for "stacklevel=2" and exactly 0 for "stacklevel=8". Huh. So the official word is that requiring stacklevel=8 on 3.4 is not a bug, rather all those modules a

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-06 Thread Larry Hastings
Larry Hastings added the comment: Yes, I saw that. That doesn't mean we should change the interface they are using (incorrectly) eighteen months after it shipped. We take backwards-compatibility pretty seriously here in the Python world, bugs and all. --

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-06 Thread Nathaniel Smith
Nathaniel Smith added the comment: Some limited code search statistics posted upthread (msg28) suggest that ~100% of real-world code is using stacklevel=2 unconditionally and thus getting incorrect results on 3.3 and 3.4. -- ___ Python tracker

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-06 Thread Larry Hastings
Larry Hastings added the comment: I don't think it'd be appropriate to backport to 3.4--that ship has sailed. 3.4 requires a stacklevel=8 and that's that. If we backported it and it shipped in 3.4.4, "correct" code would have to use a stacklevel=8 for 3.4.0 through 3.4.3, and stacklevel=2 for

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-06 Thread Nathaniel Smith
Nathaniel Smith added the comment: Hooray! Thanks Larry. Would it make sense to do a 3.4.x backport, or is that closed now with 3.5 being imminent? -- ___ Python tracker ___ __

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-06 Thread Larry Hastings
Larry Hastings added the comment: It was basically okay on the buildbots--no worse than cpython would have been before the checkin. (A lot of the buildbots are... wonky.) I checked it in to cpython350 directly. I'll do the forward merge after 3.5.0rc3 goes out the door. -- resolutio

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-05 Thread Larry Hastings
Larry Hastings added the comment: Okay. Right now creating server-side clones is broken. So I have repurposed one of my existing (old, dead) server-side clones for testing this. It's called "ssh://h...@hg.python.org/larry/path_error2". I just fired off this change on all the "custom" buildb

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-03 Thread Larry Hastings
Larry Hastings added the comment: That *is* easier, thanks. Though the UI for that is baffling. Protip: search for the section where all the "custom" builders are listed all in one section, three-quarters of the way down the page. -- ___ Python tr

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-03 Thread Brett Cannon
Changes by Brett Cannon : -- assignee: larry -> brett.cannon ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-03 Thread Zachary Ware
Zachary Ware added the comment: Just to note, there's an easier way to run a custom build on multiple bots: go to http://buildbot.python.org/all/builders/ and scroll (way) down to the section for forcing a build on custom builders (you can search for 'Repo path:' (with the colon)), check the b

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-09-03 Thread Larry Hastings
Larry Hastings added the comment: Well, this is making me nervous to apply during the RCs. But... I'm willing to risk it. My price: I want to see this run on a bunch of otherwise-healthy buildbots to make sure it doesn't break any platforms. In case you've never done such a thing, here's how

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-08-28 Thread Brett Cannon
Brett Cannon added the comment: I figured out what was causing the threading/subprocess problems (something in frame->f_code->co-filename was NULL), so the attached patch covers Python, C, and adds a test (as well as cleaning up the test_warnings file structure since it was old-school spread

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-08-28 Thread Brett Cannon
Changes by Brett Cannon : Added file: http://bugs.python.org/file40286/issue24305.diff ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-08-28 Thread Brett Cannon
Changes by Brett Cannon : -- assignee: larry -> brett.cannon priority: deferred blocker -> critical ___ Python tracker ___ ___ Python-

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-08-25 Thread Brett Cannon
Brett Cannon added the comment: So there are two approaches I see to solving this whole thing. One is for there to be a slight divergence between the C code and the Python code. For _warnings.warn(), nothing changes. For warnings.warn(), though, it does the expected frame skipping. This would

[issue24305] The new import system makes it inconvenient to correctly issue a deprecation warning for a module

2015-08-24 Thread Larry Hastings
Changes by Larry Hastings : -- title: The new import system makes it impossible to correctly issue a deprecation warning for a module -> The new import system makes it inconvenient to correctly issue a deprecation warning for a module ___ Python tra