{"action":"closed","number":528,"pull_request":{"url":"https://api.github.com/repos/scalanlp/breeze/pulls/528","id":67128052,"html_url":"https://github.com/scalanlp/breeze/pull/528","diff_url":"https://github.com/scalanlp/breeze/pull/528.diff","patch_url":"https://github.com/scalanlp/breeze/pull/528.patch","issue_url":"https://api.github.com/repos/scalanlp/breeze/issues/528","number":528,"state":"closed","locked":false,"title":"bug fix: assert that operations on different sized vectors fail. ","user":{"login":"adgaudio","id":860369,"avatar_url":"https://avatars.githubusercontent.com/u/860369?v=3","gravatar_id":"","url":"https://api.github.com/users/adgaudio","html_url":"https://github.com/adgaudio","followers_url":"https://api.github.com/users/adgaudio/followers","following_url":"https://api.github.com/users/adgaudio/following{/other_user}","gists_url":"https://api.github.com/users/adgaudio/gists{/gist_id}","starred_url":"https://api.github.com/users/adgaudio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adgaudio/subscriptions","organizations_url":"https://api.github.com/users/adgaudio/orgs","repos_url":"https://api.github.com/users/adgaudio/repos","events_url":"https://api.github.com/users/adgaudio/events{/privacy}","received_events_url":"https://api.github.com/users/adgaudio/received_events","type":"User","site_admin":false},"body":"In issue #515 I pointed out that the following bug exists:\r\n\r\n```\r\nscala> val a = DenseVector(1, 2, 3, 4, 5)\r\na: breeze.linalg.DenseVector[Int] = DenseVector(1, 2, 3, 4, 5)\r\n\r\nscala> val b = DenseVector(1, 2, 3)\r\nb: breeze.linalg.DenseVector[Int] = DenseVector(1, 2, 3)\r\n\r\nscala> b + a\r\nres71: breeze.linalg.DenseVector[Int] = DenseVector(2, 4, 6)\r\n\r\nscala> a + b\r\njava.lang.ArrayIndexOutOfBoundsException: 3\r\n  at breeze.linalg.operators.DenseVectorOps$$anon$142.apply(DenseVectorOps.scala:161)\r\n  at breeze.linalg.operators.DenseVectorOps$$anon$142.apply(DenseVectorOps.scala:150)\r\n  at breeze.linalg.NumericOps$class.$plus(NumericOps.scala:172)\r\n  at breeze.linalg.DenseVector.$plus(DenseVector.scala:51)\r\n  ... 42 elided\r\n```\r\n\r\nIn this PR, I added some assertions to ensure that both `a + b` and `b + a` will throw errors.  I also added a couple tests.  Please let me know whether I should make further changes, and thank you!","created_at":"2016-04-20T04:48:07Z","updated_at":"2016-04-22T06:55:21Z","closed_at":"2016-04-22T06:55:21Z","merged_at":"2016-04-22T06:55:21Z","merge_commit_sha":"89a9921bbbd6ea270aa4c1353534f84bbf280a80","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/scalanlp/breeze/pulls/528/commits","review_comments_url":"https://api.github.com/repos/scalanlp/breeze/pulls/528/comments","review_comment_url":"https://api.github.com/repos/scalanlp/breeze/pulls/comments{/number}","comments_url":"https://api.github.com/repos/scalanlp/breeze/issues/528/comments","statuses_url":"https://api.github.com/repos/scalanlp/breeze/statuses/abf27360a979f88a98c54f0d5e9ebc83c3ac21b4","head":{"label":"adgaudio:nonequalsize-bug","ref":"nonequalsize-bug","sha":"abf27360a979f88a98c54f0d5e9ebc83c3ac21b4","user":{"login":"adgaudio","id":860369,"avatar_url":"https://avatars.githubusercontent.com/u/860369?v=3","gravatar_id":"","url":"https://api.github.com/users/adgaudio","html_url":"https://github.com/adgaudio","followers_url":"https://api.github.com/users/adgaudio/followers","following_url":"https://api.github.com/users/adgaudio/following{/other_user}","gists_url":"https://api.github.com/users/adgaudio/gists{/gist_id}","starred_url":"https://api.github.com/users/adgaudio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adgaudio/subscriptions","organizations_url":"https://api.github.com/users/adgaudio/orgs","repos_url":"https://api.github.com/users/adgaudio/repos","events_url":"https://api.github.com/users/adgaudio/events{/privacy}","received_events_url":"https://api.github.com/users/adgaudio/received_events","type":"User","site_admin":false},"repo":{"id":51104865,"name":"breeze","full_name":"adgaudio/breeze","owner":{"login":"adgaudio","id":860369,"avatar_url":"https://avatars.githubusercontent.com/u/860369?v=3","gravatar_id":"","url":"https://api.github.com/users/adgaudio","html_url":"https://github.com/adgaudio","followers_url":"https://api.github.com/users/adgaudio/followers","following_url":"https://api.github.com/users/adgaudio/following{/other_user}","gists_url":"https://api.github.com/users/adgaudio/gists{/gist_id}","starred_url":"https://api.github.com/users/adgaudio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adgaudio/subscriptions","organizations_url":"https://api.github.com/users/adgaudio/orgs","repos_url":"https://api.github.com/users/adgaudio/repos","events_url":"https://api.github.com/users/adgaudio/events{/privacy}","received_events_url":"https://api.github.com/users/adgaudio/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/adgaudio/breeze","description":"Breeze is a numerical processing library for Scala.","fork":true,"url":"https://api.github.com/repos/adgaudio/breeze","forks_url":"https://api.github.com/repos/adgaudio/breeze/forks","keys_url":"https://api.github.com/repos/adgaudio/breeze/keys{/key_id}","collaborators_url":"https://api.github.com/repos/adgaudio/breeze/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/adgaudio/breeze/teams","hooks_url":"https://api.github.com/repos/adgaudio/breeze/hooks","issue_events_url":"https://api.github.com/repos/adgaudio/breeze/issues/events{/number}","events_url":"https://api.github.com/repos/adgaudio/breeze/events","assignees_url":"https://api.github.com/repos/adgaudio/breeze/assignees{/user}","branches_url":"https://api.github.com/repos/adgaudio/breeze/branches{/branch}","tags_url":"https://api.github.com/repos/adgaudio/breeze/tags","blobs_url":"https://api.github.com/repos/adgaudio/breeze/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/adgaudio/breeze/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/adgaudio/breeze/git/refs{/sha}","trees_url":"https://api.github.com/repos/adgaudio/breeze/git/trees{/sha}","statuses_url":"https://api.github.com/repos/adgaudio/breeze/statuses/{sha}","languages_url":"https://api.github.com/repos/adgaudio/breeze/languages","stargazers_url":"https://api.github.com/repos/adgaudio/breeze/stargazers","contributors_url":"https://api.github.com/repos/adgaudio/breeze/contributors","subscribers_url":"https://api.github.com/repos/adgaudio/breeze/subscribers","subscription_url":"https://api.github.com/repos/adgaudio/breeze/subscription","commits_url":"https://api.github.com/repos/adgaudio/breeze/commits{/sha}","git_commits_url":"https://api.github.com/repos/adgaudio/breeze/git/commits{/sha}","comments_url":"https://api.github.com/repos/adgaudio/breeze/comments{/number}","issue_comment_url":"https://api.github.com/repos/adgaudio/breeze/issues/comments{/number}","contents_url":"https://api.github.com/repos/adgaudio/breeze/contents/{+path}","compare_url":"https://api.github.com/repos/adgaudio/breeze/compare/{base}...{head}","merges_url":"https://api.github.com/repos/adgaudio/breeze/merges","archive_url":"https://api.github.com/repos/adgaudio/breeze/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/adgaudio/breeze/downloads","issues_url":"https://api.github.com/repos/adgaudio/breeze/issues{/number}","pulls_url":"https://api.github.com/repos/adgaudio/breeze/pulls{/number}","milestones_url":"https://api.github.com/repos/adgaudio/breeze/milestones{/number}","notifications_url":"https://api.github.com/repos/adgaudio/breeze/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/adgaudio/breeze/labels{/name}","releases_url":"https://api.github.com/repos/adgaudio/breeze/releases{/id}","deployments_url":"https://api.github.com/repos/adgaudio/breeze/deployments","created_at":"2016-02-04T20:56:06Z","updated_at":"2016-02-04T20:56:08Z","pushed_at":"2016-04-20T04:45:58Z","git_url":"git://github.com/adgaudio/breeze.git","ssh_url":"git@github.com:adgaudio/breeze.git","clone_url":"https://github.com/adgaudio/breeze.git","svn_url":"https://github.com/adgaudio/breeze","homepage":"www.scalanlp.org","size":26045,"stargazers_count":0,"watchers_count":0,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"scalanlp:master","ref":"master","sha":"44d7b5a74b504ce23fcc1e09ba71542c6b294339","user":{"login":"scalanlp","id":103090,"avatar_url":"https://avatars.githubusercontent.com/u/103090?v=3","gravatar_id":"","url":"https://api.github.com/users/scalanlp","html_url":"https://github.com/scalanlp","followers_url":"https://api.github.com/users/scalanlp/followers","following_url":"https://api.github.com/users/scalanlp/following{/other_user}","gists_url":"https://api.github.com/users/scalanlp/gists{/gist_id}","starred_url":"https://api.github.com/users/scalanlp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scalanlp/subscriptions","organizations_url":"https://api.github.com/users/scalanlp/orgs","repos_url":"https://api.github.com/users/scalanlp/repos","events_url":"https://api.github.com/users/scalanlp/events{/privacy}","received_events_url":"https://api.github.com/users/scalanlp/received_events","type":"Organization","site_admin":false},"repo":{"id":246644,"name":"breeze","full_name":"scalanlp/breeze","owner":{"login":"scalanlp","id":103090,"avatar_url":"https://avatars.githubusercontent.com/u/103090?v=3","gravatar_id":"","url":"https://api.github.com/users/scalanlp","html_url":"https://github.com/scalanlp","followers_url":"https://api.github.com/users/scalanlp/followers","following_url":"https://api.github.com/users/scalanlp/following{/other_user}","gists_url":"https://api.github.com/users/scalanlp/gists{/gist_id}","starred_url":"https://api.github.com/users/scalanlp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scalanlp/subscriptions","organizations_url":"https://api.github.com/users/scalanlp/orgs","repos_url":"https://api.github.com/users/scalanlp/repos","events_url":"https://api.github.com/users/scalanlp/events{/privacy}","received_events_url":"https://api.github.com/users/scalanlp/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/scalanlp/breeze","description":"Breeze is a numerical processing library for Scala.","fork":false,"url":"https://api.github.com/repos/scalanlp/breeze","forks_url":"https://api.github.com/repos/scalanlp/breeze/forks","keys_url":"https://api.github.com/repos/scalanlp/breeze/keys{/key_id}","collaborators_url":"https://api.github.com/repos/scalanlp/breeze/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/scalanlp/breeze/teams","hooks_url":"https://api.github.com/repos/scalanlp/breeze/hooks","issue_events_url":"https://api.github.com/repos/scalanlp/breeze/issues/events{/number}","events_url":"https://api.github.com/repos/scalanlp/breeze/events","assignees_url":"https://api.github.com/repos/scalanlp/breeze/assignees{/user}","branches_url":"https://api.github.com/repos/scalanlp/breeze/branches{/branch}","tags_url":"https://api.github.com/repos/scalanlp/breeze/tags","blobs_url":"https://api.github.com/repos/scalanlp/breeze/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/scalanlp/breeze/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/scalanlp/breeze/git/refs{/sha}","trees_url":"https://api.github.com/repos/scalanlp/breeze/git/trees{/sha}","statuses_url":"https://api.github.com/repos/scalanlp/breeze/statuses/{sha}","languages_url":"https://api.github.com/repos/scalanlp/breeze/languages","stargazers_url":"https://api.github.com/repos/scalanlp/breeze/stargazers","contributors_url":"https://api.github.com/repos/scalanlp/breeze/contributors","subscribers_url":"https://api.github.com/repos/scalanlp/breeze/subscribers","subscription_url":"https://api.github.com/repos/scalanlp/breeze/subscription","commits_url":"https://api.github.com/repos/scalanlp/breeze/commits{/sha}","git_commits_url":"https://api.github.com/repos/scalanlp/breeze/git/commits{/sha}","comments_url":"https://api.github.com/repos/scalanlp/breeze/comments{/number}","issue_comment_url":"https://api.github.com/repos/scalanlp/breeze/issues/comments{/number}","contents_url":"https://api.github.com/repos/scalanlp/breeze/contents/{+path}","compare_url":"https://api.github.com/repos/scalanlp/breeze/compare/{base}...{head}","merges_url":"https://api.github.com/repos/scalanlp/breeze/merges","archive_url":"https://api.github.com/repos/scalanlp/breeze/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/scalanlp/breeze/downloads","issues_url":"https://api.github.com/repos/scalanlp/breeze/issues{/number}","pulls_url":"https://api.github.com/repos/scalanlp/breeze/pulls{/number}","milestones_url":"https://api.github.com/repos/scalanlp/breeze/milestones{/number}","notifications_url":"https://api.github.com/repos/scalanlp/breeze/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/scalanlp/breeze/labels{/name}","releases_url":"https://api.github.com/repos/scalanlp/breeze/releases{/id}","deployments_url":"https://api.github.com/repos/scalanlp/breeze/deployments","created_at":"2009-07-08T23:22:52Z","updated_at":"2016-04-22T01:23:48Z","pushed_at":"2016-04-22T06:55:22Z","git_url":"git://github.com/scalanlp/breeze.git","ssh_url":"git@github.com:scalanlp/breeze.git","clone_url":"https://github.com/scalanlp/breeze.git","svn_url":"https://github.com/scalanlp/breeze","homepage":"www.scalanlp.org","size":27476,"stargazers_count":1480,"watchers_count":1480,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":393,"mirror_url":null,"open_issues_count":72,"forks":393,"open_issues":72,"watchers":1480,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/scalanlp/breeze/pulls/528"},"html":{"href":"https://github.com/scalanlp/breeze/pull/528"},"issue":{"href":"https://api.github.com/repos/scalanlp/breeze/issues/528"},"comments":{"href":"https://api.github.com/repos/scalanlp/breeze/issues/528/comments"},"review_comments":{"href":"https://api.github.com/repos/scalanlp/breeze/pulls/528/comments"},"review_comment":{"href":"https://api.github.com/repos/scalanlp/breeze/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/scalanlp/breeze/pulls/528/commits"},"statuses":{"href":"https://api.github.com/repos/scalanlp/breeze/statuses/abf27360a979f88a98c54f0d5e9ebc83c3ac21b4"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"dlwh","id":9633,"avatar_url":"https://avatars.githubusercontent.com/u/9633?v=3","gravatar_id":"","url":"https://api.github.com/users/dlwh","html_url":"https://github.com/dlwh","followers_url":"https://api.github.com/users/dlwh/followers","following_url":"https://api.github.com/users/dlwh/following{/other_user}","gists_url":"https://api.github.com/users/dlwh/gists{/gist_id}","starred_url":"https://api.github.com/users/dlwh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dlwh/subscriptions","organizations_url":"https://api.github.com/users/dlwh/orgs","repos_url":"https://api.github.com/users/dlwh/repos","events_url":"https://api.github.com/users/dlwh/events{/privacy}","received_events_url":"https://api.github.com/users/dlwh/received_events","type":"User","site_admin":false},"comments":0,"review_comments":0,"commits":1,"additions":36,"deletions":2,"changed_files":3}}