{"action":"created","comment":{"url":"https://api.github.com/repos/mldbai/mldb/pulls/comments/51724677","id":51724677,"diff_hunk":"@@ -0,0 +1,47 @@\n+#\n+# MLDBFB-192_row_name_as_string_test.py\n+# Mich, 2016-02-02\n+# Copyright (c) 2016 Datacratic Inc. All rights reserved.\n+#\n+import tempfile\n+import os\n+import unittest\n+mldb = mldb_wrapper.wrap(mldb) # noqa\n+\n+class RowNameAsStringTest(MldbUnitTest):\n+    query = \"SELECT * FROM csv ORDER BY rowName()\"\n+\n+    @classmethod\n+    def setUpClass(cls):\n+        tmp_file = tempfile.NamedTemporaryFile(\n+            prefix=os.getcwd() + '/build/x86_64/tmp/')\n+        with open(tmp_file.name, 'wt') as f:\n+            f.write(\"header\\n\")\n+            f.write(\"val1\\n\")\n+            f.write(\"val2\\n\")\n+\n+        mldb.put('/v1/datasets/csv', {\n+            'type' : 'text.csv.tabular',\n+            'params' : {\n+                'dataFileUrl' : 'file:///' + tmp_file.name\n+            }\n+        })\n+\n+    def test_flat_result(self):\n+        res = mldb.query(self.__class__.query)\n+        self.assertQueryResult(res, [\n+            ['_rowName', 'header'],\n+            ['2', 'val1'],\n+            ['3', 'val2']\n+        ])\n+\n+    @unittest.expectedFailure\n+    def test_object_result(self):\n+        res = mldb.get('/v1/query', q=self.__class__.query).json()\n+        # because of the now ts beign inserted we only check for row names","path":"testing/MLDBFB-192_row_name_as_string_test.py","position":41,"original_position":41,"commit_id":"4c61d409045baff6bcab176b36c25863b85cc097","original_commit_id":"4c61d409045baff6bcab176b36c25863b85cc097","user":{"login":"nicolaskruchten","id":203523,"avatar_url":"https://avatars.githubusercontent.com/u/203523?v=3","gravatar_id":"","url":"https://api.github.com/users/nicolaskruchten","html_url":"https://github.com/nicolaskruchten","followers_url":"https://api.github.com/users/nicolaskruchten/followers","following_url":"https://api.github.com/users/nicolaskruchten/following{/other_user}","gists_url":"https://api.github.com/users/nicolaskruchten/gists{/gist_id}","starred_url":"https://api.github.com/users/nicolaskruchten/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicolaskruchten/subscriptions","organizations_url":"https://api.github.com/users/nicolaskruchten/orgs","repos_url":"https://api.github.com/users/nicolaskruchten/repos","events_url":"https://api.github.com/users/nicolaskruchten/events{/privacy}","received_events_url":"https://api.github.com/users/nicolaskruchten/received_events","type":"User","site_admin":false},"body":"where is the now ts being inserted?","created_at":"2016-02-03T14:13:11Z","updated_at":"2016-02-03T14:13:11Z","html_url":"https://github.com/mldbai/mldb/pull/141#discussion_r51724677","pull_request_url":"https://api.github.com/repos/mldbai/mldb/pulls/141","_links":{"self":{"href":"https://api.github.com/repos/mldbai/mldb/pulls/comments/51724677"},"html":{"href":"https://github.com/mldbai/mldb/pull/141#discussion_r51724677"},"pull_request":{"href":"https://api.github.com/repos/mldbai/mldb/pulls/141"}}},"pull_request":{"url":"https://api.github.com/repos/mldbai/mldb/pulls/141","id":58059829,"html_url":"https://github.com/mldbai/mldb/pull/141","diff_url":"https://github.com/mldbai/mldb/pull/141.diff","patch_url":"https://github.com/mldbai/mldb/pull/141.patch","issue_url":"https://api.github.com/repos/mldbai/mldb/issues/141","number":141,"state":"open","locked":false,"title":"Mldbfb 192 row name as string test","user":{"login":"FinchPowers","id":607566,"avatar_url":"https://avatars.githubusercontent.com/u/607566?v=3","gravatar_id":"","url":"https://api.github.com/users/FinchPowers","html_url":"https://github.com/FinchPowers","followers_url":"https://api.github.com/users/FinchPowers/followers","following_url":"https://api.github.com/users/FinchPowers/following{/other_user}","gists_url":"https://api.github.com/users/FinchPowers/gists{/gist_id}","starred_url":"https://api.github.com/users/FinchPowers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FinchPowers/subscriptions","organizations_url":"https://api.github.com/users/FinchPowers/orgs","repos_url":"https://api.github.com/users/FinchPowers/repos","events_url":"https://api.github.com/users/FinchPowers/events{/privacy}","received_events_url":"https://api.github.com/users/FinchPowers/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-02-02T22:20:23Z","updated_at":"2016-02-03T14:13:11Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a6b1cb3e32d1e14ee67911a4b4a662ad827bd343","assignee":{"login":"nicolaskruchten","id":203523,"avatar_url":"https://avatars.githubusercontent.com/u/203523?v=3","gravatar_id":"","url":"https://api.github.com/users/nicolaskruchten","html_url":"https://github.com/nicolaskruchten","followers_url":"https://api.github.com/users/nicolaskruchten/followers","following_url":"https://api.github.com/users/nicolaskruchten/following{/other_user}","gists_url":"https://api.github.com/users/nicolaskruchten/gists{/gist_id}","starred_url":"https://api.github.com/users/nicolaskruchten/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicolaskruchten/subscriptions","organizations_url":"https://api.github.com/users/nicolaskruchten/orgs","repos_url":"https://api.github.com/users/nicolaskruchten/repos","events_url":"https://api.github.com/users/nicolaskruchten/events{/privacy}","received_events_url":"https://api.github.com/users/nicolaskruchten/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/mldbai/mldb/pulls/141/commits","review_comments_url":"https://api.github.com/repos/mldbai/mldb/pulls/141/comments","review_comment_url":"https://api.github.com/repos/mldbai/mldb/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mldbai/mldb/issues/141/comments","statuses_url":"https://api.github.com/repos/mldbai/mldb/statuses/4c61d409045baff6bcab176b36c25863b85cc097","head":{"label":"mldbai:MLDBFB-192_row_name_as_string_test","ref":"MLDBFB-192_row_name_as_string_test","sha":"4c61d409045baff6bcab176b36c25863b85cc097","user":{"login":"mldbai","id":11510172,"avatar_url":"https://avatars.githubusercontent.com/u/11510172?v=3","gravatar_id":"","url":"https://api.github.com/users/mldbai","html_url":"https://github.com/mldbai","followers_url":"https://api.github.com/users/mldbai/followers","following_url":"https://api.github.com/users/mldbai/following{/other_user}","gists_url":"https://api.github.com/users/mldbai/gists{/gist_id}","starred_url":"https://api.github.com/users/mldbai/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mldbai/subscriptions","organizations_url":"https://api.github.com/users/mldbai/orgs","repos_url":"https://api.github.com/users/mldbai/repos","events_url":"https://api.github.com/users/mldbai/events{/privacy}","received_events_url":"https://api.github.com/users/mldbai/received_events","type":"Organization","site_admin":false},"repo":{"id":47634692,"name":"mldb","full_name":"mldbai/mldb","owner":{"login":"mldbai","id":11510172,"avatar_url":"https://avatars.githubusercontent.com/u/11510172?v=3","gravatar_id":"","url":"https://api.github.com/users/mldbai","html_url":"https://github.com/mldbai","followers_url":"https://api.github.com/users/mldbai/followers","following_url":"https://api.github.com/users/mldbai/following{/other_user}","gists_url":"https://api.github.com/users/mldbai/gists{/gist_id}","starred_url":"https://api.github.com/users/mldbai/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mldbai/subscriptions","organizations_url":"https://api.github.com/users/mldbai/orgs","repos_url":"https://api.github.com/users/mldbai/repos","events_url":"https://api.github.com/users/mldbai/events{/privacy}","received_events_url":"https://api.github.com/users/mldbai/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mldbai/mldb","description":"MLDB is the Machine Learning Database","fork":false,"url":"https://api.github.com/repos/mldbai/mldb","forks_url":"https://api.github.com/repos/mldbai/mldb/forks","keys_url":"https://api.github.com/repos/mldbai/mldb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mldbai/mldb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mldbai/mldb/teams","hooks_url":"https://api.github.com/repos/mldbai/mldb/hooks","issue_events_url":"https://api.github.com/repos/mldbai/mldb/issues/events{/number}","events_url":"https://api.github.com/repos/mldbai/mldb/events","assignees_url":"https://api.github.com/repos/mldbai/mldb/assignees{/user}","branches_url":"https://api.github.com/repos/mldbai/mldb/branches{/branch}","tags_url":"https://api.github.com/repos/mldbai/mldb/tags","blobs_url":"https://api.github.com/repos/mldbai/mldb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mldbai/mldb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mldbai/mldb/git/refs{/sha}","trees_url":"https://api.github.com/repos/mldbai/mldb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mldbai/mldb/statuses/{sha}","languages_url":"https://api.github.com/repos/mldbai/mldb/languages","stargazers_url":"https://api.github.com/repos/mldbai/mldb/stargazers","contributors_url":"https://api.github.com/repos/mldbai/mldb/contributors","subscribers_url":"https://api.github.com/repos/mldbai/mldb/subscribers","subscription_url":"https://api.github.com/repos/mldbai/mldb/subscription","commits_url":"https://api.github.com/repos/mldbai/mldb/commits{/sha}","git_commits_url":"https://api.github.com/repos/mldbai/mldb/git/commits{/sha}","comments_url":"https://api.github.com/repos/mldbai/mldb/comments{/number}","issue_comment_url":"https://api.github.com/repos/mldbai/mldb/issues/comments{/number}","contents_url":"https://api.github.com/repos/mldbai/mldb/contents/{+path}","compare_url":"https://api.github.com/repos/mldbai/mldb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mldbai/mldb/merges","archive_url":"https://api.github.com/repos/mldbai/mldb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mldbai/mldb/downloads","issues_url":"https://api.github.com/repos/mldbai/mldb/issues{/number}","pulls_url":"https://api.github.com/repos/mldbai/mldb/pulls{/number}","milestones_url":"https://api.github.com/repos/mldbai/mldb/milestones{/number}","notifications_url":"https://api.github.com/repos/mldbai/mldb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mldbai/mldb/labels{/name}","releases_url":"https://api.github.com/repos/mldbai/mldb/releases{/id}","deployments_url":"https://api.github.com/repos/mldbai/mldb/deployments","created_at":"2015-12-08T16:34:16Z","updated_at":"2016-02-02T17:22:00Z","pushed_at":"2016-02-03T13:21:32Z","git_url":"git://github.com/mldbai/mldb.git","ssh_url":"git@github.com:mldbai/mldb.git","clone_url":"https://github.com/mldbai/mldb.git","svn_url":"https://github.com/mldbai/mldb","homepage":"http://mldb.ai","size":9989,"stargazers_count":19,"watchers_count":19,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":9,"forks":2,"open_issues":9,"watchers":19,"default_branch":"master"}},"base":{"label":"mldbai:master","ref":"master","sha":"813395f5594cee206cc69f6a936bdf15ce853b81","user":{"login":"mldbai","id":11510172,"avatar_url":"https://avatars.githubusercontent.com/u/11510172?v=3","gravatar_id":"","url":"https://api.github.com/users/mldbai","html_url":"https://github.com/mldbai","followers_url":"https://api.github.com/users/mldbai/followers","following_url":"https://api.github.com/users/mldbai/following{/other_user}","gists_url":"https://api.github.com/users/mldbai/gists{/gist_id}","starred_url":"https://api.github.com/users/mldbai/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mldbai/subscriptions","organizations_url":"https://api.github.com/users/mldbai/orgs","repos_url":"https://api.github.com/users/mldbai/repos","events_url":"https://api.github.com/users/mldbai/events{/privacy}","received_events_url":"https://api.github.com/users/mldbai/received_events","type":"Organization","site_admin":false},"repo":{"id":47634692,"name":"mldb","full_name":"mldbai/mldb","owner":{"login":"mldbai","id":11510172,"avatar_url":"https://avatars.githubusercontent.com/u/11510172?v=3","gravatar_id":"","url":"https://api.github.com/users/mldbai","html_url":"https://github.com/mldbai","followers_url":"https://api.github.com/users/mldbai/followers","following_url":"https://api.github.com/users/mldbai/following{/other_user}","gists_url":"https://api.github.com/users/mldbai/gists{/gist_id}","starred_url":"https://api.github.com/users/mldbai/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mldbai/subscriptions","organizations_url":"https://api.github.com/users/mldbai/orgs","repos_url":"https://api.github.com/users/mldbai/repos","events_url":"https://api.github.com/users/mldbai/events{/privacy}","received_events_url":"https://api.github.com/users/mldbai/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mldbai/mldb","description":"MLDB is the Machine Learning Database","fork":false,"url":"https://api.github.com/repos/mldbai/mldb","forks_url":"https://api.github.com/repos/mldbai/mldb/forks","keys_url":"https://api.github.com/repos/mldbai/mldb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mldbai/mldb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mldbai/mldb/teams","hooks_url":"https://api.github.com/repos/mldbai/mldb/hooks","issue_events_url":"https://api.github.com/repos/mldbai/mldb/issues/events{/number}","events_url":"https://api.github.com/repos/mldbai/mldb/events","assignees_url":"https://api.github.com/repos/mldbai/mldb/assignees{/user}","branches_url":"https://api.github.com/repos/mldbai/mldb/branches{/branch}","tags_url":"https://api.github.com/repos/mldbai/mldb/tags","blobs_url":"https://api.github.com/repos/mldbai/mldb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mldbai/mldb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mldbai/mldb/git/refs{/sha}","trees_url":"https://api.github.com/repos/mldbai/mldb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mldbai/mldb/statuses/{sha}","languages_url":"https://api.github.com/repos/mldbai/mldb/languages","stargazers_url":"https://api.github.com/repos/mldbai/mldb/stargazers","contributors_url":"https://api.github.com/repos/mldbai/mldb/contributors","subscribers_url":"https://api.github.com/repos/mldbai/mldb/subscribers","subscription_url":"https://api.github.com/repos/mldbai/mldb/subscription","commits_url":"https://api.github.com/repos/mldbai/mldb/commits{/sha}","git_commits_url":"https://api.github.com/repos/mldbai/mldb/git/commits{/sha}","comments_url":"https://api.github.com/repos/mldbai/mldb/comments{/number}","issue_comment_url":"https://api.github.com/repos/mldbai/mldb/issues/comments{/number}","contents_url":"https://api.github.com/repos/mldbai/mldb/contents/{+path}","compare_url":"https://api.github.com/repos/mldbai/mldb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mldbai/mldb/merges","archive_url":"https://api.github.com/repos/mldbai/mldb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mldbai/mldb/downloads","issues_url":"https://api.github.com/repos/mldbai/mldb/issues{/number}","pulls_url":"https://api.github.com/repos/mldbai/mldb/pulls{/number}","milestones_url":"https://api.github.com/repos/mldbai/mldb/milestones{/number}","notifications_url":"https://api.github.com/repos/mldbai/mldb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mldbai/mldb/labels{/name}","releases_url":"https://api.github.com/repos/mldbai/mldb/releases{/id}","deployments_url":"https://api.github.com/repos/mldbai/mldb/deployments","created_at":"2015-12-08T16:34:16Z","updated_at":"2016-02-02T17:22:00Z","pushed_at":"2016-02-03T13:21:32Z","git_url":"git://github.com/mldbai/mldb.git","ssh_url":"git@github.com:mldbai/mldb.git","clone_url":"https://github.com/mldbai/mldb.git","svn_url":"https://github.com/mldbai/mldb","homepage":"http://mldb.ai","size":9989,"stargazers_count":19,"watchers_count":19,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":9,"forks":2,"open_issues":9,"watchers":19,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mldbai/mldb/pulls/141"},"html":{"href":"https://github.com/mldbai/mldb/pull/141"},"issue":{"href":"https://api.github.com/repos/mldbai/mldb/issues/141"},"comments":{"href":"https://api.github.com/repos/mldbai/mldb/issues/141/comments"},"review_comments":{"href":"https://api.github.com/repos/mldbai/mldb/pulls/141/comments"},"review_comment":{"href":"https://api.github.com/repos/mldbai/mldb/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mldbai/mldb/pulls/141/commits"},"statuses":{"href":"https://api.github.com/repos/mldbai/mldb/statuses/4c61d409045baff6bcab176b36c25863b85cc097"}}}}