{"action":"created","comment":{"url":"https://api.github.com/repos/endlessm/endless-ndn/pulls/comments/94001983","pull_request_review_id":14532018,"id":94001983,"diff_hunk":"@@ -0,0 +1,51 @@\n+#!/usr/bin/python\n+# -*- Mode:python; coding: utf-8; c-file-style:\"gnu\"; indent-tabs-mode:nil -*- */\n+#\n+# Copyright (C) 2016 Endless Computers INC.\n+# Author: Niv Sardi <xaiki@endlessm.com>\n+#\n+# This program is free software: you can redistribute it and/or modify\n+# it under the terms of the GNU Lesser General Public License as published by\n+# the Free Software Foundation, either version 3 of the License, or\n+# (at your option) any later version.\n+#\n+# This program is distributed in the hope that it will be useful,\n+# but WITHOUT ANY WARRANTY; without even the implied warranty of\n+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n+# GNU Lesser General Public License for more details.\n+#\n+# You should have received a copy of the GNU Lesser General Public License\n+# along with this program.  If not, see <http://www.gnu.org/licenses/>.\n+# A copy of the GNU Lesser General Public License is in the file COPYING.\n+\n+import logging\n+\n+from pyndn import Name\n+\n+from . import http\n+from . import chunks\n+\n+logger = logging.getLogger(__name__)\n+\n+# the manifest producer is an http Producer that answers on a different name\n+class Producer(chunks.Producer):\n+    def __init__(self, name, url, session=None, *args, **kwargs):\n+        self._getter = http.Getter(url, session)\n+        self._getter.connect('data', lambda o, d: self.sendFinish(d))\n+\n+        # XXX -- we mangle the name in the constructor, this is slow\n+        self._reply_name = Name(name).append(self._getter._last_modified)","path":"eos_data_distribution/ndn/manifest.py","position":37,"original_position":37,"commit_id":"f753e77dfa50b80c4c662b4c37b90ebf13bfdbc1","original_commit_id":"d444fb806c8b5e534e71ca547ef308d1150cc5c0","user":{"login":"xaiki","id":127133,"avatar_url":"https://avatars.githubusercontent.com/u/127133?v=3","gravatar_id":"","url":"https://api.github.com/users/xaiki","html_url":"https://github.com/xaiki","followers_url":"https://api.github.com/users/xaiki/followers","following_url":"https://api.github.com/users/xaiki/following{/other_user}","gists_url":"https://api.github.com/users/xaiki/gists{/gist_id}","starred_url":"https://api.github.com/users/xaiki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xaiki/subscriptions","organizations_url":"https://api.github.com/users/xaiki/orgs","repos_url":"https://api.github.com/users/xaiki/repos","events_url":"https://api.github.com/users/xaiki/events{/privacy}","received_events_url":"https://api.github.com/users/xaiki/received_events","type":"User","site_admin":false},"body":"the store asks for the name without the timestamp asking for the <right most child> the higher date wins, no need to know about the date. it's not really a timestamp, it should be a version number, but we don't have that.","created_at":"2016-12-28T07:29:34Z","updated_at":"2016-12-28T07:29:34Z","html_url":"https://github.com/endlessm/endless-ndn/pull/5#discussion_r94001983","pull_request_url":"https://api.github.com/repos/endlessm/endless-ndn/pulls/5","_links":{"self":{"href":"https://api.github.com/repos/endlessm/endless-ndn/pulls/comments/94001983"},"html":{"href":"https://github.com/endlessm/endless-ndn/pull/5#discussion_r94001983"},"pull_request":{"href":"https://api.github.com/repos/endlessm/endless-ndn/pulls/5"}}},"pull_request":{"url":"https://api.github.com/repos/endlessm/endless-ndn/pulls/5","id":99168416,"html_url":"https://github.com/endlessm/endless-ndn/pull/5","diff_url":"https://github.com/endlessm/endless-ndn/pull/5.diff","patch_url":"https://github.com/endlessm/endless-ndn/pull/5.patch","issue_url":"https://api.github.com/repos/endlessm/endless-ndn/issues/5","number":5,"state":"open","locked":false,"title":"Xaiki/re request","user":{"login":"xaiki","id":127133,"avatar_url":"https://avatars.githubusercontent.com/u/127133?v=3","gravatar_id":"","url":"https://api.github.com/users/xaiki","html_url":"https://github.com/xaiki","followers_url":"https://api.github.com/users/xaiki/followers","following_url":"https://api.github.com/users/xaiki/following{/other_user}","gists_url":"https://api.github.com/users/xaiki/gists{/gist_id}","starred_url":"https://api.github.com/users/xaiki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xaiki/subscriptions","organizations_url":"https://api.github.com/users/xaiki/orgs","repos_url":"https://api.github.com/users/xaiki/repos","events_url":"https://api.github.com/users/xaiki/events{/privacy}","received_events_url":"https://api.github.com/users/xaiki/received_events","type":"User","site_admin":false},"body":"this moves a bunch of things around but really goes towards the goal of making re-request work.\r\n\r\nso re-request works by having the date in the name for manifest.json, we do this by supperclassing the http getter and splitting the http only function into another class (http.Getter)\r\n\r\nstill WIP.","created_at":"2016-12-22T20:54:53Z","updated_at":"2016-12-28T07:29:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a9879a53d0de78407c76ee7b40dcf8d98aced484","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/endlessm/endless-ndn/pulls/5/commits","review_comments_url":"https://api.github.com/repos/endlessm/endless-ndn/pulls/5/comments","review_comment_url":"https://api.github.com/repos/endlessm/endless-ndn/pulls/comments{/number}","comments_url":"https://api.github.com/repos/endlessm/endless-ndn/issues/5/comments","statuses_url":"https://api.github.com/repos/endlessm/endless-ndn/statuses/f753e77dfa50b80c4c662b4c37b90ebf13bfdbc1","head":{"label":"endlessm:xaiki/re-request","ref":"xaiki/re-request","sha":"f753e77dfa50b80c4c662b4c37b90ebf13bfdbc1","user":{"login":"endlessm","id":1930958,"avatar_url":"https://avatars.githubusercontent.com/u/1930958?v=3","gravatar_id":"","url":"https://api.github.com/users/endlessm","html_url":"https://github.com/endlessm","followers_url":"https://api.github.com/users/endlessm/followers","following_url":"https://api.github.com/users/endlessm/following{/other_user}","gists_url":"https://api.github.com/users/endlessm/gists{/gist_id}","starred_url":"https://api.github.com/users/endlessm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/endlessm/subscriptions","organizations_url":"https://api.github.com/users/endlessm/orgs","repos_url":"https://api.github.com/users/endlessm/repos","events_url":"https://api.github.com/users/endlessm/events{/privacy}","received_events_url":"https://api.github.com/users/endlessm/received_events","type":"Organization","site_admin":false},"repo":{"id":69488186,"name":"endless-ndn","full_name":"endlessm/endless-ndn","owner":{"login":"endlessm","id":1930958,"avatar_url":"https://avatars.githubusercontent.com/u/1930958?v=3","gravatar_id":"","url":"https://api.github.com/users/endlessm","html_url":"https://github.com/endlessm","followers_url":"https://api.github.com/users/endlessm/followers","following_url":"https://api.github.com/users/endlessm/following{/other_user}","gists_url":"https://api.github.com/users/endlessm/gists{/gist_id}","starred_url":"https://api.github.com/users/endlessm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/endlessm/subscriptions","organizations_url":"https://api.github.com/users/endlessm/orgs","repos_url":"https://api.github.com/users/endlessm/repos","events_url":"https://api.github.com/users/endlessm/events{/privacy}","received_events_url":"https://api.github.com/users/endlessm/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/endlessm/endless-ndn","description":"NDN-based data distribution","fork":false,"url":"https://api.github.com/repos/endlessm/endless-ndn","forks_url":"https://api.github.com/repos/endlessm/endless-ndn/forks","keys_url":"https://api.github.com/repos/endlessm/endless-ndn/keys{/key_id}","collaborators_url":"https://api.github.com/repos/endlessm/endless-ndn/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/endlessm/endless-ndn/teams","hooks_url":"https://api.github.com/repos/endlessm/endless-ndn/hooks","issue_events_url":"https://api.github.com/repos/endlessm/endless-ndn/issues/events{/number}","events_url":"https://api.github.com/repos/endlessm/endless-ndn/events","assignees_url":"https://api.github.com/repos/endlessm/endless-ndn/assignees{/user}","branches_url":"https://api.github.com/repos/endlessm/endless-ndn/branches{/branch}","tags_url":"https://api.github.com/repos/endlessm/endless-ndn/tags","blobs_url":"https://api.github.com/repos/endlessm/endless-ndn/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/endlessm/endless-ndn/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/endlessm/endless-ndn/git/refs{/sha}","trees_url":"https://api.github.com/repos/endlessm/endless-ndn/git/trees{/sha}","statuses_url":"https://api.github.com/repos/endlessm/endless-ndn/statuses/{sha}","languages_url":"https://api.github.com/repos/endlessm/endless-ndn/languages","stargazers_url":"https://api.github.com/repos/endlessm/endless-ndn/stargazers","contributors_url":"https://api.github.com/repos/endlessm/endless-ndn/contributors","subscribers_url":"https://api.github.com/repos/endlessm/endless-ndn/subscribers","subscription_url":"https://api.github.com/repos/endlessm/endless-ndn/subscription","commits_url":"https://api.github.com/repos/endlessm/endless-ndn/commits{/sha}","git_commits_url":"https://api.github.com/repos/endlessm/endless-ndn/git/commits{/sha}","comments_url":"https://api.github.com/repos/endlessm/endless-ndn/comments{/number}","issue_comment_url":"https://api.github.com/repos/endlessm/endless-ndn/issues/comments{/number}","contents_url":"https://api.github.com/repos/endlessm/endless-ndn/contents/{+path}","compare_url":"https://api.github.com/repos/endlessm/endless-ndn/compare/{base}...{head}","merges_url":"https://api.github.com/repos/endlessm/endless-ndn/merges","archive_url":"https://api.github.com/repos/endlessm/endless-ndn/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/endlessm/endless-ndn/downloads","issues_url":"https://api.github.com/repos/endlessm/endless-ndn/issues{/number}","pulls_url":"https://api.github.com/repos/endlessm/endless-ndn/pulls{/number}","milestones_url":"https://api.github.com/repos/endlessm/endless-ndn/milestones{/number}","notifications_url":"https://api.github.com/repos/endlessm/endless-ndn/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/endlessm/endless-ndn/labels{/name}","releases_url":"https://api.github.com/repos/endlessm/endless-ndn/releases{/id}","deployments_url":"https://api.github.com/repos/endlessm/endless-ndn/deployments","created_at":"2016-09-28T17:41:05Z","updated_at":"2016-11-27T16:49:03Z","pushed_at":"2016-12-28T00:42:44Z","git_url":"git://github.com/endlessm/endless-ndn.git","ssh_url":"git@github.com:endlessm/endless-ndn.git","clone_url":"https://github.com/endlessm/endless-ndn.git","svn_url":"https://github.com/endlessm/endless-ndn","homepage":null,"size":280,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"endlessm:master","ref":"master","sha":"809f6fc26acca45ca5593556112ff8c9708c9d9a","user":{"login":"endlessm","id":1930958,"avatar_url":"https://avatars.githubusercontent.com/u/1930958?v=3","gravatar_id":"","url":"https://api.github.com/users/endlessm","html_url":"https://github.com/endlessm","followers_url":"https://api.github.com/users/endlessm/followers","following_url":"https://api.github.com/users/endlessm/following{/other_user}","gists_url":"https://api.github.com/users/endlessm/gists{/gist_id}","starred_url":"https://api.github.com/users/endlessm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/endlessm/subscriptions","organizations_url":"https://api.github.com/users/endlessm/orgs","repos_url":"https://api.github.com/users/endlessm/repos","events_url":"https://api.github.com/users/endlessm/events{/privacy}","received_events_url":"https://api.github.com/users/endlessm/received_events","type":"Organization","site_admin":false},"repo":{"id":69488186,"name":"endless-ndn","full_name":"endlessm/endless-ndn","owner":{"login":"endlessm","id":1930958,"avatar_url":"https://avatars.githubusercontent.com/u/1930958?v=3","gravatar_id":"","url":"https://api.github.com/users/endlessm","html_url":"https://github.com/endlessm","followers_url":"https://api.github.com/users/endlessm/followers","following_url":"https://api.github.com/users/endlessm/following{/other_user}","gists_url":"https://api.github.com/users/endlessm/gists{/gist_id}","starred_url":"https://api.github.com/users/endlessm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/endlessm/subscriptions","organizations_url":"https://api.github.com/users/endlessm/orgs","repos_url":"https://api.github.com/users/endlessm/repos","events_url":"https://api.github.com/users/endlessm/events{/privacy}","received_events_url":"https://api.github.com/users/endlessm/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/endlessm/endless-ndn","description":"NDN-based data distribution","fork":false,"url":"https://api.github.com/repos/endlessm/endless-ndn","forks_url":"https://api.github.com/repos/endlessm/endless-ndn/forks","keys_url":"https://api.github.com/repos/endlessm/endless-ndn/keys{/key_id}","collaborators_url":"https://api.github.com/repos/endlessm/endless-ndn/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/endlessm/endless-ndn/teams","hooks_url":"https://api.github.com/repos/endlessm/endless-ndn/hooks","issue_events_url":"https://api.github.com/repos/endlessm/endless-ndn/issues/events{/number}","events_url":"https://api.github.com/repos/endlessm/endless-ndn/events","assignees_url":"https://api.github.com/repos/endlessm/endless-ndn/assignees{/user}","branches_url":"https://api.github.com/repos/endlessm/endless-ndn/branches{/branch}","tags_url":"https://api.github.com/repos/endlessm/endless-ndn/tags","blobs_url":"https://api.github.com/repos/endlessm/endless-ndn/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/endlessm/endless-ndn/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/endlessm/endless-ndn/git/refs{/sha}","trees_url":"https://api.github.com/repos/endlessm/endless-ndn/git/trees{/sha}","statuses_url":"https://api.github.com/repos/endlessm/endless-ndn/statuses/{sha}","languages_url":"https://api.github.com/repos/endlessm/endless-ndn/languages","stargazers_url":"https://api.github.com/repos/endlessm/endless-ndn/stargazers","contributors_url":"https://api.github.com/repos/endlessm/endless-ndn/contributors","subscribers_url":"https://api.github.com/repos/endlessm/endless-ndn/subscribers","subscription_url":"https://api.github.com/repos/endlessm/endless-ndn/subscription","commits_url":"https://api.github.com/repos/endlessm/endless-ndn/commits{/sha}","git_commits_url":"https://api.github.com/repos/endlessm/endless-ndn/git/commits{/sha}","comments_url":"https://api.github.com/repos/endlessm/endless-ndn/comments{/number}","issue_comment_url":"https://api.github.com/repos/endlessm/endless-ndn/issues/comments{/number}","contents_url":"https://api.github.com/repos/endlessm/endless-ndn/contents/{+path}","compare_url":"https://api.github.com/repos/endlessm/endless-ndn/compare/{base}...{head}","merges_url":"https://api.github.com/repos/endlessm/endless-ndn/merges","archive_url":"https://api.github.com/repos/endlessm/endless-ndn/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/endlessm/endless-ndn/downloads","issues_url":"https://api.github.com/repos/endlessm/endless-ndn/issues{/number}","pulls_url":"https://api.github.com/repos/endlessm/endless-ndn/pulls{/number}","milestones_url":"https://api.github.com/repos/endlessm/endless-ndn/milestones{/number}","notifications_url":"https://api.github.com/repos/endlessm/endless-ndn/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/endlessm/endless-ndn/labels{/name}","releases_url":"https://api.github.com/repos/endlessm/endless-ndn/releases{/id}","deployments_url":"https://api.github.com/repos/endlessm/endless-ndn/deployments","created_at":"2016-09-28T17:41:05Z","updated_at":"2016-11-27T16:49:03Z","pushed_at":"2016-12-28T00:42:44Z","git_url":"git://github.com/endlessm/endless-ndn.git","ssh_url":"git@github.com:endlessm/endless-ndn.git","clone_url":"https://github.com/endlessm/endless-ndn.git","svn_url":"https://github.com/endlessm/endless-ndn","homepage":null,"size":280,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/endlessm/endless-ndn/pulls/5"},"html":{"href":"https://github.com/endlessm/endless-ndn/pull/5"},"issue":{"href":"https://api.github.com/repos/endlessm/endless-ndn/issues/5"},"comments":{"href":"https://api.github.com/repos/endlessm/endless-ndn/issues/5/comments"},"review_comments":{"href":"https://api.github.com/repos/endlessm/endless-ndn/pulls/5/comments"},"review_comment":{"href":"https://api.github.com/repos/endlessm/endless-ndn/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/endlessm/endless-ndn/pulls/5/commits"},"statuses":{"href":"https://api.github.com/repos/endlessm/endless-ndn/statuses/f753e77dfa50b80c4c662b4c37b90ebf13bfdbc1"}}}}
{"actor":{"display_login":"xaiki"}}