{"action":"opened","number":58,"pull_request":{"url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/pulls/58","id":224487139,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI0NDg3MTM5","html_url":"https://github.com/scott-mcdonald/JsonApiFramework/pull/58","diff_url":"https://github.com/scott-mcdonald/JsonApiFramework/pull/58.diff","patch_url":"https://github.com/scott-mcdonald/JsonApiFramework/pull/58.patch","issue_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/issues/58","number":58,"state":"open","locked":false,"title":"Prevent InvalidOperationException on DocumentPathContext","user":{"login":"circleupx","id":8635797,"node_id":"MDQ6VXNlcjg2MzU3OTc=","avatar_url":"https://avatars2.githubusercontent.com/u/8635797?v=4","gravatar_id":"","url":"https://api.github.com/users/circleupx","html_url":"https://github.com/circleupx","followers_url":"https://api.github.com/users/circleupx/followers","following_url":"https://api.github.com/users/circleupx/following{/other_user}","gists_url":"https://api.github.com/users/circleupx/gists{/gist_id}","starred_url":"https://api.github.com/users/circleupx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/circleupx/subscriptions","organizations_url":"https://api.github.com/users/circleupx/orgs","repos_url":"https://api.github.com/users/circleupx/repos","events_url":"https://api.github.com/users/circleupx/events{/privacy}","received_events_url":"https://api.github.com/users/circleupx/received_events","type":"User","site_admin":false},"body":"The method GetPrimaryClrResourceType() throws an InvalidOperationException on the .Last() call because ClrResourceTypes at times can be an empty collection. \r\n\r\n> System.InvalidOperationException\r\n  HResult=0x80131509\r\n  Message=Sequence contains no elements\r\n  Source=System.Linq\r\n  StackTrace:\r\n   at System.Linq.Enumerable.Last[TSource](IEnumerable`1 source)\r\n   at JsonApiFramework.Server.Hypermedia.Internal.DocumentPathContext.GetPrimaryClrResourceType() in F:\\repos\\JsonApiFramework\\Source\\JsonApiFramework.Server\\Hypermedia\\Internal\\DocumentPathContext.cs:line 57\r\n\r\nShielding the code by making the code check if ClrResourceTypes has any elements before performing the .Last() call.\r\n\r\n","created_at":"2018-10-20T16:58:08Z","updated_at":"2018-10-20T16:58:08Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/pulls/58/commits","review_comments_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/pulls/58/comments","review_comment_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/pulls/comments{/number}","comments_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/issues/58/comments","statuses_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/statuses/c550c06b8a83c8ac481bee596bea3ee6023f0a7b","head":{"label":"circleupx:f/FixSequenceContainsNoElementsExceptionOnDocumentPathContext","ref":"f/FixSequenceContainsNoElementsExceptionOnDocumentPathContext","sha":"c550c06b8a83c8ac481bee596bea3ee6023f0a7b","user":{"login":"circleupx","id":8635797,"node_id":"MDQ6VXNlcjg2MzU3OTc=","avatar_url":"https://avatars2.githubusercontent.com/u/8635797?v=4","gravatar_id":"","url":"https://api.github.com/users/circleupx","html_url":"https://github.com/circleupx","followers_url":"https://api.github.com/users/circleupx/followers","following_url":"https://api.github.com/users/circleupx/following{/other_user}","gists_url":"https://api.github.com/users/circleupx/gists{/gist_id}","starred_url":"https://api.github.com/users/circleupx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/circleupx/subscriptions","organizations_url":"https://api.github.com/users/circleupx/orgs","repos_url":"https://api.github.com/users/circleupx/repos","events_url":"https://api.github.com/users/circleupx/events{/privacy}","received_events_url":"https://api.github.com/users/circleupx/received_events","type":"User","site_admin":false},"repo":{"id":153923865,"node_id":"MDEwOlJlcG9zaXRvcnkxNTM5MjM4NjU=","name":"JsonApiFramework","full_name":"circleupx/JsonApiFramework","private":false,"owner":{"login":"circleupx","id":8635797,"node_id":"MDQ6VXNlcjg2MzU3OTc=","avatar_url":"https://avatars2.githubusercontent.com/u/8635797?v=4","gravatar_id":"","url":"https://api.github.com/users/circleupx","html_url":"https://github.com/circleupx","followers_url":"https://api.github.com/users/circleupx/followers","following_url":"https://api.github.com/users/circleupx/following{/other_user}","gists_url":"https://api.github.com/users/circleupx/gists{/gist_id}","starred_url":"https://api.github.com/users/circleupx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/circleupx/subscriptions","organizations_url":"https://api.github.com/users/circleupx/orgs","repos_url":"https://api.github.com/users/circleupx/repos","events_url":"https://api.github.com/users/circleupx/events{/privacy}","received_events_url":"https://api.github.com/users/circleupx/received_events","type":"User","site_admin":false},"html_url":"https://github.com/circleupx/JsonApiFramework","description":"JsonApiFramework is a fast, extensible, and portable .NET framework for the reading and writing of JSON API documents. Currently working on ApiFramework 1.0 which is a new framework that supports the many enhancements documented in the 2.0 milestone of this project while being media type agnostic but will support media types like {json:api} and GraphQL for serialization/deserialization purposes.","fork":true,"url":"https://api.github.com/repos/circleupx/JsonApiFramework","forks_url":"https://api.github.com/repos/circleupx/JsonApiFramework/forks","keys_url":"https://api.github.com/repos/circleupx/JsonApiFramework/keys{/key_id}","collaborators_url":"https://api.github.com/repos/circleupx/JsonApiFramework/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/circleupx/JsonApiFramework/teams","hooks_url":"https://api.github.com/repos/circleupx/JsonApiFramework/hooks","issue_events_url":"https://api.github.com/repos/circleupx/JsonApiFramework/issues/events{/number}","events_url":"https://api.github.com/repos/circleupx/JsonApiFramework/events","assignees_url":"https://api.github.com/repos/circleupx/JsonApiFramework/assignees{/user}","branches_url":"https://api.github.com/repos/circleupx/JsonApiFramework/branches{/branch}","tags_url":"https://api.github.com/repos/circleupx/JsonApiFramework/tags","blobs_url":"https://api.github.com/repos/circleupx/JsonApiFramework/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/circleupx/JsonApiFramework/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/circleupx/JsonApiFramework/git/refs{/sha}","trees_url":"https://api.github.com/repos/circleupx/JsonApiFramework/git/trees{/sha}","statuses_url":"https://api.github.com/repos/circleupx/JsonApiFramework/statuses/{sha}","languages_url":"https://api.github.com/repos/circleupx/JsonApiFramework/languages","stargazers_url":"https://api.github.com/repos/circleupx/JsonApiFramework/stargazers","contributors_url":"https://api.github.com/repos/circleupx/JsonApiFramework/contributors","subscribers_url":"https://api.github.com/repos/circleupx/JsonApiFramework/subscribers","subscription_url":"https://api.github.com/repos/circleupx/JsonApiFramework/subscription","commits_url":"https://api.github.com/repos/circleupx/JsonApiFramework/commits{/sha}","git_commits_url":"https://api.github.com/repos/circleupx/JsonApiFramework/git/commits{/sha}","comments_url":"https://api.github.com/repos/circleupx/JsonApiFramework/comments{/number}","issue_comment_url":"https://api.github.com/repos/circleupx/JsonApiFramework/issues/comments{/number}","contents_url":"https://api.github.com/repos/circleupx/JsonApiFramework/contents/{+path}","compare_url":"https://api.github.com/repos/circleupx/JsonApiFramework/compare/{base}...{head}","merges_url":"https://api.github.com/repos/circleupx/JsonApiFramework/merges","archive_url":"https://api.github.com/repos/circleupx/JsonApiFramework/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/circleupx/JsonApiFramework/downloads","issues_url":"https://api.github.com/repos/circleupx/JsonApiFramework/issues{/number}","pulls_url":"https://api.github.com/repos/circleupx/JsonApiFramework/pulls{/number}","milestones_url":"https://api.github.com/repos/circleupx/JsonApiFramework/milestones{/number}","notifications_url":"https://api.github.com/repos/circleupx/JsonApiFramework/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/circleupx/JsonApiFramework/labels{/name}","releases_url":"https://api.github.com/repos/circleupx/JsonApiFramework/releases{/id}","deployments_url":"https://api.github.com/repos/circleupx/JsonApiFramework/deployments","created_at":"2018-10-20T16:12:01Z","updated_at":"2018-10-20T16:12:04Z","pushed_at":"2018-10-20T16:53:48Z","git_url":"git://github.com/circleupx/JsonApiFramework.git","ssh_url":"git@github.com:circleupx/JsonApiFramework.git","clone_url":"https://github.com/circleupx/JsonApiFramework.git","svn_url":"https://github.com/circleupx/JsonApiFramework","homepage":"","size":2545,"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":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"scott-mcdonald:master","ref":"master","sha":"3099e01bad9819367e7e91e7e7537ea73ee32368","user":{"login":"scott-mcdonald","id":8608244,"node_id":"MDQ6VXNlcjg2MDgyNDQ=","avatar_url":"https://avatars3.githubusercontent.com/u/8608244?v=4","gravatar_id":"","url":"https://api.github.com/users/scott-mcdonald","html_url":"https://github.com/scott-mcdonald","followers_url":"https://api.github.com/users/scott-mcdonald/followers","following_url":"https://api.github.com/users/scott-mcdonald/following{/other_user}","gists_url":"https://api.github.com/users/scott-mcdonald/gists{/gist_id}","starred_url":"https://api.github.com/users/scott-mcdonald/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scott-mcdonald/subscriptions","organizations_url":"https://api.github.com/users/scott-mcdonald/orgs","repos_url":"https://api.github.com/users/scott-mcdonald/repos","events_url":"https://api.github.com/users/scott-mcdonald/events{/privacy}","received_events_url":"https://api.github.com/users/scott-mcdonald/received_events","type":"User","site_admin":false},"repo":{"id":65886925,"node_id":"MDEwOlJlcG9zaXRvcnk2NTg4NjkyNQ==","name":"JsonApiFramework","full_name":"scott-mcdonald/JsonApiFramework","private":false,"owner":{"login":"scott-mcdonald","id":8608244,"node_id":"MDQ6VXNlcjg2MDgyNDQ=","avatar_url":"https://avatars3.githubusercontent.com/u/8608244?v=4","gravatar_id":"","url":"https://api.github.com/users/scott-mcdonald","html_url":"https://github.com/scott-mcdonald","followers_url":"https://api.github.com/users/scott-mcdonald/followers","following_url":"https://api.github.com/users/scott-mcdonald/following{/other_user}","gists_url":"https://api.github.com/users/scott-mcdonald/gists{/gist_id}","starred_url":"https://api.github.com/users/scott-mcdonald/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scott-mcdonald/subscriptions","organizations_url":"https://api.github.com/users/scott-mcdonald/orgs","repos_url":"https://api.github.com/users/scott-mcdonald/repos","events_url":"https://api.github.com/users/scott-mcdonald/events{/privacy}","received_events_url":"https://api.github.com/users/scott-mcdonald/received_events","type":"User","site_admin":false},"html_url":"https://github.com/scott-mcdonald/JsonApiFramework","description":"JsonApiFramework is a fast, extensible, and portable .NET framework for the reading and writing of JSON API documents. Currently working on ApiFramework 1.0 which is a new framework that supports the many enhancements documented in the 2.0 milestone of this project while being media type agnostic but will support media types like {json:api} and GraphQL for serialization/deserialization purposes.","fork":false,"url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework","forks_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/forks","keys_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/keys{/key_id}","collaborators_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/teams","hooks_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/hooks","issue_events_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/issues/events{/number}","events_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/events","assignees_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/assignees{/user}","branches_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/branches{/branch}","tags_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/tags","blobs_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/git/refs{/sha}","trees_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/git/trees{/sha}","statuses_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/statuses/{sha}","languages_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/languages","stargazers_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/stargazers","contributors_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/contributors","subscribers_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/subscribers","subscription_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/subscription","commits_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/commits{/sha}","git_commits_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/git/commits{/sha}","comments_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/comments{/number}","issue_comment_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/issues/comments{/number}","contents_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/contents/{+path}","compare_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/compare/{base}...{head}","merges_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/merges","archive_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/downloads","issues_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/issues{/number}","pulls_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/pulls{/number}","milestones_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/milestones{/number}","notifications_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/labels{/name}","releases_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/releases{/id}","deployments_url":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/deployments","created_at":"2016-08-17T07:43:31Z","updated_at":"2018-10-18T20:49:02Z","pushed_at":"2018-10-05T05:41:42Z","git_url":"git://github.com/scott-mcdonald/JsonApiFramework.git","ssh_url":"git@github.com:scott-mcdonald/JsonApiFramework.git","clone_url":"https://github.com/scott-mcdonald/JsonApiFramework.git","svn_url":"https://github.com/scott-mcdonald/JsonApiFramework","homepage":"","size":2545,"stargazers_count":59,"watchers_count":59,"language":"C#","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":8,"mirror_url":null,"archived":false,"open_issues_count":10,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":8,"open_issues":10,"watchers":59,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/pulls/58"},"html":{"href":"https://github.com/scott-mcdonald/JsonApiFramework/pull/58"},"issue":{"href":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/issues/58"},"comments":{"href":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/issues/58/comments"},"review_comments":{"href":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/pulls/58/comments"},"review_comment":{"href":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/pulls/58/commits"},"statuses":{"href":"https://api.github.com/repos/scott-mcdonald/JsonApiFramework/statuses/c550c06b8a83c8ac481bee596bea3ee6023f0a7b"}},"author_association":"NONE","merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"maintainer_can_modify":true,"commits":1,"additions":5,"deletions":1,"changed_files":1}}
{"actor":{"display_login":"circleupx"}}