{"action":"created","comment":{"url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/comments/170070291","pull_request_review_id":98700463,"id":170070291,"diff_hunk":"@@ -8,7 +8,7 @@\n \n namespace Rubberduck.VBEditor.SafeComWrappers.VB6\n {\n-    public class VBProjects : SafeComWrapper<VB.VBProjects>, IVBProjects\n+    public class VBProjects : SafeEventedComWrapper<VB.VBProjects, VB._dispVBProjectsEvents>, IVBProjects\n     {\n         private static readonly Guid VBProjectsEventsGuid = new Guid(\"0002E190-0000-0000-C000-000000000046\");","path":"Rubberduck.VBEEditor/SafeComWrappers/VB6/VBProjects.cs","position":7,"original_position":7,"commit_id":"fa50478e090dda850c5a0c75b741017c70fede4f","original_commit_id":"fa50478e090dda850c5a0c75b741017c70fede4f","user":{"login":"bclothier","id":2367644,"avatar_url":"https://avatars2.githubusercontent.com/u/2367644?v=4","gravatar_id":"","url":"https://api.github.com/users/bclothier","html_url":"https://github.com/bclothier","followers_url":"https://api.github.com/users/bclothier/followers","following_url":"https://api.github.com/users/bclothier/following{/other_user}","gists_url":"https://api.github.com/users/bclothier/gists{/gist_id}","starred_url":"https://api.github.com/users/bclothier/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bclothier/subscriptions","organizations_url":"https://api.github.com/users/bclothier/orgs","repos_url":"https://api.github.com/users/bclothier/repos","events_url":"https://api.github.com/users/bclothier/events{/privacy}","received_events_url":"https://api.github.com/users/bclothier/received_events","type":"User","site_admin":false},"body":"The problem is that we use the interface (`IVBComponents` and `IVBProjects`), which are shared by both VB6 and VBA, so if I don't implement VB6 using same interface, I get compilation errors because the consuming code can't call `AttachEvents` / `DetachEvents` since VB6's implementation won't have `SafeEventedComWrapper` interface. I agree it's lousy but short of actually deleting the whole VB6 implementation, I'm not sure what I can do about that. I will at least add a TODO to warn it's all wrong.","created_at":"2018-02-22T19:38:44Z","updated_at":"2018-02-22T19:38:44Z","html_url":"https://github.com/rubberduck-vba/Rubberduck/pull/3701#discussion_r170070291","pull_request_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/3701","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/comments/170070291"},"html":{"href":"https://github.com/rubberduck-vba/Rubberduck/pull/3701#discussion_r170070291"},"pull_request":{"href":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/3701"}},"in_reply_to_id":170047986},"pull_request":{"url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/3701","id":162786584,"html_url":"https://github.com/rubberduck-vba/Rubberduck/pull/3701","diff_url":"https://github.com/rubberduck-vba/Rubberduck/pull/3701.diff","patch_url":"https://github.com/rubberduck-vba/Rubberduck/pull/3701.patch","issue_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/issues/3701","number":3701,"state":"open","locked":false,"title":"Event interface","user":{"login":"bclothier","id":2367644,"avatar_url":"https://avatars2.githubusercontent.com/u/2367644?v=4","gravatar_id":"","url":"https://api.github.com/users/bclothier","html_url":"https://github.com/bclothier","followers_url":"https://api.github.com/users/bclothier/followers","following_url":"https://api.github.com/users/bclothier/following{/other_user}","gists_url":"https://api.github.com/users/bclothier/gists{/gist_id}","starred_url":"https://api.github.com/users/bclothier/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bclothier/subscriptions","organizations_url":"https://api.github.com/users/bclothier/orgs","repos_url":"https://api.github.com/users/bclothier/repos","events_url":"https://api.github.com/users/bclothier/events{/privacy}","received_events_url":"https://api.github.com/users/bclothier/received_events","type":"User","site_admin":false},"body":"This restores the implementation of events as an instance member of their containing class rather than as a static methods. This may potentially fix the issues where we miss some `VBComponents` events because only the first registration are considered. \r\n\r\nNote that this is somehow a reversion to an earlier pull request - see @comintern PRs here:\r\n[PR to make it thread-safe](https://github.com/rubberduck-vba/Rubberduck/pull/2677)\r\n[PR to plug memory leaks](https://github.com/rubberduck-vba/Rubberduck/pull/2687)\r\n\r\nThat said, there are still few differences --\r\n\r\n1) We build upon the `SafeComWrapper`, creating `SafeEventedComWrapper` which controls the disposal.\r\n2) We implement the source interface directly, rather than using a separate sink, which simplify the instance management as there's now an one-one relationship between the source and the events.\r\n\r\nThis is being put up for review by others before I proceed further on other and to help us decide if it's still warranted. ","created_at":"2018-01-13T16:33:15Z","updated_at":"2018-02-22T19:38:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b19e84b6b9fd8f201a42c01e19d3e1ce22d944b7","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":765570372,"url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/labels/PR-Status:%20Review%20Requested","name":"PR-Status: Review Requested","color":"584daf","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/3701/commits","review_comments_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/3701/comments","review_comment_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/comments{/number}","comments_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/issues/3701/comments","statuses_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/statuses/fa50478e090dda850c5a0c75b741017c70fede4f","head":{"label":"bclothier:EventInterface","ref":"EventInterface","sha":"fa50478e090dda850c5a0c75b741017c70fede4f","user":{"login":"bclothier","id":2367644,"avatar_url":"https://avatars2.githubusercontent.com/u/2367644?v=4","gravatar_id":"","url":"https://api.github.com/users/bclothier","html_url":"https://github.com/bclothier","followers_url":"https://api.github.com/users/bclothier/followers","following_url":"https://api.github.com/users/bclothier/following{/other_user}","gists_url":"https://api.github.com/users/bclothier/gists{/gist_id}","starred_url":"https://api.github.com/users/bclothier/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bclothier/subscriptions","organizations_url":"https://api.github.com/users/bclothier/orgs","repos_url":"https://api.github.com/users/bclothier/repos","events_url":"https://api.github.com/users/bclothier/events{/privacy}","received_events_url":"https://api.github.com/users/bclothier/received_events","type":"User","site_admin":false},"repo":{"id":102542787,"name":"Rubberduck","full_name":"bclothier/Rubberduck","owner":{"login":"bclothier","id":2367644,"avatar_url":"https://avatars2.githubusercontent.com/u/2367644?v=4","gravatar_id":"","url":"https://api.github.com/users/bclothier","html_url":"https://github.com/bclothier","followers_url":"https://api.github.com/users/bclothier/followers","following_url":"https://api.github.com/users/bclothier/following{/other_user}","gists_url":"https://api.github.com/users/bclothier/gists{/gist_id}","starred_url":"https://api.github.com/users/bclothier/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bclothier/subscriptions","organizations_url":"https://api.github.com/users/bclothier/orgs","repos_url":"https://api.github.com/users/bclothier/repos","events_url":"https://api.github.com/users/bclothier/events{/privacy}","received_events_url":"https://api.github.com/users/bclothier/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bclothier/Rubberduck","description":"Every programmer needs a rubberduck. COM add-in for the VBA IDE (VBE).","fork":true,"url":"https://api.github.com/repos/bclothier/Rubberduck","forks_url":"https://api.github.com/repos/bclothier/Rubberduck/forks","keys_url":"https://api.github.com/repos/bclothier/Rubberduck/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bclothier/Rubberduck/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bclothier/Rubberduck/teams","hooks_url":"https://api.github.com/repos/bclothier/Rubberduck/hooks","issue_events_url":"https://api.github.com/repos/bclothier/Rubberduck/issues/events{/number}","events_url":"https://api.github.com/repos/bclothier/Rubberduck/events","assignees_url":"https://api.github.com/repos/bclothier/Rubberduck/assignees{/user}","branches_url":"https://api.github.com/repos/bclothier/Rubberduck/branches{/branch}","tags_url":"https://api.github.com/repos/bclothier/Rubberduck/tags","blobs_url":"https://api.github.com/repos/bclothier/Rubberduck/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bclothier/Rubberduck/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bclothier/Rubberduck/git/refs{/sha}","trees_url":"https://api.github.com/repos/bclothier/Rubberduck/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bclothier/Rubberduck/statuses/{sha}","languages_url":"https://api.github.com/repos/bclothier/Rubberduck/languages","stargazers_url":"https://api.github.com/repos/bclothier/Rubberduck/stargazers","contributors_url":"https://api.github.com/repos/bclothier/Rubberduck/contributors","subscribers_url":"https://api.github.com/repos/bclothier/Rubberduck/subscribers","subscription_url":"https://api.github.com/repos/bclothier/Rubberduck/subscription","commits_url":"https://api.github.com/repos/bclothier/Rubberduck/commits{/sha}","git_commits_url":"https://api.github.com/repos/bclothier/Rubberduck/git/commits{/sha}","comments_url":"https://api.github.com/repos/bclothier/Rubberduck/comments{/number}","issue_comment_url":"https://api.github.com/repos/bclothier/Rubberduck/issues/comments{/number}","contents_url":"https://api.github.com/repos/bclothier/Rubberduck/contents/{+path}","compare_url":"https://api.github.com/repos/bclothier/Rubberduck/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bclothier/Rubberduck/merges","archive_url":"https://api.github.com/repos/bclothier/Rubberduck/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bclothier/Rubberduck/downloads","issues_url":"https://api.github.com/repos/bclothier/Rubberduck/issues{/number}","pulls_url":"https://api.github.com/repos/bclothier/Rubberduck/pulls{/number}","milestones_url":"https://api.github.com/repos/bclothier/Rubberduck/milestones{/number}","notifications_url":"https://api.github.com/repos/bclothier/Rubberduck/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bclothier/Rubberduck/labels{/name}","releases_url":"https://api.github.com/repos/bclothier/Rubberduck/releases{/id}","deployments_url":"https://api.github.com/repos/bclothier/Rubberduck/deployments","created_at":"2017-09-06T00:21:49Z","updated_at":"2017-09-06T00:21:55Z","pushed_at":"2018-02-22T17:40:40Z","git_url":"git://github.com/bclothier/Rubberduck.git","ssh_url":"git@github.com:bclothier/Rubberduck.git","clone_url":"https://github.com/bclothier/Rubberduck.git","svn_url":"https://github.com/bclothier/Rubberduck","homepage":"","size":43437,"stargazers_count":0,"watchers_count":0,"language":"C#","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":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"next"}},"base":{"label":"rubberduck-vba:next","ref":"next","sha":"0a8fcdb5d820528f362f8c6039d8c437e72b4044","user":{"login":"rubberduck-vba","id":12832254,"avatar_url":"https://avatars0.githubusercontent.com/u/12832254?v=4","gravatar_id":"","url":"https://api.github.com/users/rubberduck-vba","html_url":"https://github.com/rubberduck-vba","followers_url":"https://api.github.com/users/rubberduck-vba/followers","following_url":"https://api.github.com/users/rubberduck-vba/following{/other_user}","gists_url":"https://api.github.com/users/rubberduck-vba/gists{/gist_id}","starred_url":"https://api.github.com/users/rubberduck-vba/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rubberduck-vba/subscriptions","organizations_url":"https://api.github.com/users/rubberduck-vba/orgs","repos_url":"https://api.github.com/users/rubberduck-vba/repos","events_url":"https://api.github.com/users/rubberduck-vba/events{/privacy}","received_events_url":"https://api.github.com/users/rubberduck-vba/received_events","type":"Organization","site_admin":false},"repo":{"id":25800128,"name":"Rubberduck","full_name":"rubberduck-vba/Rubberduck","owner":{"login":"rubberduck-vba","id":12832254,"avatar_url":"https://avatars0.githubusercontent.com/u/12832254?v=4","gravatar_id":"","url":"https://api.github.com/users/rubberduck-vba","html_url":"https://github.com/rubberduck-vba","followers_url":"https://api.github.com/users/rubberduck-vba/followers","following_url":"https://api.github.com/users/rubberduck-vba/following{/other_user}","gists_url":"https://api.github.com/users/rubberduck-vba/gists{/gist_id}","starred_url":"https://api.github.com/users/rubberduck-vba/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rubberduck-vba/subscriptions","organizations_url":"https://api.github.com/users/rubberduck-vba/orgs","repos_url":"https://api.github.com/users/rubberduck-vba/repos","events_url":"https://api.github.com/users/rubberduck-vba/events{/privacy}","received_events_url":"https://api.github.com/users/rubberduck-vba/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/rubberduck-vba/Rubberduck","description":"Every programmer needs a rubberduck. COM add-in for the VBA IDE (VBE).","fork":false,"url":"https://api.github.com/repos/rubberduck-vba/Rubberduck","forks_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/forks","keys_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/teams","hooks_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/hooks","issue_events_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/issues/events{/number}","events_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/events","assignees_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/assignees{/user}","branches_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/branches{/branch}","tags_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/tags","blobs_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/git/refs{/sha}","trees_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/statuses/{sha}","languages_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/languages","stargazers_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/stargazers","contributors_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/contributors","subscribers_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/subscribers","subscription_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/subscription","commits_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/commits{/sha}","git_commits_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/git/commits{/sha}","comments_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/comments{/number}","issue_comment_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/issues/comments{/number}","contents_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/contents/{+path}","compare_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/merges","archive_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/downloads","issues_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/issues{/number}","pulls_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls{/number}","milestones_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/milestones{/number}","notifications_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/labels{/name}","releases_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/releases{/id}","deployments_url":"https://api.github.com/repos/rubberduck-vba/Rubberduck/deployments","created_at":"2014-10-27T02:35:11Z","updated_at":"2018-02-22T16:11:31Z","pushed_at":"2018-02-22T19:37:02Z","git_url":"git://github.com/rubberduck-vba/Rubberduck.git","ssh_url":"git@github.com:rubberduck-vba/Rubberduck.git","clone_url":"https://github.com/rubberduck-vba/Rubberduck.git","svn_url":"https://github.com/rubberduck-vba/Rubberduck","homepage":"","size":43649,"stargazers_count":548,"watchers_count":548,"language":"C#","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":148,"mirror_url":null,"archived":false,"open_issues_count":641,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0"},"forks":148,"open_issues":641,"watchers":548,"default_branch":"next"}},"_links":{"self":{"href":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/3701"},"html":{"href":"https://github.com/rubberduck-vba/Rubberduck/pull/3701"},"issue":{"href":"https://api.github.com/repos/rubberduck-vba/Rubberduck/issues/3701"},"comments":{"href":"https://api.github.com/repos/rubberduck-vba/Rubberduck/issues/3701/comments"},"review_comments":{"href":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/3701/comments"},"review_comment":{"href":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/rubberduck-vba/Rubberduck/pulls/3701/commits"},"statuses":{"href":"https://api.github.com/repos/rubberduck-vba/Rubberduck/statuses/fa50478e090dda850c5a0c75b741017c70fede4f"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"bclothier"}}