{"action":"closed","number":354,"pull_request":{"url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/pulls/354","id":89672826,"html_url":"https://github.com/fedspendingtransparency/data-act-broker-backend/pull/354","diff_url":"https://github.com/fedspendingtransparency/data-act-broker-backend/pull/354.diff","patch_url":"https://github.com/fedspendingtransparency/data-act-broker-backend/pull/354.patch","issue_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/issues/354","number":354,"state":"closed","locked":false,"title":"Remaining nonflask db updates","user":{"login":"bsweger","id":540544,"avatar_url":"https://avatars.githubusercontent.com/u/540544?v=3","gravatar_id":"","url":"https://api.github.com/users/bsweger","html_url":"https://github.com/bsweger","followers_url":"https://api.github.com/users/bsweger/followers","following_url":"https://api.github.com/users/bsweger/following{/other_user}","gists_url":"https://api.github.com/users/bsweger/gists{/gist_id}","starred_url":"https://api.github.com/users/bsweger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bsweger/subscriptions","organizations_url":"https://api.github.com/users/bsweger/orgs","repos_url":"https://api.github.com/users/bsweger/repos","events_url":"https://api.github.com/users/bsweger/events{/privacy}","received_events_url":"https://api.github.com/users/bsweger/received_events","type":"User","site_admin":false},"body":"This PR updates some of the previous changes I'd made to get rid of the database interfaces from non-Flask code. The changes are based on team discussions and code reviews and reflect our latest thinking on how best to handle database access within the broker:\r\n\r\n* All db access is not through a flask application context (i.e., no more stand-alone database session context)\r\n* When creating a one-off flask context, do it with the validator's app.py instead of the broker's app.py, which is more resource intensive\r\n* Move a problematic interface function to `function_bag.py` and re-think its session handling in an attempt to fix the intermittent SQLAlchemy errors on local integration test runs","created_at":"2016-10-17T18:04:30Z","updated_at":"2016-10-17T19:54:10Z","closed_at":"2016-10-17T19:54:10Z","merged_at":"2016-10-17T19:54:10Z","merge_commit_sha":"eb27a74e01b5b7703045756f81841f16e0e8aa05","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/pulls/354/commits","review_comments_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/pulls/354/comments","review_comment_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/pulls/comments{/number}","comments_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/issues/354/comments","statuses_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/statuses/9df3f7744d562b43c604dc1a28461ce3f2762125","head":{"label":"fedspendingtransparency:remaining-nonflask-db-updates","ref":"remaining-nonflask-db-updates","sha":"9df3f7744d562b43c604dc1a28461ce3f2762125","user":{"login":"fedspendingtransparency","id":8397762,"avatar_url":"https://avatars.githubusercontent.com/u/8397762?v=3","gravatar_id":"","url":"https://api.github.com/users/fedspendingtransparency","html_url":"https://github.com/fedspendingtransparency","followers_url":"https://api.github.com/users/fedspendingtransparency/followers","following_url":"https://api.github.com/users/fedspendingtransparency/following{/other_user}","gists_url":"https://api.github.com/users/fedspendingtransparency/gists{/gist_id}","starred_url":"https://api.github.com/users/fedspendingtransparency/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fedspendingtransparency/subscriptions","organizations_url":"https://api.github.com/users/fedspendingtransparency/orgs","repos_url":"https://api.github.com/users/fedspendingtransparency/repos","events_url":"https://api.github.com/users/fedspendingtransparency/events{/privacy}","received_events_url":"https://api.github.com/users/fedspendingtransparency/received_events","type":"Organization","site_admin":false},"repo":{"id":57313310,"name":"data-act-broker-backend","full_name":"fedspendingtransparency/data-act-broker-backend","owner":{"login":"fedspendingtransparency","id":8397762,"avatar_url":"https://avatars.githubusercontent.com/u/8397762?v=3","gravatar_id":"","url":"https://api.github.com/users/fedspendingtransparency","html_url":"https://github.com/fedspendingtransparency","followers_url":"https://api.github.com/users/fedspendingtransparency/followers","following_url":"https://api.github.com/users/fedspendingtransparency/following{/other_user}","gists_url":"https://api.github.com/users/fedspendingtransparency/gists{/gist_id}","starred_url":"https://api.github.com/users/fedspendingtransparency/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fedspendingtransparency/subscriptions","organizations_url":"https://api.github.com/users/fedspendingtransparency/orgs","repos_url":"https://api.github.com/users/fedspendingtransparency/repos","events_url":"https://api.github.com/users/fedspendingtransparency/events{/privacy}","received_events_url":"https://api.github.com/users/fedspendingtransparency/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/fedspendingtransparency/data-act-broker-backend","description":null,"fork":false,"url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend","forks_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/forks","keys_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/teams","hooks_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/hooks","issue_events_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/issues/events{/number}","events_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/events","assignees_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/assignees{/user}","branches_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/branches{/branch}","tags_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/tags","blobs_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/git/refs{/sha}","trees_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/statuses/{sha}","languages_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/languages","stargazers_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/stargazers","contributors_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/contributors","subscribers_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/subscribers","subscription_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/subscription","commits_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/commits{/sha}","git_commits_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/git/commits{/sha}","comments_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/comments{/number}","issue_comment_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/issues/comments{/number}","contents_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/contents/{+path}","compare_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/merges","archive_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/downloads","issues_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/issues{/number}","pulls_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/pulls{/number}","milestones_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/milestones{/number}","notifications_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/labels{/name}","releases_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/releases{/id}","deployments_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/deployments","created_at":"2016-04-28T15:39:36Z","updated_at":"2016-08-30T17:03:39Z","pushed_at":"2016-10-17T19:54:10Z","git_url":"git://github.com/fedspendingtransparency/data-act-broker-backend.git","ssh_url":"git@github.com:fedspendingtransparency/data-act-broker-backend.git","clone_url":"https://github.com/fedspendingtransparency/data-act-broker-backend.git","svn_url":"https://github.com/fedspendingtransparency/data-act-broker-backend","homepage":null,"size":52917,"stargazers_count":1,"watchers_count":1,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":2,"forks":2,"open_issues":2,"watchers":1,"default_branch":"master"}},"base":{"label":"fedspendingtransparency:development","ref":"development","sha":"859743fca36fc860703f9a77862b0d543fa3897b","user":{"login":"fedspendingtransparency","id":8397762,"avatar_url":"https://avatars.githubusercontent.com/u/8397762?v=3","gravatar_id":"","url":"https://api.github.com/users/fedspendingtransparency","html_url":"https://github.com/fedspendingtransparency","followers_url":"https://api.github.com/users/fedspendingtransparency/followers","following_url":"https://api.github.com/users/fedspendingtransparency/following{/other_user}","gists_url":"https://api.github.com/users/fedspendingtransparency/gists{/gist_id}","starred_url":"https://api.github.com/users/fedspendingtransparency/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fedspendingtransparency/subscriptions","organizations_url":"https://api.github.com/users/fedspendingtransparency/orgs","repos_url":"https://api.github.com/users/fedspendingtransparency/repos","events_url":"https://api.github.com/users/fedspendingtransparency/events{/privacy}","received_events_url":"https://api.github.com/users/fedspendingtransparency/received_events","type":"Organization","site_admin":false},"repo":{"id":57313310,"name":"data-act-broker-backend","full_name":"fedspendingtransparency/data-act-broker-backend","owner":{"login":"fedspendingtransparency","id":8397762,"avatar_url":"https://avatars.githubusercontent.com/u/8397762?v=3","gravatar_id":"","url":"https://api.github.com/users/fedspendingtransparency","html_url":"https://github.com/fedspendingtransparency","followers_url":"https://api.github.com/users/fedspendingtransparency/followers","following_url":"https://api.github.com/users/fedspendingtransparency/following{/other_user}","gists_url":"https://api.github.com/users/fedspendingtransparency/gists{/gist_id}","starred_url":"https://api.github.com/users/fedspendingtransparency/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fedspendingtransparency/subscriptions","organizations_url":"https://api.github.com/users/fedspendingtransparency/orgs","repos_url":"https://api.github.com/users/fedspendingtransparency/repos","events_url":"https://api.github.com/users/fedspendingtransparency/events{/privacy}","received_events_url":"https://api.github.com/users/fedspendingtransparency/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/fedspendingtransparency/data-act-broker-backend","description":null,"fork":false,"url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend","forks_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/forks","keys_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/teams","hooks_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/hooks","issue_events_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/issues/events{/number}","events_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/events","assignees_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/assignees{/user}","branches_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/branches{/branch}","tags_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/tags","blobs_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/git/refs{/sha}","trees_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/statuses/{sha}","languages_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/languages","stargazers_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/stargazers","contributors_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/contributors","subscribers_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/subscribers","subscription_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/subscription","commits_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/commits{/sha}","git_commits_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/git/commits{/sha}","comments_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/comments{/number}","issue_comment_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/issues/comments{/number}","contents_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/contents/{+path}","compare_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/merges","archive_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/downloads","issues_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/issues{/number}","pulls_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/pulls{/number}","milestones_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/milestones{/number}","notifications_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/labels{/name}","releases_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/releases{/id}","deployments_url":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/deployments","created_at":"2016-04-28T15:39:36Z","updated_at":"2016-08-30T17:03:39Z","pushed_at":"2016-10-17T19:54:10Z","git_url":"git://github.com/fedspendingtransparency/data-act-broker-backend.git","ssh_url":"git@github.com:fedspendingtransparency/data-act-broker-backend.git","clone_url":"https://github.com/fedspendingtransparency/data-act-broker-backend.git","svn_url":"https://github.com/fedspendingtransparency/data-act-broker-backend","homepage":null,"size":52917,"stargazers_count":1,"watchers_count":1,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":2,"forks":2,"open_issues":2,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/pulls/354"},"html":{"href":"https://github.com/fedspendingtransparency/data-act-broker-backend/pull/354"},"issue":{"href":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/issues/354"},"comments":{"href":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/issues/354/comments"},"review_comments":{"href":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/pulls/354/comments"},"review_comment":{"href":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/pulls/354/commits"},"statuses":{"href":"https://api.github.com/repos/fedspendingtransparency/data-act-broker-backend/statuses/9df3f7744d562b43c604dc1a28461ce3f2762125"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"cmc333333","id":326918,"avatar_url":"https://avatars.githubusercontent.com/u/326918?v=3","gravatar_id":"","url":"https://api.github.com/users/cmc333333","html_url":"https://github.com/cmc333333","followers_url":"https://api.github.com/users/cmc333333/followers","following_url":"https://api.github.com/users/cmc333333/following{/other_user}","gists_url":"https://api.github.com/users/cmc333333/gists{/gist_id}","starred_url":"https://api.github.com/users/cmc333333/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cmc333333/subscriptions","organizations_url":"https://api.github.com/users/cmc333333/orgs","repos_url":"https://api.github.com/users/cmc333333/repos","events_url":"https://api.github.com/users/cmc333333/events{/privacy}","received_events_url":"https://api.github.com/users/cmc333333/received_events","type":"User","site_admin":false},"comments":2,"review_comments":13,"commits":8,"additions":205,"deletions":178,"changed_files":19}}
{"actor":{"display_login":"cmc333333"}}