{"action":"created","comment":{"url":"https://api.github.com/repos/jezdez/django-configurations/pulls/comments/23536311","id":23536311,"diff_hunk":"@@ -67,14 +54,48 @@ def name(self):\n         return os.environ.get(self.namevar)\n \n     def check_options(self):\n-        parser = LaxOptionParser(option_list=configuration_options,\n-                                 add_help_option=False)\n-        try:\n-            options, args = parser.parse_args(self.argv)\n-            if options.configuration:\n-                os.environ[self.namevar] = options.configuration\n-        except:\n-            pass  # Ignore any option errors at this point.\n+        # django switched to argparse in version 1.8\n+        if DJ_VERSION >= (1, 8):\n+            from django.core.management.base import (CommandError,\n+                                                     CommandParser,\n+                                                     handle_default_options)\n+            parser = CommandParser(None,\n+                                   usage=\"%(prog)s subcommand [options] [args]\",\n+                                   add_help=False)\n+            parser.add_argument('--settings')\n+            parser.add_argument('--pythonpath')\n+            parser.add_argument('--configuration',","path":"configurations/importer.py","position":60,"original_position":60,"commit_id":"d9b2815526f72fc6fff6a6c4114ae61f6759f854","original_commit_id":"d9b2815526f72fc6fff6a6c4114ae61f6759f854","user":{"login":"jezdez","id":1610,"avatar_url":"https://avatars.githubusercontent.com/u/1610?v=3","gravatar_id":"","url":"https://api.github.com/users/jezdez","html_url":"https://github.com/jezdez","followers_url":"https://api.github.com/users/jezdez/followers","following_url":"https://api.github.com/users/jezdez/following{/other_user}","gists_url":"https://api.github.com/users/jezdez/gists{/gist_id}","starred_url":"https://api.github.com/users/jezdez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jezdez/subscriptions","organizations_url":"https://api.github.com/users/jezdez/orgs","repos_url":"https://api.github.com/users/jezdez/repos","events_url":"https://api.github.com/users/jezdez/events{/privacy}","received_events_url":"https://api.github.com/users/jezdez/received_events","type":"User","site_admin":false},"body":"Could you define hat help text in a central variable instead of repeating it?","created_at":"2015-01-26T15:13:48Z","updated_at":"2015-01-26T15:13:48Z","html_url":"https://github.com/jezdez/django-configurations/pull/90#discussion_r23536311","pull_request_url":"https://api.github.com/repos/jezdez/django-configurations/pulls/90","_links":{"self":{"href":"https://api.github.com/repos/jezdez/django-configurations/pulls/comments/23536311"},"html":{"href":"https://github.com/jezdez/django-configurations/pull/90#discussion_r23536311"},"pull_request":{"href":"https://api.github.com/repos/jezdez/django-configurations/pulls/90"}}},"pull_request":{"url":"https://api.github.com/repos/jezdez/django-configurations/pulls/90","id":27911716,"html_url":"https://github.com/jezdez/django-configurations/pull/90","diff_url":"https://github.com/jezdez/django-configurations/pull/90.diff","patch_url":"https://github.com/jezdez/django-configurations/pull/90.patch","issue_url":"https://api.github.com/repos/jezdez/django-configurations/issues/90","number":90,"state":"open","locked":false,"title":"Use CommandParser instead of LaxOptionParser in django1.8 ","user":{"login":"benjaminabel","id":1004282,"avatar_url":"https://avatars.githubusercontent.com/u/1004282?v=3","gravatar_id":"","url":"https://api.github.com/users/benjaminabel","html_url":"https://github.com/benjaminabel","followers_url":"https://api.github.com/users/benjaminabel/followers","following_url":"https://api.github.com/users/benjaminabel/following{/other_user}","gists_url":"https://api.github.com/users/benjaminabel/gists{/gist_id}","starred_url":"https://api.github.com/users/benjaminabel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benjaminabel/subscriptions","organizations_url":"https://api.github.com/users/benjaminabel/orgs","repos_url":"https://api.github.com/users/benjaminabel/repos","events_url":"https://api.github.com/users/benjaminabel/events{/privacy}","received_events_url":"https://api.github.com/users/benjaminabel/received_events","type":"User","site_admin":false},"body":"@jezdez I added a django version check to use `CommandParser` instead of `LaxOptionParser` if django>=1.8. I've tested it locally, this commit closes #65. django-configurations and pytest-django tests succeed.","created_at":"2015-01-23T09:48:38Z","updated_at":"2015-01-26T15:13:48Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3d8c44ce45b666daa7a811c4a6f828c133a996e8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/jezdez/django-configurations/pulls/90/commits","review_comments_url":"https://api.github.com/repos/jezdez/django-configurations/pulls/90/comments","review_comment_url":"https://api.github.com/repos/jezdez/django-configurations/pulls/comments/{number}","comments_url":"https://api.github.com/repos/jezdez/django-configurations/issues/90/comments","statuses_url":"https://api.github.com/repos/jezdez/django-configurations/statuses/d9b2815526f72fc6fff6a6c4114ae61f6759f854","head":{"label":"benjaminabel:master","ref":"master","sha":"d9b2815526f72fc6fff6a6c4114ae61f6759f854","user":{"login":"benjaminabel","id":1004282,"avatar_url":"https://avatars.githubusercontent.com/u/1004282?v=3","gravatar_id":"","url":"https://api.github.com/users/benjaminabel","html_url":"https://github.com/benjaminabel","followers_url":"https://api.github.com/users/benjaminabel/followers","following_url":"https://api.github.com/users/benjaminabel/following{/other_user}","gists_url":"https://api.github.com/users/benjaminabel/gists{/gist_id}","starred_url":"https://api.github.com/users/benjaminabel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benjaminabel/subscriptions","organizations_url":"https://api.github.com/users/benjaminabel/orgs","repos_url":"https://api.github.com/users/benjaminabel/repos","events_url":"https://api.github.com/users/benjaminabel/events{/privacy}","received_events_url":"https://api.github.com/users/benjaminabel/received_events","type":"User","site_admin":false},"repo":{"id":28917881,"name":"django-configurations","full_name":"benjaminabel/django-configurations","owner":{"login":"benjaminabel","id":1004282,"avatar_url":"https://avatars.githubusercontent.com/u/1004282?v=3","gravatar_id":"","url":"https://api.github.com/users/benjaminabel","html_url":"https://github.com/benjaminabel","followers_url":"https://api.github.com/users/benjaminabel/followers","following_url":"https://api.github.com/users/benjaminabel/following{/other_user}","gists_url":"https://api.github.com/users/benjaminabel/gists{/gist_id}","starred_url":"https://api.github.com/users/benjaminabel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benjaminabel/subscriptions","organizations_url":"https://api.github.com/users/benjaminabel/orgs","repos_url":"https://api.github.com/users/benjaminabel/repos","events_url":"https://api.github.com/users/benjaminabel/events{/privacy}","received_events_url":"https://api.github.com/users/benjaminabel/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/benjaminabel/django-configurations","description":"A helper for organizing Django project settings by relying on well established programming patterns.","fork":true,"url":"https://api.github.com/repos/benjaminabel/django-configurations","forks_url":"https://api.github.com/repos/benjaminabel/django-configurations/forks","keys_url":"https://api.github.com/repos/benjaminabel/django-configurations/keys{/key_id}","collaborators_url":"https://api.github.com/repos/benjaminabel/django-configurations/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/benjaminabel/django-configurations/teams","hooks_url":"https://api.github.com/repos/benjaminabel/django-configurations/hooks","issue_events_url":"https://api.github.com/repos/benjaminabel/django-configurations/issues/events{/number}","events_url":"https://api.github.com/repos/benjaminabel/django-configurations/events","assignees_url":"https://api.github.com/repos/benjaminabel/django-configurations/assignees{/user}","branches_url":"https://api.github.com/repos/benjaminabel/django-configurations/branches{/branch}","tags_url":"https://api.github.com/repos/benjaminabel/django-configurations/tags","blobs_url":"https://api.github.com/repos/benjaminabel/django-configurations/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/benjaminabel/django-configurations/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/benjaminabel/django-configurations/git/refs{/sha}","trees_url":"https://api.github.com/repos/benjaminabel/django-configurations/git/trees{/sha}","statuses_url":"https://api.github.com/repos/benjaminabel/django-configurations/statuses/{sha}","languages_url":"https://api.github.com/repos/benjaminabel/django-configurations/languages","stargazers_url":"https://api.github.com/repos/benjaminabel/django-configurations/stargazers","contributors_url":"https://api.github.com/repos/benjaminabel/django-configurations/contributors","subscribers_url":"https://api.github.com/repos/benjaminabel/django-configurations/subscribers","subscription_url":"https://api.github.com/repos/benjaminabel/django-configurations/subscription","commits_url":"https://api.github.com/repos/benjaminabel/django-configurations/commits{/sha}","git_commits_url":"https://api.github.com/repos/benjaminabel/django-configurations/git/commits{/sha}","comments_url":"https://api.github.com/repos/benjaminabel/django-configurations/comments{/number}","issue_comment_url":"https://api.github.com/repos/benjaminabel/django-configurations/issues/comments/{number}","contents_url":"https://api.github.com/repos/benjaminabel/django-configurations/contents/{+path}","compare_url":"https://api.github.com/repos/benjaminabel/django-configurations/compare/{base}...{head}","merges_url":"https://api.github.com/repos/benjaminabel/django-configurations/merges","archive_url":"https://api.github.com/repos/benjaminabel/django-configurations/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/benjaminabel/django-configurations/downloads","issues_url":"https://api.github.com/repos/benjaminabel/django-configurations/issues{/number}","pulls_url":"https://api.github.com/repos/benjaminabel/django-configurations/pulls{/number}","milestones_url":"https://api.github.com/repos/benjaminabel/django-configurations/milestones{/number}","notifications_url":"https://api.github.com/repos/benjaminabel/django-configurations/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/benjaminabel/django-configurations/labels{/name}","releases_url":"https://api.github.com/repos/benjaminabel/django-configurations/releases{/id}","created_at":"2015-01-07T14:28:22Z","updated_at":"2015-01-25T17:32:25Z","pushed_at":"2015-01-25T17:32:24Z","git_url":"git://github.com/benjaminabel/django-configurations.git","ssh_url":"git@github.com:benjaminabel/django-configurations.git","clone_url":"https://github.com/benjaminabel/django-configurations.git","svn_url":"https://github.com/benjaminabel/django-configurations","homepage":"http://django-configurations.readthedocs.org/","size":361,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"jezdez:master","ref":"master","sha":"f53e99904100a6b9f0411e461b4f320acd636299","user":{"login":"jezdez","id":1610,"avatar_url":"https://avatars.githubusercontent.com/u/1610?v=3","gravatar_id":"","url":"https://api.github.com/users/jezdez","html_url":"https://github.com/jezdez","followers_url":"https://api.github.com/users/jezdez/followers","following_url":"https://api.github.com/users/jezdez/following{/other_user}","gists_url":"https://api.github.com/users/jezdez/gists{/gist_id}","starred_url":"https://api.github.com/users/jezdez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jezdez/subscriptions","organizations_url":"https://api.github.com/users/jezdez/orgs","repos_url":"https://api.github.com/users/jezdez/repos","events_url":"https://api.github.com/users/jezdez/events{/privacy}","received_events_url":"https://api.github.com/users/jezdez/received_events","type":"User","site_admin":false},"repo":{"id":5133993,"name":"django-configurations","full_name":"jezdez/django-configurations","owner":{"login":"jezdez","id":1610,"avatar_url":"https://avatars.githubusercontent.com/u/1610?v=3","gravatar_id":"","url":"https://api.github.com/users/jezdez","html_url":"https://github.com/jezdez","followers_url":"https://api.github.com/users/jezdez/followers","following_url":"https://api.github.com/users/jezdez/following{/other_user}","gists_url":"https://api.github.com/users/jezdez/gists{/gist_id}","starred_url":"https://api.github.com/users/jezdez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jezdez/subscriptions","organizations_url":"https://api.github.com/users/jezdez/orgs","repos_url":"https://api.github.com/users/jezdez/repos","events_url":"https://api.github.com/users/jezdez/events{/privacy}","received_events_url":"https://api.github.com/users/jezdez/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jezdez/django-configurations","description":"A helper for organizing Django project settings by relying on well established programming patterns.","fork":false,"url":"https://api.github.com/repos/jezdez/django-configurations","forks_url":"https://api.github.com/repos/jezdez/django-configurations/forks","keys_url":"https://api.github.com/repos/jezdez/django-configurations/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jezdez/django-configurations/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jezdez/django-configurations/teams","hooks_url":"https://api.github.com/repos/jezdez/django-configurations/hooks","issue_events_url":"https://api.github.com/repos/jezdez/django-configurations/issues/events{/number}","events_url":"https://api.github.com/repos/jezdez/django-configurations/events","assignees_url":"https://api.github.com/repos/jezdez/django-configurations/assignees{/user}","branches_url":"https://api.github.com/repos/jezdez/django-configurations/branches{/branch}","tags_url":"https://api.github.com/repos/jezdez/django-configurations/tags","blobs_url":"https://api.github.com/repos/jezdez/django-configurations/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jezdez/django-configurations/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jezdez/django-configurations/git/refs{/sha}","trees_url":"https://api.github.com/repos/jezdez/django-configurations/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jezdez/django-configurations/statuses/{sha}","languages_url":"https://api.github.com/repos/jezdez/django-configurations/languages","stargazers_url":"https://api.github.com/repos/jezdez/django-configurations/stargazers","contributors_url":"https://api.github.com/repos/jezdez/django-configurations/contributors","subscribers_url":"https://api.github.com/repos/jezdez/django-configurations/subscribers","subscription_url":"https://api.github.com/repos/jezdez/django-configurations/subscription","commits_url":"https://api.github.com/repos/jezdez/django-configurations/commits{/sha}","git_commits_url":"https://api.github.com/repos/jezdez/django-configurations/git/commits{/sha}","comments_url":"https://api.github.com/repos/jezdez/django-configurations/comments{/number}","issue_comment_url":"https://api.github.com/repos/jezdez/django-configurations/issues/comments/{number}","contents_url":"https://api.github.com/repos/jezdez/django-configurations/contents/{+path}","compare_url":"https://api.github.com/repos/jezdez/django-configurations/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jezdez/django-configurations/merges","archive_url":"https://api.github.com/repos/jezdez/django-configurations/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jezdez/django-configurations/downloads","issues_url":"https://api.github.com/repos/jezdez/django-configurations/issues{/number}","pulls_url":"https://api.github.com/repos/jezdez/django-configurations/pulls{/number}","milestones_url":"https://api.github.com/repos/jezdez/django-configurations/milestones{/number}","notifications_url":"https://api.github.com/repos/jezdez/django-configurations/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jezdez/django-configurations/labels{/name}","releases_url":"https://api.github.com/repos/jezdez/django-configurations/releases{/id}","created_at":"2012-07-21T13:56:20Z","updated_at":"2015-01-26T03:09:50Z","pushed_at":"2015-01-15T12:06:19Z","git_url":"git://github.com/jezdez/django-configurations.git","ssh_url":"git@github.com:jezdez/django-configurations.git","clone_url":"https://github.com/jezdez/django-configurations.git","svn_url":"https://github.com/jezdez/django-configurations","homepage":"http://django-configurations.readthedocs.org/","size":1009,"stargazers_count":310,"watchers_count":310,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":38,"mirror_url":null,"open_issues_count":5,"forks":38,"open_issues":5,"watchers":310,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jezdez/django-configurations/pulls/90"},"html":{"href":"https://github.com/jezdez/django-configurations/pull/90"},"issue":{"href":"https://api.github.com/repos/jezdez/django-configurations/issues/90"},"comments":{"href":"https://api.github.com/repos/jezdez/django-configurations/issues/90/comments"},"review_comments":{"href":"https://api.github.com/repos/jezdez/django-configurations/pulls/90/comments"},"review_comment":{"href":"https://api.github.com/repos/jezdez/django-configurations/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/jezdez/django-configurations/pulls/90/commits"},"statuses":{"href":"https://api.github.com/repos/jezdez/django-configurations/statuses/d9b2815526f72fc6fff6a6c4114ae61f6759f854"}}}}