{"action":"created","comment":{"url":"https://api.github.com/repos/gocraft/dbr/pulls/comments/228956597","pull_request_review_id":169339724,"id":228956597,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyODk1NjU5Nw==","diff_hunk":"@@ -174,15 +176,19 @@ func TestTimeout(t *testing.T) {\n \t\tvar people []dbrPerson\n \t\t_, err := sess.Select(\"*\").From(\"dbr_people\").Load(&people)\n \t\trequire.Equal(t, context.DeadlineExceeded, err)\n+\t\tassert.Equal(t, 1, sess.EventReceiver.(*testTraceReceiver).errored)","path":"dbr_test.go","position":29,"original_position":29,"commit_id":"2b7f5d4170bc267b8b198eb4e30f42913ea14bb5","original_commit_id":"2b7f5d4170bc267b8b198eb4e30f42913ea14bb5","user":{"login":"taylorchu","id":422998,"node_id":"MDQ6VXNlcjQyMjk5OA==","avatar_url":"https://avatars0.githubusercontent.com/u/422998?v=4","gravatar_id":"","url":"https://api.github.com/users/taylorchu","html_url":"https://github.com/taylorchu","followers_url":"https://api.github.com/users/taylorchu/followers","following_url":"https://api.github.com/users/taylorchu/following{/other_user}","gists_url":"https://api.github.com/users/taylorchu/gists{/gist_id}","starred_url":"https://api.github.com/users/taylorchu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/taylorchu/subscriptions","organizations_url":"https://api.github.com/users/taylorchu/orgs","repos_url":"https://api.github.com/users/taylorchu/repos","events_url":"https://api.github.com/users/taylorchu/events{/privacy}","received_events_url":"https://api.github.com/users/taylorchu/received_events","type":"User","site_admin":false},"body":"could you use `require` package instead? ","created_at":"2018-10-29T14:47:28Z","updated_at":"2018-10-29T14:49:35Z","html_url":"https://github.com/gocraft/dbr/pull/154#discussion_r228956597","pull_request_url":"https://api.github.com/repos/gocraft/dbr/pulls/154","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/gocraft/dbr/pulls/comments/228956597"},"html":{"href":"https://github.com/gocraft/dbr/pull/154#discussion_r228956597"},"pull_request":{"href":"https://api.github.com/repos/gocraft/dbr/pulls/154"}}},"pull_request":{"url":"https://api.github.com/repos/gocraft/dbr/pulls/154","id":225941384,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI1OTQxMzg0","html_url":"https://github.com/gocraft/dbr/pull/154","diff_url":"https://github.com/gocraft/dbr/pull/154.diff","patch_url":"https://github.com/gocraft/dbr/pull/154.patch","issue_url":"https://api.github.com/repos/gocraft/dbr/issues/154","number":154,"state":"open","locked":false,"title":"Fix ability to pass TracingEventReceiver to dbr","user":{"login":"cce","id":51567,"node_id":"MDQ6VXNlcjUxNTY3","avatar_url":"https://avatars1.githubusercontent.com/u/51567?v=4","gravatar_id":"","url":"https://api.github.com/users/cce","html_url":"https://github.com/cce","followers_url":"https://api.github.com/users/cce/followers","following_url":"https://api.github.com/users/cce/following{/other_user}","gists_url":"https://api.github.com/users/cce/gists{/gist_id}","starred_url":"https://api.github.com/users/cce/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cce/subscriptions","organizations_url":"https://api.github.com/users/cce/orgs","repos_url":"https://api.github.com/users/cce/repos","events_url":"https://api.github.com/users/cce/events{/privacy}","received_events_url":"https://api.github.com/users/cce/received_events","type":"User","site_admin":false},"body":"After trying out #153 I discovered it doesn't work — this is because composition is used to add `EventReceiver` to various structs, and so it loses track of the original EventReceiver implementation when passing it around, and then the type assertion for `TracingEventReceiver` in dbr.go does not work. This adds some failing test cases asserting that tracing works, then fixes them.\r\n\r\nA bigger change would be to name the `EventReceiver` rather than using an anonymous embedding, but I didn't want to make such a big change.","created_at":"2018-10-26T00:11:50Z","updated_at":"2018-10-29T14:49:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"439bcd63773ab06ab9e13f1b1aa81a2e815f998d","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/gocraft/dbr/pulls/154/commits","review_comments_url":"https://api.github.com/repos/gocraft/dbr/pulls/154/comments","review_comment_url":"https://api.github.com/repos/gocraft/dbr/pulls/comments{/number}","comments_url":"https://api.github.com/repos/gocraft/dbr/issues/154/comments","statuses_url":"https://api.github.com/repos/gocraft/dbr/statuses/2b7f5d4170bc267b8b198eb4e30f42913ea14bb5","head":{"label":"cce:fix-trace-event-receiver","ref":"fix-trace-event-receiver","sha":"2b7f5d4170bc267b8b198eb4e30f42913ea14bb5","user":{"login":"cce","id":51567,"node_id":"MDQ6VXNlcjUxNTY3","avatar_url":"https://avatars1.githubusercontent.com/u/51567?v=4","gravatar_id":"","url":"https://api.github.com/users/cce","html_url":"https://github.com/cce","followers_url":"https://api.github.com/users/cce/followers","following_url":"https://api.github.com/users/cce/following{/other_user}","gists_url":"https://api.github.com/users/cce/gists{/gist_id}","starred_url":"https://api.github.com/users/cce/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cce/subscriptions","organizations_url":"https://api.github.com/users/cce/orgs","repos_url":"https://api.github.com/users/cce/repos","events_url":"https://api.github.com/users/cce/events{/privacy}","received_events_url":"https://api.github.com/users/cce/received_events","type":"User","site_admin":false},"repo":{"id":153665868,"node_id":"MDEwOlJlcG9zaXRvcnkxNTM2NjU4Njg=","name":"dbr","full_name":"cce/dbr","private":false,"owner":{"login":"cce","id":51567,"node_id":"MDQ6VXNlcjUxNTY3","avatar_url":"https://avatars1.githubusercontent.com/u/51567?v=4","gravatar_id":"","url":"https://api.github.com/users/cce","html_url":"https://github.com/cce","followers_url":"https://api.github.com/users/cce/followers","following_url":"https://api.github.com/users/cce/following{/other_user}","gists_url":"https://api.github.com/users/cce/gists{/gist_id}","starred_url":"https://api.github.com/users/cce/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cce/subscriptions","organizations_url":"https://api.github.com/users/cce/orgs","repos_url":"https://api.github.com/users/cce/repos","events_url":"https://api.github.com/users/cce/events{/privacy}","received_events_url":"https://api.github.com/users/cce/received_events","type":"User","site_admin":false},"html_url":"https://github.com/cce/dbr","description":"Additions to Go's database/sql for super fast performance and convenience.","fork":true,"url":"https://api.github.com/repos/cce/dbr","forks_url":"https://api.github.com/repos/cce/dbr/forks","keys_url":"https://api.github.com/repos/cce/dbr/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cce/dbr/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cce/dbr/teams","hooks_url":"https://api.github.com/repos/cce/dbr/hooks","issue_events_url":"https://api.github.com/repos/cce/dbr/issues/events{/number}","events_url":"https://api.github.com/repos/cce/dbr/events","assignees_url":"https://api.github.com/repos/cce/dbr/assignees{/user}","branches_url":"https://api.github.com/repos/cce/dbr/branches{/branch}","tags_url":"https://api.github.com/repos/cce/dbr/tags","blobs_url":"https://api.github.com/repos/cce/dbr/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cce/dbr/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cce/dbr/git/refs{/sha}","trees_url":"https://api.github.com/repos/cce/dbr/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cce/dbr/statuses/{sha}","languages_url":"https://api.github.com/repos/cce/dbr/languages","stargazers_url":"https://api.github.com/repos/cce/dbr/stargazers","contributors_url":"https://api.github.com/repos/cce/dbr/contributors","subscribers_url":"https://api.github.com/repos/cce/dbr/subscribers","subscription_url":"https://api.github.com/repos/cce/dbr/subscription","commits_url":"https://api.github.com/repos/cce/dbr/commits{/sha}","git_commits_url":"https://api.github.com/repos/cce/dbr/git/commits{/sha}","comments_url":"https://api.github.com/repos/cce/dbr/comments{/number}","issue_comment_url":"https://api.github.com/repos/cce/dbr/issues/comments{/number}","contents_url":"https://api.github.com/repos/cce/dbr/contents/{+path}","compare_url":"https://api.github.com/repos/cce/dbr/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cce/dbr/merges","archive_url":"https://api.github.com/repos/cce/dbr/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cce/dbr/downloads","issues_url":"https://api.github.com/repos/cce/dbr/issues{/number}","pulls_url":"https://api.github.com/repos/cce/dbr/pulls{/number}","milestones_url":"https://api.github.com/repos/cce/dbr/milestones{/number}","notifications_url":"https://api.github.com/repos/cce/dbr/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cce/dbr/labels{/name}","releases_url":"https://api.github.com/repos/cce/dbr/releases{/id}","deployments_url":"https://api.github.com/repos/cce/dbr/deployments","created_at":"2018-10-18T18:01:08Z","updated_at":"2018-10-18T18:01:10Z","pushed_at":"2018-10-26T00:17:16Z","git_url":"git://github.com/cce/dbr.git","ssh_url":"git@github.com:cce/dbr.git","clone_url":"https://github.com/cce/dbr.git","svn_url":"https://github.com/cce/dbr","homepage":"","size":247,"stargazers_count":0,"watchers_count":0,"language":"Go","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","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"gocraft:master","ref":"master","sha":"018a08e13b8a4e51aff158821be83002fc285cd6","user":{"login":"gocraft","id":6075192,"node_id":"MDEyOk9yZ2FuaXphdGlvbjYwNzUxOTI=","avatar_url":"https://avatars1.githubusercontent.com/u/6075192?v=4","gravatar_id":"","url":"https://api.github.com/users/gocraft","html_url":"https://github.com/gocraft","followers_url":"https://api.github.com/users/gocraft/followers","following_url":"https://api.github.com/users/gocraft/following{/other_user}","gists_url":"https://api.github.com/users/gocraft/gists{/gist_id}","starred_url":"https://api.github.com/users/gocraft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gocraft/subscriptions","organizations_url":"https://api.github.com/users/gocraft/orgs","repos_url":"https://api.github.com/users/gocraft/repos","events_url":"https://api.github.com/users/gocraft/events{/privacy}","received_events_url":"https://api.github.com/users/gocraft/received_events","type":"Organization","site_admin":false},"repo":{"id":19512853,"node_id":"MDEwOlJlcG9zaXRvcnkxOTUxMjg1Mw==","name":"dbr","full_name":"gocraft/dbr","private":false,"owner":{"login":"gocraft","id":6075192,"node_id":"MDEyOk9yZ2FuaXphdGlvbjYwNzUxOTI=","avatar_url":"https://avatars1.githubusercontent.com/u/6075192?v=4","gravatar_id":"","url":"https://api.github.com/users/gocraft","html_url":"https://github.com/gocraft","followers_url":"https://api.github.com/users/gocraft/followers","following_url":"https://api.github.com/users/gocraft/following{/other_user}","gists_url":"https://api.github.com/users/gocraft/gists{/gist_id}","starred_url":"https://api.github.com/users/gocraft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gocraft/subscriptions","organizations_url":"https://api.github.com/users/gocraft/orgs","repos_url":"https://api.github.com/users/gocraft/repos","events_url":"https://api.github.com/users/gocraft/events{/privacy}","received_events_url":"https://api.github.com/users/gocraft/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/gocraft/dbr","description":"Additions to Go's database/sql for super fast performance and convenience.","fork":false,"url":"https://api.github.com/repos/gocraft/dbr","forks_url":"https://api.github.com/repos/gocraft/dbr/forks","keys_url":"https://api.github.com/repos/gocraft/dbr/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gocraft/dbr/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gocraft/dbr/teams","hooks_url":"https://api.github.com/repos/gocraft/dbr/hooks","issue_events_url":"https://api.github.com/repos/gocraft/dbr/issues/events{/number}","events_url":"https://api.github.com/repos/gocraft/dbr/events","assignees_url":"https://api.github.com/repos/gocraft/dbr/assignees{/user}","branches_url":"https://api.github.com/repos/gocraft/dbr/branches{/branch}","tags_url":"https://api.github.com/repos/gocraft/dbr/tags","blobs_url":"https://api.github.com/repos/gocraft/dbr/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gocraft/dbr/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gocraft/dbr/git/refs{/sha}","trees_url":"https://api.github.com/repos/gocraft/dbr/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gocraft/dbr/statuses/{sha}","languages_url":"https://api.github.com/repos/gocraft/dbr/languages","stargazers_url":"https://api.github.com/repos/gocraft/dbr/stargazers","contributors_url":"https://api.github.com/repos/gocraft/dbr/contributors","subscribers_url":"https://api.github.com/repos/gocraft/dbr/subscribers","subscription_url":"https://api.github.com/repos/gocraft/dbr/subscription","commits_url":"https://api.github.com/repos/gocraft/dbr/commits{/sha}","git_commits_url":"https://api.github.com/repos/gocraft/dbr/git/commits{/sha}","comments_url":"https://api.github.com/repos/gocraft/dbr/comments{/number}","issue_comment_url":"https://api.github.com/repos/gocraft/dbr/issues/comments{/number}","contents_url":"https://api.github.com/repos/gocraft/dbr/contents/{+path}","compare_url":"https://api.github.com/repos/gocraft/dbr/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gocraft/dbr/merges","archive_url":"https://api.github.com/repos/gocraft/dbr/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gocraft/dbr/downloads","issues_url":"https://api.github.com/repos/gocraft/dbr/issues{/number}","pulls_url":"https://api.github.com/repos/gocraft/dbr/pulls{/number}","milestones_url":"https://api.github.com/repos/gocraft/dbr/milestones{/number}","notifications_url":"https://api.github.com/repos/gocraft/dbr/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gocraft/dbr/labels{/name}","releases_url":"https://api.github.com/repos/gocraft/dbr/releases{/id}","deployments_url":"https://api.github.com/repos/gocraft/dbr/deployments","created_at":"2014-05-06T22:20:36Z","updated_at":"2018-10-28T22:22:49Z","pushed_at":"2018-10-26T00:17:18Z","git_url":"git://github.com/gocraft/dbr.git","ssh_url":"git@github.com:gocraft/dbr.git","clone_url":"https://github.com/gocraft/dbr.git","svn_url":"https://github.com/gocraft/dbr","homepage":"","size":242,"stargazers_count":1118,"watchers_count":1118,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":121,"mirror_url":null,"archived":false,"open_issues_count":4,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":121,"open_issues":4,"watchers":1118,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/gocraft/dbr/pulls/154"},"html":{"href":"https://github.com/gocraft/dbr/pull/154"},"issue":{"href":"https://api.github.com/repos/gocraft/dbr/issues/154"},"comments":{"href":"https://api.github.com/repos/gocraft/dbr/issues/154/comments"},"review_comments":{"href":"https://api.github.com/repos/gocraft/dbr/pulls/154/comments"},"review_comment":{"href":"https://api.github.com/repos/gocraft/dbr/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/gocraft/dbr/pulls/154/commits"},"statuses":{"href":"https://api.github.com/repos/gocraft/dbr/statuses/2b7f5d4170bc267b8b198eb4e30f42913ea14bb5"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"taylorchu"}}