{"action":"closed","issue":{"url":"https://api.github.com/repos/pytest-dev/pluggy/issues/166","repository_url":"https://api.github.com/repos/pytest-dev/pluggy","labels_url":"https://api.github.com/repos/pytest-dev/pluggy/issues/166/labels{/name}","comments_url":"https://api.github.com/repos/pytest-dev/pluggy/issues/166/comments","events_url":"https://api.github.com/repos/pytest-dev/pluggy/issues/166/events","html_url":"https://github.com/pytest-dev/pluggy/issues/166","id":345524776,"node_id":"MDU6SXNzdWUzNDU1MjQ3NzY=","number":166,"title":"Adjust the implprefix DeprecationWarning's stack level","user":{"login":"edmorley","id":501702,"node_id":"MDQ6VXNlcjUwMTcwMg==","avatar_url":"https://avatars3.githubusercontent.com/u/501702?v=4","gravatar_id":"","url":"https://api.github.com/users/edmorley","html_url":"https://github.com/edmorley","followers_url":"https://api.github.com/users/edmorley/followers","following_url":"https://api.github.com/users/edmorley/following{/other_user}","gists_url":"https://api.github.com/users/edmorley/gists{/gist_id}","starred_url":"https://api.github.com/users/edmorley/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edmorley/subscriptions","organizations_url":"https://api.github.com/users/edmorley/orgs","repos_url":"https://api.github.com/users/edmorley/repos","events_url":"https://api.github.com/users/edmorley/events{/privacy}","received_events_url":"https://api.github.com/users/edmorley/received_events","type":"User","site_admin":false},"labels":[{"id":205263666,"node_id":"MDU6TGFiZWwyMDUyNjM2NjY=","url":"https://api.github.com/repos/pytest-dev/pluggy/labels/help%20wanted","name":"help wanted","color":"159818","default":true}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2018-07-29T11:54:27Z","updated_at":"2018-11-09T06:56:50Z","closed_at":"2018-11-09T06:56:50Z","author_association":"NONE","body":"Hi!\r\n\r\nIn #144 a deprecation warning was added for usage of the `implprefix` argument.\r\n\r\nHowever the `warnings.warn()` call doesn't set a `stacklevel`, which means when the warning is output, the blamed line is in pluggy, rather than the plugin that's using `implprefix`. For example:\r\nhttps://travis-ci.org/mozilla/treeherder/jobs/409417404#L895\r\n\r\nPassing `stacklevel=2` would make it clearer as to where the issue lies, and also mean the correct module path can be referenced in eg pytest's `filterwarnings` (for downstream projects who enable warnings/deprecation warnings as errors).\r\n\r\nMany thanks :-)\r\n\r\nCC @tgoodlet"}}
{"actor":{"display_login":"tgoodlet"}}