{"action":"closed","number":28,"pull_request":{"url":"https://api.github.com/repos/Oslandia/qgis-versioning/pulls/28","id":51111563,"html_url":"https://github.com/Oslandia/qgis-versioning/pull/28","diff_url":"https://github.com/Oslandia/qgis-versioning/pull/28.diff","patch_url":"https://github.com/Oslandia/qgis-versioning/pull/28.patch","issue_url":"https://api.github.com/repos/Oslandia/qgis-versioning/issues/28","number":28,"state":"closed","locked":false,"title":"General commit and update modifications","user":{"login":"ymoisan","id":7468595,"avatar_url":"https://avatars.githubusercontent.com/u/7468595?v=3","gravatar_id":"","url":"https://api.github.com/users/ymoisan","html_url":"https://github.com/ymoisan","followers_url":"https://api.github.com/users/ymoisan/followers","following_url":"https://api.github.com/users/ymoisan/following{/other_user}","gists_url":"https://api.github.com/users/ymoisan/gists{/gist_id}","starred_url":"https://api.github.com/users/ymoisan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ymoisan/subscriptions","organizations_url":"https://api.github.com/users/ymoisan/orgs","repos_url":"https://api.github.com/users/ymoisan/repos","events_url":"https://api.github.com/users/ymoisan/events{/privacy}","received_events_url":"https://api.github.com/users/ymoisan/received_events","type":"User","site_admin":false},"body":"In relation to GISeHealth#19,  GISeHealth#20 and GISeHealth#2, here is a series of edits to versioning.py. \r\n\r\n- Added force refresh of the canvas after update, if any\r\n\r\nRationale : the user should not have to pan or zoom in the map to see changes to geometries that were updated into the working copy (https://github.com/GISeHealth/qgis-versioning/issues/19)\r\n\r\n- Modified the update process : if the current revision of the working copy is not late (late_by = 0), no update is performed and an info message \"Working copy already up to date with remote revision\" pops; else, a warning message[1] tells the user the working copy was late by \"N\" commits and it was updated.\r\n\r\nRationale : updating forces changes into the working copy.  Even though unmodified features in the working copy can be logically thought of as being readily overridable (I'm personnally not so sure as it may well be that the current editor wants features the way they are in his working copy), I feel it is important to let the user know if something was really written in the working copy.  If the working copy is up to date with the versioned database, then we don't run [pg_]update and let the user know there was no change.  If there were changes, the plugin needs a way to notify the user, as those changes may not be noticeable on the map (e.g. attribute changes).  \r\n\r\n- Fixed \"rev= \" type strings in menu; after commit or update, the rev number is now readily incremented in the QGIS group; the user no longer has to click some other element in the legend for the number to be incremented\r\n\r\n- Changed vocabulary relative to revisions; remote revisions pertain to the central DB and local revs to working copies.\r\n\r\nRationale : revision numbers as presented to the user in the normal operation of the plugin were misleading.  First, there was no distinction between revisions in the working copy and remote revisions.  Second, revision numbers as shown in the pop ups and on the plugin menu [2] sometimes differed and the difference was hard to understand.  The change in vocabulary now makes it clearer to the user what is their working revision and what is the remote revision.  It makes sense given that context that the local revision is +1 with respect to the remote revision.\r\n\r\n- Added the prefix \"Versioning : \" to setText messages appearing in the leftmost section of the plugin menu.\r\n\r\nRationale : Messages that show up alone in the plugin menu, that is without any of the plugin icons (like \"No group selected\") are a bit odd for users since nothing tells them that this string comes from the plugin.  \"Versioning : no group selected\" makes the association clearer.  If there were a way to identify the plugin menu graphically so that strings/messages showing up there could be readily associated with the plugin, then we could drop the prefix.  I have a \"docs\" branch that adds a \"help\" button in the plugin menu so when that gets merged then there will be at least one icon always showing up in the plugin menu.  When the user clicks on a versioned group then the plugin menu populates with many icons and therefore messages are easier to associate as emanating from the plugin.  For that reason messages involving a filename or database name were not preprended with the prefix.\r\n\r\n- Pep 8 : there are still lines of code > 80 chars; I fixed mine (one of my strings were keeping my editor from folding the code correctly)\r\n\r\n- Got rid of extra spaces between defs so that code folding in editors looks cleaner\r\n\r\n[1] Could be an info message but I think warning is warranted here since changes were pushed in the working copy.  The info box (information messages in general ?) could be changed to a message bar to avoid user clicks.\r\n\r\n[2] I took the liberty to make the revision string bold in the plugin menu; it is debatable, but the objective here is to make the leftmost string in the plugin menu clearer; it is now a concatenation of several items (db name, db schema, filename for spatialite, revision number) and, short of having a way to present the string in a cleaner manner I thought using some formatting would help","created_at":"2015-11-18T17:01:25Z","updated_at":"2015-12-07T09:45:49Z","closed_at":"2015-12-07T09:45:49Z","merged_at":"2015-12-07T09:45:49Z","merge_commit_sha":"7f84c3fb64640b96c021e30b23e5d4dfc3af5d43","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Oslandia/qgis-versioning/pulls/28/commits","review_comments_url":"https://api.github.com/repos/Oslandia/qgis-versioning/pulls/28/comments","review_comment_url":"https://api.github.com/repos/Oslandia/qgis-versioning/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Oslandia/qgis-versioning/issues/28/comments","statuses_url":"https://api.github.com/repos/Oslandia/qgis-versioning/statuses/a47855b104da6f33a9ab5eabe2a55723ce57f7ef","head":{"label":"GISeHealth:gh19eha","ref":"gh19eha","sha":"a47855b104da6f33a9ab5eabe2a55723ce57f7ef","user":{"login":"GISeHealth","id":10815649,"avatar_url":"https://avatars.githubusercontent.com/u/10815649?v=3","gravatar_id":"","url":"https://api.github.com/users/GISeHealth","html_url":"https://github.com/GISeHealth","followers_url":"https://api.github.com/users/GISeHealth/followers","following_url":"https://api.github.com/users/GISeHealth/following{/other_user}","gists_url":"https://api.github.com/users/GISeHealth/gists{/gist_id}","starred_url":"https://api.github.com/users/GISeHealth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GISeHealth/subscriptions","organizations_url":"https://api.github.com/users/GISeHealth/orgs","repos_url":"https://api.github.com/users/GISeHealth/repos","events_url":"https://api.github.com/users/GISeHealth/events{/privacy}","received_events_url":"https://api.github.com/users/GISeHealth/received_events","type":"Organization","site_admin":false},"repo":{"id":39340578,"name":"qgis-versioning","full_name":"GISeHealth/qgis-versioning","owner":{"login":"GISeHealth","id":10815649,"avatar_url":"https://avatars.githubusercontent.com/u/10815649?v=3","gravatar_id":"","url":"https://api.github.com/users/GISeHealth","html_url":"https://github.com/GISeHealth","followers_url":"https://api.github.com/users/GISeHealth/followers","following_url":"https://api.github.com/users/GISeHealth/following{/other_user}","gists_url":"https://api.github.com/users/GISeHealth/gists{/gist_id}","starred_url":"https://api.github.com/users/GISeHealth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GISeHealth/subscriptions","organizations_url":"https://api.github.com/users/GISeHealth/orgs","repos_url":"https://api.github.com/users/GISeHealth/repos","events_url":"https://api.github.com/users/GISeHealth/events{/privacy}","received_events_url":"https://api.github.com/users/GISeHealth/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/GISeHealth/qgis-versioning","description":"Version postgresql DB from qgis and work offline on spatialite working copies","fork":true,"url":"https://api.github.com/repos/GISeHealth/qgis-versioning","forks_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/forks","keys_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/teams","hooks_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/hooks","issue_events_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/issues/events{/number}","events_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/events","assignees_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/assignees{/user}","branches_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/branches{/branch}","tags_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/tags","blobs_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/git/refs{/sha}","trees_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/statuses/{sha}","languages_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/languages","stargazers_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/stargazers","contributors_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/contributors","subscribers_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/subscribers","subscription_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/subscription","commits_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/commits{/sha}","git_commits_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/git/commits{/sha}","comments_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/comments{/number}","issue_comment_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/issues/comments{/number}","contents_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/contents/{+path}","compare_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/merges","archive_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/downloads","issues_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/issues{/number}","pulls_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/pulls{/number}","milestones_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/milestones{/number}","notifications_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/labels{/name}","releases_url":"https://api.github.com/repos/GISeHealth/qgis-versioning/releases{/id}","created_at":"2015-07-19T16:32:01Z","updated_at":"2015-10-01T13:46:19Z","pushed_at":"2015-11-25T19:44:27Z","git_url":"git://github.com/GISeHealth/qgis-versioning.git","ssh_url":"git@github.com:GISeHealth/qgis-versioning.git","clone_url":"https://github.com/GISeHealth/qgis-versioning.git","svn_url":"https://github.com/GISeHealth/qgis-versioning","homepage":null,"size":838,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":20,"forks":0,"open_issues":20,"watchers":0,"default_branch":"master"}},"base":{"label":"Oslandia:master","ref":"master","sha":"0101af497edf8db7d9aca386361dae45638a1541","user":{"login":"Oslandia","id":1655161,"avatar_url":"https://avatars.githubusercontent.com/u/1655161?v=3","gravatar_id":"","url":"https://api.github.com/users/Oslandia","html_url":"https://github.com/Oslandia","followers_url":"https://api.github.com/users/Oslandia/followers","following_url":"https://api.github.com/users/Oslandia/following{/other_user}","gists_url":"https://api.github.com/users/Oslandia/gists{/gist_id}","starred_url":"https://api.github.com/users/Oslandia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Oslandia/subscriptions","organizations_url":"https://api.github.com/users/Oslandia/orgs","repos_url":"https://api.github.com/users/Oslandia/repos","events_url":"https://api.github.com/users/Oslandia/events{/privacy}","received_events_url":"https://api.github.com/users/Oslandia/received_events","type":"Organization","site_admin":false},"repo":{"id":18211760,"name":"qgis-versioning","full_name":"Oslandia/qgis-versioning","owner":{"login":"Oslandia","id":1655161,"avatar_url":"https://avatars.githubusercontent.com/u/1655161?v=3","gravatar_id":"","url":"https://api.github.com/users/Oslandia","html_url":"https://github.com/Oslandia","followers_url":"https://api.github.com/users/Oslandia/followers","following_url":"https://api.github.com/users/Oslandia/following{/other_user}","gists_url":"https://api.github.com/users/Oslandia/gists{/gist_id}","starred_url":"https://api.github.com/users/Oslandia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Oslandia/subscriptions","organizations_url":"https://api.github.com/users/Oslandia/orgs","repos_url":"https://api.github.com/users/Oslandia/repos","events_url":"https://api.github.com/users/Oslandia/events{/privacy}","received_events_url":"https://api.github.com/users/Oslandia/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Oslandia/qgis-versioning","description":"Version postgresql DB from qgis and work offline on spatialite working copies","fork":false,"url":"https://api.github.com/repos/Oslandia/qgis-versioning","forks_url":"https://api.github.com/repos/Oslandia/qgis-versioning/forks","keys_url":"https://api.github.com/repos/Oslandia/qgis-versioning/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Oslandia/qgis-versioning/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Oslandia/qgis-versioning/teams","hooks_url":"https://api.github.com/repos/Oslandia/qgis-versioning/hooks","issue_events_url":"https://api.github.com/repos/Oslandia/qgis-versioning/issues/events{/number}","events_url":"https://api.github.com/repos/Oslandia/qgis-versioning/events","assignees_url":"https://api.github.com/repos/Oslandia/qgis-versioning/assignees{/user}","branches_url":"https://api.github.com/repos/Oslandia/qgis-versioning/branches{/branch}","tags_url":"https://api.github.com/repos/Oslandia/qgis-versioning/tags","blobs_url":"https://api.github.com/repos/Oslandia/qgis-versioning/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Oslandia/qgis-versioning/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Oslandia/qgis-versioning/git/refs{/sha}","trees_url":"https://api.github.com/repos/Oslandia/qgis-versioning/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Oslandia/qgis-versioning/statuses/{sha}","languages_url":"https://api.github.com/repos/Oslandia/qgis-versioning/languages","stargazers_url":"https://api.github.com/repos/Oslandia/qgis-versioning/stargazers","contributors_url":"https://api.github.com/repos/Oslandia/qgis-versioning/contributors","subscribers_url":"https://api.github.com/repos/Oslandia/qgis-versioning/subscribers","subscription_url":"https://api.github.com/repos/Oslandia/qgis-versioning/subscription","commits_url":"https://api.github.com/repos/Oslandia/qgis-versioning/commits{/sha}","git_commits_url":"https://api.github.com/repos/Oslandia/qgis-versioning/git/commits{/sha}","comments_url":"https://api.github.com/repos/Oslandia/qgis-versioning/comments{/number}","issue_comment_url":"https://api.github.com/repos/Oslandia/qgis-versioning/issues/comments{/number}","contents_url":"https://api.github.com/repos/Oslandia/qgis-versioning/contents/{+path}","compare_url":"https://api.github.com/repos/Oslandia/qgis-versioning/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Oslandia/qgis-versioning/merges","archive_url":"https://api.github.com/repos/Oslandia/qgis-versioning/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Oslandia/qgis-versioning/downloads","issues_url":"https://api.github.com/repos/Oslandia/qgis-versioning/issues{/number}","pulls_url":"https://api.github.com/repos/Oslandia/qgis-versioning/pulls{/number}","milestones_url":"https://api.github.com/repos/Oslandia/qgis-versioning/milestones{/number}","notifications_url":"https://api.github.com/repos/Oslandia/qgis-versioning/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Oslandia/qgis-versioning/labels{/name}","releases_url":"https://api.github.com/repos/Oslandia/qgis-versioning/releases{/id}","created_at":"2014-03-28T12:47:59Z","updated_at":"2015-08-14T01:55:21Z","pushed_at":"2015-12-07T09:45:49Z","git_url":"git://github.com/Oslandia/qgis-versioning.git","ssh_url":"git@github.com:Oslandia/qgis-versioning.git","clone_url":"https://github.com/Oslandia/qgis-versioning.git","svn_url":"https://github.com/Oslandia/qgis-versioning","homepage":null,"size":680,"stargazers_count":12,"watchers_count":12,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":9,"mirror_url":null,"open_issues_count":15,"forks":9,"open_issues":15,"watchers":12,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Oslandia/qgis-versioning/pulls/28"},"html":{"href":"https://github.com/Oslandia/qgis-versioning/pull/28"},"issue":{"href":"https://api.github.com/repos/Oslandia/qgis-versioning/issues/28"},"comments":{"href":"https://api.github.com/repos/Oslandia/qgis-versioning/issues/28/comments"},"review_comments":{"href":"https://api.github.com/repos/Oslandia/qgis-versioning/pulls/28/comments"},"review_comment":{"href":"https://api.github.com/repos/Oslandia/qgis-versioning/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Oslandia/qgis-versioning/pulls/28/commits"},"statuses":{"href":"https://api.github.com/repos/Oslandia/qgis-versioning/statuses/a47855b104da6f33a9ab5eabe2a55723ce57f7ef"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"vmora","id":4415710,"avatar_url":"https://avatars.githubusercontent.com/u/4415710?v=3","gravatar_id":"","url":"https://api.github.com/users/vmora","html_url":"https://github.com/vmora","followers_url":"https://api.github.com/users/vmora/followers","following_url":"https://api.github.com/users/vmora/following{/other_user}","gists_url":"https://api.github.com/users/vmora/gists{/gist_id}","starred_url":"https://api.github.com/users/vmora/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vmora/subscriptions","organizations_url":"https://api.github.com/users/vmora/orgs","repos_url":"https://api.github.com/users/vmora/repos","events_url":"https://api.github.com/users/vmora/events{/privacy}","received_events_url":"https://api.github.com/users/vmora/received_events","type":"User","site_admin":false},"comments":1,"review_comments":0,"commits":2,"additions":63,"deletions":29,"changed_files":1}}