{"action":"created","comment":{"url":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/comments/24186789","id":24186789,"diff_hunk":"@@ -0,0 +1,104 @@\n+#!/usr/bin/env python\n+#\n+# Public Domain 2014-2015 MongoDB, Inc.\n+# Public Domain 2008-2014 WiredTiger, Inc.\n+#\n+# This is free and unencumbered software released into the public domain.\n+#\n+# Anyone is free to copy, modify, publish, use, compile, sell, or\n+# distribute this software, either in source code form or as a compiled\n+# binary, for any purpose, commercial or non-commercial, and by any\n+# means.\n+#\n+# In jurisdictions that recognize copyright laws, the author or authors\n+# of this software dedicate any and all copyright interest in the\n+# software to the public domain. We make this dedication for the benefit\n+# of the public at large and to the detriment of our heirs and\n+# successors. We intend this dedication to be an overt act of\n+# relinquishment in perpetuity of all present and future rights to this\n+# software under copyright law.\n+#\n+# THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n+# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n+# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.\n+# IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR\n+# OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,\n+# ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR\n+# OTHER DEALINGS IN THE SOFTWARE.\n+#\n+# test_cursor07.py\n+# Log cursors\n+#\n+\n+import fnmatch, os, shutil, run, time\n+from suite_subprocess import suite_subprocess\n+from wiredtiger import wiredtiger_open, stat\n+from wtscenario import multiply_scenarios, number_scenarios\n+import wttest\n+\n+class test_cursor07(wttest.WiredTigerTestCase, suite_subprocess):\n+    logmax = \"100K\"\n+    tablename = 'test_cursor07'\n+    uri = 'table:' + tablename\n+    nkeys = 5\n+\n+    scenarios = [\n+        ('regular', dict(reopen=False)),\n+        ('reopen', dict(reopen=True))\n+    ]\n+\n+    # Overrides WiredTigerTestCase - add logging\n+    def setUpConnectionOpen(self, dir):\n+        self.home = dir\n+        self.txn_sync = '(method=dsync,enabled)'\n+        conn_params = \\\n+                'log=(archive=false,enabled,file_max=%s)' % self.logmax + \\\n+                ',create,error_prefix=\"%s: \",' % self.shortid() + \\\n+                'transaction_sync=\"%s\",' % self.txn_sync\n+        # print \"Creating conn at '%s' with config '%s'\" % (dir, conn_params)\n+        try:\n+            conn = wiredtiger_open(dir, conn_params)\n+        except wiredtiger.WiredTigerError as e:\n+            print \"Failed conn at '%s' with config '%s'\" % (dir, conn_params)\n+        self.pr(`conn`)\n+        self.session2 = conn.open_session()\n+        return conn\n+\n+    def test_log_cursor(self):\n+        # print \"Creating %s with config '%s'\" % (self.uri, self.create_params)\n+        create_params = 'key_format=i,value_format=S'\n+        self.session.create(self.uri, create_params)\n+        c = self.session.open_cursor(self.uri, None)\n+\n+        # A binary value.\n+        value = u'\\u0001\\u0002abcd\\u0003\\u0004'\n+\n+        self.session.begin_transaction()\n+        for k in range(self.nkeys):\n+            c.set_key(k)\n+            c.set_value(value)\n+            c.insert()\n+        self.session.commit_transaction()\n+        c.close()\n+\n+        if self.reopen:\n+            self.reopen_conn()\n+\n+        # Check for these values via a log cursor\n+\tc = self.session.open_cursor(\"log:\", None)\n+        count = 0","path":"test/suite/test_cursor07.py","position":89,"original_position":89,"commit_id":"9607c118d06434efbb9d17708afe5a88441f1f14","original_commit_id":"9607c118d06434efbb9d17708afe5a88441f1f14","user":{"login":"sueloverso","id":2945957,"avatar_url":"https://avatars.githubusercontent.com/u/2945957?v=3","gravatar_id":"","url":"https://api.github.com/users/sueloverso","html_url":"https://github.com/sueloverso","followers_url":"https://api.github.com/users/sueloverso/followers","following_url":"https://api.github.com/users/sueloverso/following{/other_user}","gists_url":"https://api.github.com/users/sueloverso/gists{/gist_id}","starred_url":"https://api.github.com/users/sueloverso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sueloverso/subscriptions","organizations_url":"https://api.github.com/users/sueloverso/orgs","repos_url":"https://api.github.com/users/sueloverso/repos","events_url":"https://api.github.com/users/sueloverso/events{/privacy}","received_events_url":"https://api.github.com/users/sueloverso/received_events","type":"User","site_admin":false},"body":"Actually it looks like there is one space too few on line 88.","created_at":"2015-02-05T18:39:54Z","updated_at":"2015-02-05T18:39:54Z","html_url":"https://github.com/wiredtiger/wiredtiger/pull/1637#discussion_r24186789","pull_request_url":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/1637","_links":{"self":{"href":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/comments/24186789"},"html":{"href":"https://github.com/wiredtiger/wiredtiger/pull/1637#discussion_r24186789"},"pull_request":{"href":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/1637"}}},"pull_request":{"url":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/1637","id":28696347,"html_url":"https://github.com/wiredtiger/wiredtiger/pull/1637","diff_url":"https://github.com/wiredtiger/wiredtiger/pull/1637.diff","patch_url":"https://github.com/wiredtiger/wiredtiger/pull/1637.patch","issue_url":"https://api.github.com/repos/wiredtiger/wiredtiger/issues/1637","number":1637,"state":"open","locked":false,"title":"Add a simple test for log cursors.","user":{"login":"ddanderson","id":591610,"avatar_url":"https://avatars.githubusercontent.com/u/591610?v=3","gravatar_id":"","url":"https://api.github.com/users/ddanderson","html_url":"https://github.com/ddanderson","followers_url":"https://api.github.com/users/ddanderson/followers","following_url":"https://api.github.com/users/ddanderson/following{/other_user}","gists_url":"https://api.github.com/users/ddanderson/gists{/gist_id}","starred_url":"https://api.github.com/users/ddanderson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ddanderson/subscriptions","organizations_url":"https://api.github.com/users/ddanderson/orgs","repos_url":"https://api.github.com/users/ddanderson/repos","events_url":"https://api.github.com/users/ddanderson/events{/privacy}","received_events_url":"https://api.github.com/users/ddanderson/received_events","type":"User","site_admin":false},"body":"Refs #1530","created_at":"2015-02-05T03:19:37Z","updated_at":"2015-02-05T18:39:54Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e6826ca085cec8a46a44f65588803bd4d2a46e69","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/1637/commits","review_comments_url":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/1637/comments","review_comment_url":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/comments/{number}","comments_url":"https://api.github.com/repos/wiredtiger/wiredtiger/issues/1637/comments","statuses_url":"https://api.github.com/repos/wiredtiger/wiredtiger/statuses/9607c118d06434efbb9d17708afe5a88441f1f14","head":{"label":"wiredtiger:log-cursor-test","ref":"log-cursor-test","sha":"9607c118d06434efbb9d17708afe5a88441f1f14","user":{"login":"wiredtiger","id":1251095,"avatar_url":"https://avatars.githubusercontent.com/u/1251095?v=3","gravatar_id":"","url":"https://api.github.com/users/wiredtiger","html_url":"https://github.com/wiredtiger","followers_url":"https://api.github.com/users/wiredtiger/followers","following_url":"https://api.github.com/users/wiredtiger/following{/other_user}","gists_url":"https://api.github.com/users/wiredtiger/gists{/gist_id}","starred_url":"https://api.github.com/users/wiredtiger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wiredtiger/subscriptions","organizations_url":"https://api.github.com/users/wiredtiger/orgs","repos_url":"https://api.github.com/users/wiredtiger/repos","events_url":"https://api.github.com/users/wiredtiger/events{/privacy}","received_events_url":"https://api.github.com/users/wiredtiger/received_events","type":"Organization","site_admin":false},"repo":{"id":2944302,"name":"wiredtiger","full_name":"wiredtiger/wiredtiger","owner":{"login":"wiredtiger","id":1251095,"avatar_url":"https://avatars.githubusercontent.com/u/1251095?v=3","gravatar_id":"","url":"https://api.github.com/users/wiredtiger","html_url":"https://github.com/wiredtiger","followers_url":"https://api.github.com/users/wiredtiger/followers","following_url":"https://api.github.com/users/wiredtiger/following{/other_user}","gists_url":"https://api.github.com/users/wiredtiger/gists{/gist_id}","starred_url":"https://api.github.com/users/wiredtiger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wiredtiger/subscriptions","organizations_url":"https://api.github.com/users/wiredtiger/orgs","repos_url":"https://api.github.com/users/wiredtiger/repos","events_url":"https://api.github.com/users/wiredtiger/events{/privacy}","received_events_url":"https://api.github.com/users/wiredtiger/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/wiredtiger/wiredtiger","description":"WiredTiger's source tree","fork":false,"url":"https://api.github.com/repos/wiredtiger/wiredtiger","forks_url":"https://api.github.com/repos/wiredtiger/wiredtiger/forks","keys_url":"https://api.github.com/repos/wiredtiger/wiredtiger/keys{/key_id}","collaborators_url":"https://api.github.com/repos/wiredtiger/wiredtiger/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/wiredtiger/wiredtiger/teams","hooks_url":"https://api.github.com/repos/wiredtiger/wiredtiger/hooks","issue_events_url":"https://api.github.com/repos/wiredtiger/wiredtiger/issues/events{/number}","events_url":"https://api.github.com/repos/wiredtiger/wiredtiger/events","assignees_url":"https://api.github.com/repos/wiredtiger/wiredtiger/assignees{/user}","branches_url":"https://api.github.com/repos/wiredtiger/wiredtiger/branches{/branch}","tags_url":"https://api.github.com/repos/wiredtiger/wiredtiger/tags","blobs_url":"https://api.github.com/repos/wiredtiger/wiredtiger/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/wiredtiger/wiredtiger/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/wiredtiger/wiredtiger/git/refs{/sha}","trees_url":"https://api.github.com/repos/wiredtiger/wiredtiger/git/trees{/sha}","statuses_url":"https://api.github.com/repos/wiredtiger/wiredtiger/statuses/{sha}","languages_url":"https://api.github.com/repos/wiredtiger/wiredtiger/languages","stargazers_url":"https://api.github.com/repos/wiredtiger/wiredtiger/stargazers","contributors_url":"https://api.github.com/repos/wiredtiger/wiredtiger/contributors","subscribers_url":"https://api.github.com/repos/wiredtiger/wiredtiger/subscribers","subscription_url":"https://api.github.com/repos/wiredtiger/wiredtiger/subscription","commits_url":"https://api.github.com/repos/wiredtiger/wiredtiger/commits{/sha}","git_commits_url":"https://api.github.com/repos/wiredtiger/wiredtiger/git/commits{/sha}","comments_url":"https://api.github.com/repos/wiredtiger/wiredtiger/comments{/number}","issue_comment_url":"https://api.github.com/repos/wiredtiger/wiredtiger/issues/comments/{number}","contents_url":"https://api.github.com/repos/wiredtiger/wiredtiger/contents/{+path}","compare_url":"https://api.github.com/repos/wiredtiger/wiredtiger/compare/{base}...{head}","merges_url":"https://api.github.com/repos/wiredtiger/wiredtiger/merges","archive_url":"https://api.github.com/repos/wiredtiger/wiredtiger/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/wiredtiger/wiredtiger/downloads","issues_url":"https://api.github.com/repos/wiredtiger/wiredtiger/issues{/number}","pulls_url":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls{/number}","milestones_url":"https://api.github.com/repos/wiredtiger/wiredtiger/milestones{/number}","notifications_url":"https://api.github.com/repos/wiredtiger/wiredtiger/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/wiredtiger/wiredtiger/labels{/name}","releases_url":"https://api.github.com/repos/wiredtiger/wiredtiger/releases{/id}","created_at":"2011-12-09T00:43:19Z","updated_at":"2015-02-05T18:21:43Z","pushed_at":"2015-02-05T18:29:09Z","git_url":"git://github.com/wiredtiger/wiredtiger.git","ssh_url":"git@github.com:wiredtiger/wiredtiger.git","clone_url":"https://github.com/wiredtiger/wiredtiger.git","svn_url":"https://github.com/wiredtiger/wiredtiger","homepage":"http://source.wiredtiger.com/","size":95833,"stargazers_count":316,"watchers_count":316,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":51,"mirror_url":null,"open_issues_count":94,"forks":51,"open_issues":94,"watchers":316,"default_branch":"master"}},"base":{"label":"wiredtiger:develop","ref":"develop","sha":"06e343db63fd90cc0755369c7231b100e0180f96","user":{"login":"wiredtiger","id":1251095,"avatar_url":"https://avatars.githubusercontent.com/u/1251095?v=3","gravatar_id":"","url":"https://api.github.com/users/wiredtiger","html_url":"https://github.com/wiredtiger","followers_url":"https://api.github.com/users/wiredtiger/followers","following_url":"https://api.github.com/users/wiredtiger/following{/other_user}","gists_url":"https://api.github.com/users/wiredtiger/gists{/gist_id}","starred_url":"https://api.github.com/users/wiredtiger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wiredtiger/subscriptions","organizations_url":"https://api.github.com/users/wiredtiger/orgs","repos_url":"https://api.github.com/users/wiredtiger/repos","events_url":"https://api.github.com/users/wiredtiger/events{/privacy}","received_events_url":"https://api.github.com/users/wiredtiger/received_events","type":"Organization","site_admin":false},"repo":{"id":2944302,"name":"wiredtiger","full_name":"wiredtiger/wiredtiger","owner":{"login":"wiredtiger","id":1251095,"avatar_url":"https://avatars.githubusercontent.com/u/1251095?v=3","gravatar_id":"","url":"https://api.github.com/users/wiredtiger","html_url":"https://github.com/wiredtiger","followers_url":"https://api.github.com/users/wiredtiger/followers","following_url":"https://api.github.com/users/wiredtiger/following{/other_user}","gists_url":"https://api.github.com/users/wiredtiger/gists{/gist_id}","starred_url":"https://api.github.com/users/wiredtiger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wiredtiger/subscriptions","organizations_url":"https://api.github.com/users/wiredtiger/orgs","repos_url":"https://api.github.com/users/wiredtiger/repos","events_url":"https://api.github.com/users/wiredtiger/events{/privacy}","received_events_url":"https://api.github.com/users/wiredtiger/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/wiredtiger/wiredtiger","description":"WiredTiger's source tree","fork":false,"url":"https://api.github.com/repos/wiredtiger/wiredtiger","forks_url":"https://api.github.com/repos/wiredtiger/wiredtiger/forks","keys_url":"https://api.github.com/repos/wiredtiger/wiredtiger/keys{/key_id}","collaborators_url":"https://api.github.com/repos/wiredtiger/wiredtiger/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/wiredtiger/wiredtiger/teams","hooks_url":"https://api.github.com/repos/wiredtiger/wiredtiger/hooks","issue_events_url":"https://api.github.com/repos/wiredtiger/wiredtiger/issues/events{/number}","events_url":"https://api.github.com/repos/wiredtiger/wiredtiger/events","assignees_url":"https://api.github.com/repos/wiredtiger/wiredtiger/assignees{/user}","branches_url":"https://api.github.com/repos/wiredtiger/wiredtiger/branches{/branch}","tags_url":"https://api.github.com/repos/wiredtiger/wiredtiger/tags","blobs_url":"https://api.github.com/repos/wiredtiger/wiredtiger/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/wiredtiger/wiredtiger/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/wiredtiger/wiredtiger/git/refs{/sha}","trees_url":"https://api.github.com/repos/wiredtiger/wiredtiger/git/trees{/sha}","statuses_url":"https://api.github.com/repos/wiredtiger/wiredtiger/statuses/{sha}","languages_url":"https://api.github.com/repos/wiredtiger/wiredtiger/languages","stargazers_url":"https://api.github.com/repos/wiredtiger/wiredtiger/stargazers","contributors_url":"https://api.github.com/repos/wiredtiger/wiredtiger/contributors","subscribers_url":"https://api.github.com/repos/wiredtiger/wiredtiger/subscribers","subscription_url":"https://api.github.com/repos/wiredtiger/wiredtiger/subscription","commits_url":"https://api.github.com/repos/wiredtiger/wiredtiger/commits{/sha}","git_commits_url":"https://api.github.com/repos/wiredtiger/wiredtiger/git/commits{/sha}","comments_url":"https://api.github.com/repos/wiredtiger/wiredtiger/comments{/number}","issue_comment_url":"https://api.github.com/repos/wiredtiger/wiredtiger/issues/comments/{number}","contents_url":"https://api.github.com/repos/wiredtiger/wiredtiger/contents/{+path}","compare_url":"https://api.github.com/repos/wiredtiger/wiredtiger/compare/{base}...{head}","merges_url":"https://api.github.com/repos/wiredtiger/wiredtiger/merges","archive_url":"https://api.github.com/repos/wiredtiger/wiredtiger/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/wiredtiger/wiredtiger/downloads","issues_url":"https://api.github.com/repos/wiredtiger/wiredtiger/issues{/number}","pulls_url":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls{/number}","milestones_url":"https://api.github.com/repos/wiredtiger/wiredtiger/milestones{/number}","notifications_url":"https://api.github.com/repos/wiredtiger/wiredtiger/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/wiredtiger/wiredtiger/labels{/name}","releases_url":"https://api.github.com/repos/wiredtiger/wiredtiger/releases{/id}","created_at":"2011-12-09T00:43:19Z","updated_at":"2015-02-05T18:21:43Z","pushed_at":"2015-02-05T18:29:09Z","git_url":"git://github.com/wiredtiger/wiredtiger.git","ssh_url":"git@github.com:wiredtiger/wiredtiger.git","clone_url":"https://github.com/wiredtiger/wiredtiger.git","svn_url":"https://github.com/wiredtiger/wiredtiger","homepage":"http://source.wiredtiger.com/","size":95833,"stargazers_count":316,"watchers_count":316,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":51,"mirror_url":null,"open_issues_count":94,"forks":51,"open_issues":94,"watchers":316,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/1637"},"html":{"href":"https://github.com/wiredtiger/wiredtiger/pull/1637"},"issue":{"href":"https://api.github.com/repos/wiredtiger/wiredtiger/issues/1637"},"comments":{"href":"https://api.github.com/repos/wiredtiger/wiredtiger/issues/1637/comments"},"review_comments":{"href":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/1637/comments"},"review_comment":{"href":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/wiredtiger/wiredtiger/pulls/1637/commits"},"statuses":{"href":"https://api.github.com/repos/wiredtiger/wiredtiger/statuses/9607c118d06434efbb9d17708afe5a88441f1f14"}}}}