{"action":"created","comment":{"url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/comments/43498818","id":43498818,"diff_hunk":"@@ -0,0 +1,40 @@\n+# -*- coding: utf-8 -*-\n+#\n+# This file is part of Invenio.\n+# Copyright (C) 2015 CERN.\n+#\n+# Invenio is free software; you can redistribute it\n+# and/or modify it under the terms of the GNU General Public License as\n+# published by the Free Software Foundation; either version 2 of the\n+# License, or (at your option) any later version.\n+#\n+# Invenio is distributed in the hope that it will be\n+# useful, but WITHOUT ANY WARRANTY; without even the implied warranty of\n+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU\n+# General Public License for more details.\n+#\n+# You should have received a copy of the GNU General Public License\n+# along with Invenio; if not, write to the\n+# Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston,\n+# MA 02111-1307, USA.\n+#\n+# In applying this license, CERN does not\n+# waive the privileges and immunities granted to it by virtue of its status\n+# as an Intergovernmental Organization or submit itself to any jurisdiction.\n+\n+\"\"\"Record ID provider.\"\"\"\n+\n+from __future__ import absolute_import, print_function\n+\n+from ..provider import LocalPidProvider\n+\n+\n+class RecordID(LocalPidProvider):\n+    \"\"\"Provider for recids.\"\"\"\n+\n+    pid_type = 'recid'\n+\n+    @classmethod\n+    def is_provider_for_pid(cls, pid_str):\n+        \"\"\"A recid is valid is it is ``None`` or ``Integer``.\"\"\"\n+        return isinstance(pid_str, int) or pid_str.isdigit()","path":"invenio_pidstore/providers/recordid.py","position":40,"original_position":40,"commit_id":"9b3f310324268f7b714a743569cc4d5f887ee504","original_commit_id":"9b3f310324268f7b714a743569cc4d5f887ee504","user":{"login":"nharraud","id":5708796,"avatar_url":"https://avatars.githubusercontent.com/u/5708796?v=3","gravatar_id":"","url":"https://api.github.com/users/nharraud","html_url":"https://github.com/nharraud","followers_url":"https://api.github.com/users/nharraud/followers","following_url":"https://api.github.com/users/nharraud/following{/other_user}","gists_url":"https://api.github.com/users/nharraud/gists{/gist_id}","starred_url":"https://api.github.com/users/nharraud/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nharraud/subscriptions","organizations_url":"https://api.github.com/users/nharraud/orgs","repos_url":"https://api.github.com/users/nharraud/repos","events_url":"https://api.github.com/users/nharraud/events{/privacy}","received_events_url":"https://api.github.com/users/nharraud/received_events","type":"User","site_admin":false},"body":"The documentation seems to say that `pid_str` can be set to `None`, which would make this line fail with `AttributeError: 'NoneType' object has no attribute 'isdigit'`.","created_at":"2015-10-30T12:58:09Z","updated_at":"2015-10-30T12:58:09Z","html_url":"https://github.com/inveniosoftware/invenio-pidstore/pull/28#discussion_r43498818","pull_request_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/28","_links":{"self":{"href":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/comments/43498818"},"html":{"href":"https://github.com/inveniosoftware/invenio-pidstore/pull/28#discussion_r43498818"},"pull_request":{"href":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/28"}}},"pull_request":{"url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/28","id":49151683,"html_url":"https://github.com/inveniosoftware/invenio-pidstore/pull/28","diff_url":"https://github.com/inveniosoftware/invenio-pidstore/pull/28.diff","patch_url":"https://github.com/inveniosoftware/invenio-pidstore/pull/28.patch","issue_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/issues/28","number":28,"state":"open","locked":false,"title":"resolver: pid to internal object resolving","user":{"login":"lnielsen","id":1698163,"avatar_url":"https://avatars.githubusercontent.com/u/1698163?v=3","gravatar_id":"","url":"https://api.github.com/users/lnielsen","html_url":"https://github.com/lnielsen","followers_url":"https://api.github.com/users/lnielsen/followers","following_url":"https://api.github.com/users/lnielsen/following{/other_user}","gists_url":"https://api.github.com/users/lnielsen/gists{/gist_id}","starred_url":"https://api.github.com/users/lnielsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lnielsen/subscriptions","organizations_url":"https://api.github.com/users/lnielsen/orgs","repos_url":"https://api.github.com/users/lnielsen/repos","events_url":"https://api.github.com/users/lnielsen/events{/privacy}","received_events_url":"https://api.github.com/users/lnielsen/received_events","type":"User","site_admin":false},"body":"* Adds helper class to retrieve an internal object for a given\r\n  persistent identifier.\r\n\r\n* Adds temporarily record id provider.\r\n\r\n* NOTE PIDStore needs a larger refactoring in order to scale up and\r\n  API is very likely to change.\r\n\r\nSigned-off-by: Lars Holm Nielsen <lars.holm.nielsen@cern.ch>","created_at":"2015-10-29T15:04:49Z","updated_at":"2015-10-30T12:58:09Z","closed_at":null,"merged_at":null,"merge_commit_sha":"18379f0c8bca4199cfcfd71bf57dd80ff5942e1d","assignee":{"login":"nharraud","id":5708796,"avatar_url":"https://avatars.githubusercontent.com/u/5708796?v=3","gravatar_id":"","url":"https://api.github.com/users/nharraud","html_url":"https://github.com/nharraud","followers_url":"https://api.github.com/users/nharraud/followers","following_url":"https://api.github.com/users/nharraud/following{/other_user}","gists_url":"https://api.github.com/users/nharraud/gists{/gist_id}","starred_url":"https://api.github.com/users/nharraud/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nharraud/subscriptions","organizations_url":"https://api.github.com/users/nharraud/orgs","repos_url":"https://api.github.com/users/nharraud/repos","events_url":"https://api.github.com/users/nharraud/events{/privacy}","received_events_url":"https://api.github.com/users/nharraud/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/milestones/7","html_url":"https://github.com/inveniosoftware/invenio-pidstore/milestones/v1.0.0","labels_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/milestones/7/labels","id":1363884,"number":7,"title":"v1.0.0","description":null,"creator":{"login":"jirikuncar","id":189798,"avatar_url":"https://avatars.githubusercontent.com/u/189798?v=3","gravatar_id":"","url":"https://api.github.com/users/jirikuncar","html_url":"https://github.com/jirikuncar","followers_url":"https://api.github.com/users/jirikuncar/followers","following_url":"https://api.github.com/users/jirikuncar/following{/other_user}","gists_url":"https://api.github.com/users/jirikuncar/gists{/gist_id}","starred_url":"https://api.github.com/users/jirikuncar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jirikuncar/subscriptions","organizations_url":"https://api.github.com/users/jirikuncar/orgs","repos_url":"https://api.github.com/users/jirikuncar/repos","events_url":"https://api.github.com/users/jirikuncar/events{/privacy}","received_events_url":"https://api.github.com/users/jirikuncar/received_events","type":"User","site_admin":false},"open_issues":6,"closed_issues":3,"state":"open","created_at":"2015-10-19T13:13:43Z","updated_at":"2015-10-30T11:57:12Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/28/commits","review_comments_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/28/comments","review_comment_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/comments{/number}","comments_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/issues/28/comments","statuses_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/statuses/9b3f310324268f7b714a743569cc4d5f887ee504","head":{"label":"lnielsen:next-records-ui","ref":"next-records-ui","sha":"9b3f310324268f7b714a743569cc4d5f887ee504","user":{"login":"lnielsen","id":1698163,"avatar_url":"https://avatars.githubusercontent.com/u/1698163?v=3","gravatar_id":"","url":"https://api.github.com/users/lnielsen","html_url":"https://github.com/lnielsen","followers_url":"https://api.github.com/users/lnielsen/followers","following_url":"https://api.github.com/users/lnielsen/following{/other_user}","gists_url":"https://api.github.com/users/lnielsen/gists{/gist_id}","starred_url":"https://api.github.com/users/lnielsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lnielsen/subscriptions","organizations_url":"https://api.github.com/users/lnielsen/orgs","repos_url":"https://api.github.com/users/lnielsen/repos","events_url":"https://api.github.com/users/lnielsen/events{/privacy}","received_events_url":"https://api.github.com/users/lnielsen/received_events","type":"User","site_admin":false},"repo":{"id":41531871,"name":"invenio-pidstore","full_name":"lnielsen/invenio-pidstore","owner":{"login":"lnielsen","id":1698163,"avatar_url":"https://avatars.githubusercontent.com/u/1698163?v=3","gravatar_id":"","url":"https://api.github.com/users/lnielsen","html_url":"https://github.com/lnielsen","followers_url":"https://api.github.com/users/lnielsen/followers","following_url":"https://api.github.com/users/lnielsen/following{/other_user}","gists_url":"https://api.github.com/users/lnielsen/gists{/gist_id}","starred_url":"https://api.github.com/users/lnielsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lnielsen/subscriptions","organizations_url":"https://api.github.com/users/lnielsen/orgs","repos_url":"https://api.github.com/users/lnielsen/repos","events_url":"https://api.github.com/users/lnielsen/events{/privacy}","received_events_url":"https://api.github.com/users/lnielsen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/lnielsen/invenio-pidstore","description":"Invenio module that stores and registers persistent identifiers.","fork":true,"url":"https://api.github.com/repos/lnielsen/invenio-pidstore","forks_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/forks","keys_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/teams","hooks_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/hooks","issue_events_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/issues/events{/number}","events_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/events","assignees_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/assignees{/user}","branches_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/branches{/branch}","tags_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/tags","blobs_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/git/refs{/sha}","trees_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/statuses/{sha}","languages_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/languages","stargazers_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/stargazers","contributors_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/contributors","subscribers_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/subscribers","subscription_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/subscription","commits_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/commits{/sha}","git_commits_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/git/commits{/sha}","comments_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/comments{/number}","issue_comment_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/issues/comments{/number}","contents_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/contents/{+path}","compare_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/merges","archive_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/downloads","issues_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/issues{/number}","pulls_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/pulls{/number}","milestones_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/milestones{/number}","notifications_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/labels{/name}","releases_url":"https://api.github.com/repos/lnielsen/invenio-pidstore/releases{/id}","created_at":"2015-08-28T06:50:18Z","updated_at":"2015-08-28T06:50:18Z","pushed_at":"2015-10-30T11:56:29Z","git_url":"git://github.com/lnielsen/invenio-pidstore.git","ssh_url":"git@github.com:lnielsen/invenio-pidstore.git","clone_url":"https://github.com/lnielsen/invenio-pidstore.git","svn_url":"https://github.com/lnielsen/invenio-pidstore","homepage":"","size":253,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"inveniosoftware:next","ref":"next","sha":"f023804cd639eb20161a82211addd1e1165b362b","user":{"login":"inveniosoftware","id":1157480,"avatar_url":"https://avatars.githubusercontent.com/u/1157480?v=3","gravatar_id":"","url":"https://api.github.com/users/inveniosoftware","html_url":"https://github.com/inveniosoftware","followers_url":"https://api.github.com/users/inveniosoftware/followers","following_url":"https://api.github.com/users/inveniosoftware/following{/other_user}","gists_url":"https://api.github.com/users/inveniosoftware/gists{/gist_id}","starred_url":"https://api.github.com/users/inveniosoftware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/inveniosoftware/subscriptions","organizations_url":"https://api.github.com/users/inveniosoftware/orgs","repos_url":"https://api.github.com/users/inveniosoftware/repos","events_url":"https://api.github.com/users/inveniosoftware/events{/privacy}","received_events_url":"https://api.github.com/users/inveniosoftware/received_events","type":"Organization","site_admin":false},"repo":{"id":39133678,"name":"invenio-pidstore","full_name":"inveniosoftware/invenio-pidstore","owner":{"login":"inveniosoftware","id":1157480,"avatar_url":"https://avatars.githubusercontent.com/u/1157480?v=3","gravatar_id":"","url":"https://api.github.com/users/inveniosoftware","html_url":"https://github.com/inveniosoftware","followers_url":"https://api.github.com/users/inveniosoftware/followers","following_url":"https://api.github.com/users/inveniosoftware/following{/other_user}","gists_url":"https://api.github.com/users/inveniosoftware/gists{/gist_id}","starred_url":"https://api.github.com/users/inveniosoftware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/inveniosoftware/subscriptions","organizations_url":"https://api.github.com/users/inveniosoftware/orgs","repos_url":"https://api.github.com/users/inveniosoftware/repos","events_url":"https://api.github.com/users/inveniosoftware/events{/privacy}","received_events_url":"https://api.github.com/users/inveniosoftware/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/inveniosoftware/invenio-pidstore","description":"Invenio module that stores and registers persistent identifiers.","fork":false,"url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore","forks_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/forks","keys_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/keys{/key_id}","collaborators_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/teams","hooks_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/hooks","issue_events_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/issues/events{/number}","events_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/events","assignees_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/assignees{/user}","branches_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/branches{/branch}","tags_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/tags","blobs_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/git/refs{/sha}","trees_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/git/trees{/sha}","statuses_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/statuses/{sha}","languages_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/languages","stargazers_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/stargazers","contributors_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/contributors","subscribers_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/subscribers","subscription_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/subscription","commits_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/commits{/sha}","git_commits_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/git/commits{/sha}","comments_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/comments{/number}","issue_comment_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/issues/comments{/number}","contents_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/contents/{+path}","compare_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/compare/{base}...{head}","merges_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/merges","archive_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/downloads","issues_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/issues{/number}","pulls_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls{/number}","milestones_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/milestones{/number}","notifications_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/labels{/name}","releases_url":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/releases{/id}","created_at":"2015-07-15T11:40:54Z","updated_at":"2015-08-19T12:52:03Z","pushed_at":"2015-10-30T12:50:03Z","git_url":"git://github.com/inveniosoftware/invenio-pidstore.git","ssh_url":"git@github.com:inveniosoftware/invenio-pidstore.git","clone_url":"https://github.com/inveniosoftware/invenio-pidstore.git","svn_url":"https://github.com/inveniosoftware/invenio-pidstore","homepage":"","size":857,"stargazers_count":1,"watchers_count":1,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":12,"mirror_url":null,"open_issues_count":12,"forks":12,"open_issues":12,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/28"},"html":{"href":"https://github.com/inveniosoftware/invenio-pidstore/pull/28"},"issue":{"href":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/issues/28"},"comments":{"href":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/issues/28/comments"},"review_comments":{"href":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/28/comments"},"review_comment":{"href":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/pulls/28/commits"},"statuses":{"href":"https://api.github.com/repos/inveniosoftware/invenio-pidstore/statuses/9b3f310324268f7b714a743569cc4d5f887ee504"}}}}