{"action":"created","comment":{"url":"https://api.github.com/repos/pytest-dev/pytest/pulls/comments/177556986","pull_request_review_id":107449644,"id":177556986,"diff_hunk":"@@ -187,18 +187,34 @@ def find_markers(self, name):\n         \"\"\"find all marks with the given name on the node and its parents\n \n         :param str name: name of the marker\n-        :returns: iterator over marks matching the name\n+        :returns: iterator over marks matching the name\"\"\"\n+        return map(itemgetter(1), self.find_markers_with_node(name))\n+\n+    def find_markers_with_node(self, name):\n+        \"\"\"find all marks with the given name on the node and its parents\n+\n+        :param str name: name of the marker\n+        :returns: iterator over (node, mark) matching the name\n         \"\"\"\n         for node in reversed(self.listchain()):\n             for mark in node._markers.find(name):\n-                yield mark\n+                yield node, mark\n \n     def iter_markers(self):\n         \"\"\"\n         iterate over all markers of the node\n         \"\"\"\n         return chain.from_iterable(x._markers for x in reversed(self.listchain()))\n \n+    def iter_markers_with_node(self):","path":"_pytest/nodes.py","position":null,"original_position":34,"commit_id":"ff04a92cfbc747ede457b13fbf6f4595cfb58e1a","original_commit_id":"ff04a92cfbc747ede457b13fbf6f4595cfb58e1a","user":{"login":"flub","id":146720,"avatar_url":"https://avatars3.githubusercontent.com/u/146720?v=4","gravatar_id":"","url":"https://api.github.com/users/flub","html_url":"https://github.com/flub","followers_url":"https://api.github.com/users/flub/followers","following_url":"https://api.github.com/users/flub/following{/other_user}","gists_url":"https://api.github.com/users/flub/gists{/gist_id}","starred_url":"https://api.github.com/users/flub/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/flub/subscriptions","organizations_url":"https://api.github.com/users/flub/orgs","repos_url":"https://api.github.com/users/flub/repos","events_url":"https://api.github.com/users/flub/events{/privacy}","received_events_url":"https://api.github.com/users/flub/received_events","type":"User","site_admin":false},"body":"I can also be found for having fewer variations of this available.  A minimalistic API would just be `iter_markers` which yields the `(node, mark)` tuples, is that a nice starting point?  It's pretty easy for the user to write the filter.  Especially since the implementations provided here don't provide anything major, it's not like `find_markers` is much more efficient then `iter_markers` with your own filter.","created_at":"2018-03-27T20:13:02Z","updated_at":"2018-03-27T20:13:02Z","html_url":"https://github.com/pytest-dev/pytest/pull/3317#discussion_r177556986","pull_request_url":"https://api.github.com/repos/pytest-dev/pytest/pulls/3317","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/pytest-dev/pytest/pulls/comments/177556986"},"html":{"href":"https://github.com/pytest-dev/pytest/pull/3317#discussion_r177556986"},"pull_request":{"href":"https://api.github.com/repos/pytest-dev/pytest/pulls/3317"}},"in_reply_to_id":177269766},"pull_request":{"url":"https://api.github.com/repos/pytest-dev/pytest/pulls/3317","id":175487746,"html_url":"https://github.com/pytest-dev/pytest/pull/3317","diff_url":"https://github.com/pytest-dev/pytest/pull/3317.diff","patch_url":"https://github.com/pytest-dev/pytest/pull/3317.patch","issue_url":"https://api.github.com/repos/pytest-dev/pytest/issues/3317","number":3317,"state":"open","locked":false,"title":"introduce a distinct searchable non-broken storage for markers","user":{"login":"RonnyPfannschmidt","id":156838,"avatar_url":"https://avatars1.githubusercontent.com/u/156838?v=4","gravatar_id":"","url":"https://api.github.com/users/RonnyPfannschmidt","html_url":"https://github.com/RonnyPfannschmidt","followers_url":"https://api.github.com/users/RonnyPfannschmidt/followers","following_url":"https://api.github.com/users/RonnyPfannschmidt/following{/other_user}","gists_url":"https://api.github.com/users/RonnyPfannschmidt/gists{/gist_id}","starred_url":"https://api.github.com/users/RonnyPfannschmidt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RonnyPfannschmidt/subscriptions","organizations_url":"https://api.github.com/users/RonnyPfannschmidt/orgs","repos_url":"https://api.github.com/users/RonnyPfannschmidt/repos","events_url":"https://api.github.com/users/RonnyPfannschmidt/events{/privacy}","received_events_url":"https://api.github.com/users/RonnyPfannschmidt/received_events","type":"User","site_admin":false},"body":"as part of this i will deprecate markinfo,\r\n\r\nthere will be much to change about the internals, \r\nbut the find_markers api that from now on will work across all node level instead of just function will sort out some of the biggest issues","created_at":"2018-03-16T10:04:49Z","updated_at":"2018-03-27T20:13:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"27376f2ae59e7d0a210800afd7b2e89f6af9f881","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/pytest-dev/pytest/pulls/3317/commits","review_comments_url":"https://api.github.com/repos/pytest-dev/pytest/pulls/3317/comments","review_comment_url":"https://api.github.com/repos/pytest-dev/pytest/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pytest-dev/pytest/issues/3317/comments","statuses_url":"https://api.github.com/repos/pytest-dev/pytest/statuses/ff04a92cfbc747ede457b13fbf6f4595cfb58e1a","head":{"label":"RonnyPfannschmidt:marker-pristine-node-storage","ref":"marker-pristine-node-storage","sha":"ff04a92cfbc747ede457b13fbf6f4595cfb58e1a","user":{"login":"RonnyPfannschmidt","id":156838,"avatar_url":"https://avatars1.githubusercontent.com/u/156838?v=4","gravatar_id":"","url":"https://api.github.com/users/RonnyPfannschmidt","html_url":"https://github.com/RonnyPfannschmidt","followers_url":"https://api.github.com/users/RonnyPfannschmidt/followers","following_url":"https://api.github.com/users/RonnyPfannschmidt/following{/other_user}","gists_url":"https://api.github.com/users/RonnyPfannschmidt/gists{/gist_id}","starred_url":"https://api.github.com/users/RonnyPfannschmidt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RonnyPfannschmidt/subscriptions","organizations_url":"https://api.github.com/users/RonnyPfannschmidt/orgs","repos_url":"https://api.github.com/users/RonnyPfannschmidt/repos","events_url":"https://api.github.com/users/RonnyPfannschmidt/events{/privacy}","received_events_url":"https://api.github.com/users/RonnyPfannschmidt/received_events","type":"User","site_admin":false},"repo":{"id":38833653,"name":"pytest","full_name":"RonnyPfannschmidt/pytest","owner":{"login":"RonnyPfannschmidt","id":156838,"avatar_url":"https://avatars1.githubusercontent.com/u/156838?v=4","gravatar_id":"","url":"https://api.github.com/users/RonnyPfannschmidt","html_url":"https://github.com/RonnyPfannschmidt","followers_url":"https://api.github.com/users/RonnyPfannschmidt/followers","following_url":"https://api.github.com/users/RonnyPfannschmidt/following{/other_user}","gists_url":"https://api.github.com/users/RonnyPfannschmidt/gists{/gist_id}","starred_url":"https://api.github.com/users/RonnyPfannschmidt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RonnyPfannschmidt/subscriptions","organizations_url":"https://api.github.com/users/RonnyPfannschmidt/orgs","repos_url":"https://api.github.com/users/RonnyPfannschmidt/repos","events_url":"https://api.github.com/users/RonnyPfannschmidt/events{/privacy}","received_events_url":"https://api.github.com/users/RonnyPfannschmidt/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/RonnyPfannschmidt/pytest","description":"The pytest testing tool makes it easy to write small tests, yet scales to support complex functional testing","fork":true,"url":"https://api.github.com/repos/RonnyPfannschmidt/pytest","forks_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/forks","keys_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/keys{/key_id}","collaborators_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/teams","hooks_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/hooks","issue_events_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/issues/events{/number}","events_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/events","assignees_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/assignees{/user}","branches_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/branches{/branch}","tags_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/tags","blobs_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/git/refs{/sha}","trees_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/git/trees{/sha}","statuses_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/statuses/{sha}","languages_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/languages","stargazers_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/stargazers","contributors_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/contributors","subscribers_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/subscribers","subscription_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/subscription","commits_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/commits{/sha}","git_commits_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/git/commits{/sha}","comments_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/comments{/number}","issue_comment_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/issues/comments{/number}","contents_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/contents/{+path}","compare_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/compare/{base}...{head}","merges_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/merges","archive_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/downloads","issues_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/issues{/number}","pulls_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/pulls{/number}","milestones_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/milestones{/number}","notifications_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/labels{/name}","releases_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/releases{/id}","deployments_url":"https://api.github.com/repos/RonnyPfannschmidt/pytest/deployments","created_at":"2015-07-09T16:58:09Z","updated_at":"2018-03-26T17:06:30Z","pushed_at":"2018-03-26T17:06:47Z","git_url":"git://github.com/RonnyPfannschmidt/pytest.git","ssh_url":"git@github.com:RonnyPfannschmidt/pytest.git","clone_url":"https://github.com/RonnyPfannschmidt/pytest.git","svn_url":"https://github.com/RonnyPfannschmidt/pytest","homepage":"http://pytest.org/","size":11790,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"features"}},"base":{"label":"pytest-dev:features","ref":"features","sha":"ed118d7f2051ccfdb5c56cb6535e6f89485b1225","user":{"login":"pytest-dev","id":8897583,"avatar_url":"https://avatars2.githubusercontent.com/u/8897583?v=4","gravatar_id":"","url":"https://api.github.com/users/pytest-dev","html_url":"https://github.com/pytest-dev","followers_url":"https://api.github.com/users/pytest-dev/followers","following_url":"https://api.github.com/users/pytest-dev/following{/other_user}","gists_url":"https://api.github.com/users/pytest-dev/gists{/gist_id}","starred_url":"https://api.github.com/users/pytest-dev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pytest-dev/subscriptions","organizations_url":"https://api.github.com/users/pytest-dev/orgs","repos_url":"https://api.github.com/users/pytest-dev/repos","events_url":"https://api.github.com/users/pytest-dev/events{/privacy}","received_events_url":"https://api.github.com/users/pytest-dev/received_events","type":"Organization","site_admin":false},"repo":{"id":37489525,"name":"pytest","full_name":"pytest-dev/pytest","owner":{"login":"pytest-dev","id":8897583,"avatar_url":"https://avatars2.githubusercontent.com/u/8897583?v=4","gravatar_id":"","url":"https://api.github.com/users/pytest-dev","html_url":"https://github.com/pytest-dev","followers_url":"https://api.github.com/users/pytest-dev/followers","following_url":"https://api.github.com/users/pytest-dev/following{/other_user}","gists_url":"https://api.github.com/users/pytest-dev/gists{/gist_id}","starred_url":"https://api.github.com/users/pytest-dev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pytest-dev/subscriptions","organizations_url":"https://api.github.com/users/pytest-dev/orgs","repos_url":"https://api.github.com/users/pytest-dev/repos","events_url":"https://api.github.com/users/pytest-dev/events{/privacy}","received_events_url":"https://api.github.com/users/pytest-dev/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/pytest-dev/pytest","description":"The pytest framework makes it easy to write small tests, yet scales to support complex functional testing","fork":false,"url":"https://api.github.com/repos/pytest-dev/pytest","forks_url":"https://api.github.com/repos/pytest-dev/pytest/forks","keys_url":"https://api.github.com/repos/pytest-dev/pytest/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pytest-dev/pytest/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pytest-dev/pytest/teams","hooks_url":"https://api.github.com/repos/pytest-dev/pytest/hooks","issue_events_url":"https://api.github.com/repos/pytest-dev/pytest/issues/events{/number}","events_url":"https://api.github.com/repos/pytest-dev/pytest/events","assignees_url":"https://api.github.com/repos/pytest-dev/pytest/assignees{/user}","branches_url":"https://api.github.com/repos/pytest-dev/pytest/branches{/branch}","tags_url":"https://api.github.com/repos/pytest-dev/pytest/tags","blobs_url":"https://api.github.com/repos/pytest-dev/pytest/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pytest-dev/pytest/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pytest-dev/pytest/git/refs{/sha}","trees_url":"https://api.github.com/repos/pytest-dev/pytest/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pytest-dev/pytest/statuses/{sha}","languages_url":"https://api.github.com/repos/pytest-dev/pytest/languages","stargazers_url":"https://api.github.com/repos/pytest-dev/pytest/stargazers","contributors_url":"https://api.github.com/repos/pytest-dev/pytest/contributors","subscribers_url":"https://api.github.com/repos/pytest-dev/pytest/subscribers","subscription_url":"https://api.github.com/repos/pytest-dev/pytest/subscription","commits_url":"https://api.github.com/repos/pytest-dev/pytest/commits{/sha}","git_commits_url":"https://api.github.com/repos/pytest-dev/pytest/git/commits{/sha}","comments_url":"https://api.github.com/repos/pytest-dev/pytest/comments{/number}","issue_comment_url":"https://api.github.com/repos/pytest-dev/pytest/issues/comments{/number}","contents_url":"https://api.github.com/repos/pytest-dev/pytest/contents/{+path}","compare_url":"https://api.github.com/repos/pytest-dev/pytest/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pytest-dev/pytest/merges","archive_url":"https://api.github.com/repos/pytest-dev/pytest/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pytest-dev/pytest/downloads","issues_url":"https://api.github.com/repos/pytest-dev/pytest/issues{/number}","pulls_url":"https://api.github.com/repos/pytest-dev/pytest/pulls{/number}","milestones_url":"https://api.github.com/repos/pytest-dev/pytest/milestones{/number}","notifications_url":"https://api.github.com/repos/pytest-dev/pytest/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pytest-dev/pytest/labels{/name}","releases_url":"https://api.github.com/repos/pytest-dev/pytest/releases{/id}","deployments_url":"https://api.github.com/repos/pytest-dev/pytest/deployments","created_at":"2015-06-15T20:28:27Z","updated_at":"2018-03-27T20:08:47Z","pushed_at":"2018-03-27T10:49:36Z","git_url":"git://github.com/pytest-dev/pytest.git","ssh_url":"git@github.com:pytest-dev/pytest.git","clone_url":"https://github.com/pytest-dev/pytest.git","svn_url":"https://github.com/pytest-dev/pytest","homepage":"http://pytest.org/","size":11821,"stargazers_count":2359,"watchers_count":2359,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":608,"mirror_url":null,"archived":false,"open_issues_count":439,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":608,"open_issues":439,"watchers":2359,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pytest-dev/pytest/pulls/3317"},"html":{"href":"https://github.com/pytest-dev/pytest/pull/3317"},"issue":{"href":"https://api.github.com/repos/pytest-dev/pytest/issues/3317"},"comments":{"href":"https://api.github.com/repos/pytest-dev/pytest/issues/3317/comments"},"review_comments":{"href":"https://api.github.com/repos/pytest-dev/pytest/pulls/3317/comments"},"review_comment":{"href":"https://api.github.com/repos/pytest-dev/pytest/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pytest-dev/pytest/pulls/3317/commits"},"statuses":{"href":"https://api.github.com/repos/pytest-dev/pytest/statuses/ff04a92cfbc747ede457b13fbf6f4595cfb58e1a"}},"author_association":"OWNER"}}
{"actor":{"display_login":"flub"}}