{"action":"created","comment":{"url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/comments/350115306","pull_request_review_id":322193995,"id":350115306,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDM1MDExNTMwNg==","diff_hunk":"@@ -0,0 +1,302 @@\n+import json\n+\n+from django.contrib.postgres import lookups\n+from django.contrib.postgres.forms import SimpleArrayField\n+from django.contrib.postgres.validators import ArrayMaxLengthValidator\n+from django.core import checks, exceptions\n+from django.db.models import Field, IntegerField, Transform\n+from django.db.models.lookups import Exact, In\n+from django.utils.inspect import func_supports_parameter\n+from django.utils.translation import gettext_lazy as _\n+\n+from ..utils import prefix_validation_error\n+from .utils import AttributeSetter\n+\n+__all__ = ['ArrayField']\n+\n+\n+class ArrayField(Field):\n+    empty_strings_allowed = False\n+    default_error_messages = {\n+        'item_invalid': _('Item %(nth)s in the array did not validate: '),\n+        'nested_array_mismatch': _('Nested arrays must have the same length.'),\n+    }\n+\n+    def __init__(self, base_field, size=None, **kwargs):\n+        self.base_field = base_field\n+        self.size = size\n+        if self.size:\n+            self.default_validators = self.default_validators[:]\n+            self.default_validators.append(ArrayMaxLengthValidator(self.size))\n+        # For performance, only add a from_db_value() method if the base field\n+        # implements it.\n+        if hasattr(self.base_field, 'from_db_value'):\n+            self.from_db_value = self._from_db_value\n+        super().__init__(**kwargs)\n+\n+    @property\n+    def model(self):\n+        try:\n+            return self.__dict__['model']\n+        except KeyError:\n+            raise AttributeError(\"'%s' object has no attribute 'model'\" % self.__class__.__name__)\n+\n+    @model.setter\n+    def model(self, model):\n+        self.__dict__['model'] = model\n+        self.base_field.model = model\n+\n+    def check(self, **kwargs):\n+        errors = super().check(**kwargs)\n+        if self.base_field.remote_field:\n+            errors.append(\n+                checks.Error(\n+                    'Base field for array cannot be a related field.',\n+                    obj=self,\n+                    id='postgres.E002'\n+                )\n+            )\n+        else:\n+            # Remove the field name checks as they are not needed here.\n+            base_errors = self.base_field.check()\n+            if base_errors:\n+                messages = '\\n    '.join('%s (%s)' % (error.msg, error.id) for error in base_errors)\n+                errors.append(\n+                    checks.Error(\n+                        'Base field for array has errors:\\n    %s' % messages,\n+                        obj=self,\n+                        id='postgres.E001'\n+                    )\n+                )\n+        return errors\n+\n+    def set_attributes_from_name(self, name):\n+        super().set_attributes_from_name(name)\n+        self.base_field.set_attributes_from_name(name)\n+\n+    @property\n+    def description(self):\n+        return 'Array of %s' % self.base_field.description\n+\n+    def db_type(self, connection):\n+        size = self.size or ''\n+        return '%s[%s]' % (self.base_field.db_type(connection), size)\n+\n+    def get_db_prep_value(self, value, connection, prepared=False):\n+        if isinstance(value, (list, tuple)):\n+            return [self.base_field.get_db_prep_value(i, connection, prepared=False) for i in value]\n+        return value\n+\n+    def deconstruct(self):\n+        name, path, args, kwargs = super().deconstruct()\n+        if path == 'django.contrib.postgres.fields.array.ArrayField':\n+            path = 'django.contrib.postgres.fields.ArrayField'\n+        kwargs.update({\n+            'base_field': self.base_field.clone(),\n+            'size': self.size,\n+        })\n+        return name, path, args, kwargs\n+\n+    def to_python(self, value):\n+        if isinstance(value, str):\n+            # Assume we're deserializing\n+            vals = json.loads(value)\n+            value = [self.base_field.to_python(val) for val in vals]\n+        return value\n+\n+    def _from_db_value(self, value, expression, connection):\n+        if value is None:\n+            return value\n+        return [\n+            self.base_field.from_db_value(item, expression, connection, {})\n+            if func_supports_parameter(self.base_field.from_db_value, 'context')  # RemovedInDjango30Warning","path":"env/lib/python3.7/site-packages/django/contrib/postgres/fields/array.py","position":112,"original_position":112,"commit_id":"7494bca3d2a0d89b3c2c0ed12203e7be4191a145","original_commit_id":"7494bca3d2a0d89b3c2c0ed12203e7be4191a145","user":{"login":"houndci-bot","id":6697940,"node_id":"MDQ6VXNlcjY2OTc5NDA=","avatar_url":"https://avatars0.githubusercontent.com/u/6697940?v=4","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"line too long (108 > 79 characters)","created_at":"2019-11-25T10:59:32Z","updated_at":"2019-11-25T10:59:36Z","html_url":"https://github.com/JamesKirkAndSpock/Hirola/pull/135#discussion_r350115306","pull_request_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/135","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/comments/350115306"},"html":{"href":"https://github.com/JamesKirkAndSpock/Hirola/pull/135#discussion_r350115306"},"pull_request":{"href":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/135"}}},"pull_request":{"url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/135","id":344956319,"node_id":"MDExOlB1bGxSZXF1ZXN0MzQ0OTU2MzE5","html_url":"https://github.com/JamesKirkAndSpock/Hirola/pull/135","diff_url":"https://github.com/JamesKirkAndSpock/Hirola/pull/135.diff","patch_url":"https://github.com/JamesKirkAndSpock/Hirola/pull/135.patch","issue_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/issues/135","number":135,"state":"open","locked":false,"title":"Local","user":{"login":"dragz92","id":41836695,"node_id":"MDQ6VXNlcjQxODM2Njk1","avatar_url":"https://avatars3.githubusercontent.com/u/41836695?v=4","gravatar_id":"","url":"https://api.github.com/users/dragz92","html_url":"https://github.com/dragz92","followers_url":"https://api.github.com/users/dragz92/followers","following_url":"https://api.github.com/users/dragz92/following{/other_user}","gists_url":"https://api.github.com/users/dragz92/gists{/gist_id}","starred_url":"https://api.github.com/users/dragz92/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dragz92/subscriptions","organizations_url":"https://api.github.com/users/dragz92/orgs","repos_url":"https://api.github.com/users/dragz92/repos","events_url":"https://api.github.com/users/dragz92/events{/privacy}","received_events_url":"https://api.github.com/users/dragz92/received_events","type":"User","site_admin":false},"body":"Content changes (HTML) and updates\r\n\r\n\r\n#### Changes proposed in this pull request:\r\n\r\n-\r\n-\r\n-\r\n#### Screenshots:\r\n\r\n**Fixes**: #\r\n\r\n","created_at":"2019-11-24T22:27:12Z","updated_at":"2019-11-25T10:59:36Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0797e859045d0d7654901422ff7f5211d4215bd3","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/135/commits","review_comments_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/135/comments","review_comment_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/comments{/number}","comments_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/issues/135/comments","statuses_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/statuses/7494bca3d2a0d89b3c2c0ed12203e7be4191a145","head":{"label":"JamesKirkAndSpock:local","ref":"local","sha":"7494bca3d2a0d89b3c2c0ed12203e7be4191a145","user":{"login":"JamesKirkAndSpock","id":33254685,"node_id":"MDQ6VXNlcjMzMjU0Njg1","avatar_url":"https://avatars2.githubusercontent.com/u/33254685?v=4","gravatar_id":"","url":"https://api.github.com/users/JamesKirkAndSpock","html_url":"https://github.com/JamesKirkAndSpock","followers_url":"https://api.github.com/users/JamesKirkAndSpock/followers","following_url":"https://api.github.com/users/JamesKirkAndSpock/following{/other_user}","gists_url":"https://api.github.com/users/JamesKirkAndSpock/gists{/gist_id}","starred_url":"https://api.github.com/users/JamesKirkAndSpock/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JamesKirkAndSpock/subscriptions","organizations_url":"https://api.github.com/users/JamesKirkAndSpock/orgs","repos_url":"https://api.github.com/users/JamesKirkAndSpock/repos","events_url":"https://api.github.com/users/JamesKirkAndSpock/events{/privacy}","received_events_url":"https://api.github.com/users/JamesKirkAndSpock/received_events","type":"User","site_admin":false},"repo":{"id":125551636,"node_id":"MDEwOlJlcG9zaXRvcnkxMjU1NTE2MzY=","name":"Hirola","full_name":"JamesKirkAndSpock/Hirola","private":false,"owner":{"login":"JamesKirkAndSpock","id":33254685,"node_id":"MDQ6VXNlcjMzMjU0Njg1","avatar_url":"https://avatars2.githubusercontent.com/u/33254685?v=4","gravatar_id":"","url":"https://api.github.com/users/JamesKirkAndSpock","html_url":"https://github.com/JamesKirkAndSpock","followers_url":"https://api.github.com/users/JamesKirkAndSpock/followers","following_url":"https://api.github.com/users/JamesKirkAndSpock/following{/other_user}","gists_url":"https://api.github.com/users/JamesKirkAndSpock/gists{/gist_id}","starred_url":"https://api.github.com/users/JamesKirkAndSpock/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JamesKirkAndSpock/subscriptions","organizations_url":"https://api.github.com/users/JamesKirkAndSpock/orgs","repos_url":"https://api.github.com/users/JamesKirkAndSpock/repos","events_url":"https://api.github.com/users/JamesKirkAndSpock/events{/privacy}","received_events_url":"https://api.github.com/users/JamesKirkAndSpock/received_events","type":"User","site_admin":false},"html_url":"https://github.com/JamesKirkAndSpock/Hirola","description":null,"fork":false,"url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola","forks_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/forks","keys_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/keys{/key_id}","collaborators_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/teams","hooks_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/hooks","issue_events_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/issues/events{/number}","events_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/events","assignees_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/assignees{/user}","branches_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/branches{/branch}","tags_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/tags","blobs_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/git/refs{/sha}","trees_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/git/trees{/sha}","statuses_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/statuses/{sha}","languages_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/languages","stargazers_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/stargazers","contributors_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/contributors","subscribers_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/subscribers","subscription_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/subscription","commits_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/commits{/sha}","git_commits_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/git/commits{/sha}","comments_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/comments{/number}","issue_comment_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/issues/comments{/number}","contents_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/contents/{+path}","compare_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/compare/{base}...{head}","merges_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/merges","archive_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/downloads","issues_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/issues{/number}","pulls_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls{/number}","milestones_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/milestones{/number}","notifications_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/labels{/name}","releases_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/releases{/id}","deployments_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/deployments","created_at":"2018-03-16T17:55:24Z","updated_at":"2019-08-01T08:11:50Z","pushed_at":"2019-11-25T10:56:18Z","git_url":"git://github.com/JamesKirkAndSpock/Hirola.git","ssh_url":"git@github.com:JamesKirkAndSpock/Hirola.git","clone_url":"https://github.com/JamesKirkAndSpock/Hirola.git","svn_url":"https://github.com/JamesKirkAndSpock/Hirola","homepage":null,"size":26558,"stargazers_count":1,"watchers_count":1,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":5,"license":null,"forks":0,"open_issues":5,"watchers":1,"default_branch":"develop"}},"base":{"label":"JamesKirkAndSpock:develop","ref":"develop","sha":"21d48c53695cd15137011f3ca474520faeb28c8f","user":{"login":"JamesKirkAndSpock","id":33254685,"node_id":"MDQ6VXNlcjMzMjU0Njg1","avatar_url":"https://avatars2.githubusercontent.com/u/33254685?v=4","gravatar_id":"","url":"https://api.github.com/users/JamesKirkAndSpock","html_url":"https://github.com/JamesKirkAndSpock","followers_url":"https://api.github.com/users/JamesKirkAndSpock/followers","following_url":"https://api.github.com/users/JamesKirkAndSpock/following{/other_user}","gists_url":"https://api.github.com/users/JamesKirkAndSpock/gists{/gist_id}","starred_url":"https://api.github.com/users/JamesKirkAndSpock/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JamesKirkAndSpock/subscriptions","organizations_url":"https://api.github.com/users/JamesKirkAndSpock/orgs","repos_url":"https://api.github.com/users/JamesKirkAndSpock/repos","events_url":"https://api.github.com/users/JamesKirkAndSpock/events{/privacy}","received_events_url":"https://api.github.com/users/JamesKirkAndSpock/received_events","type":"User","site_admin":false},"repo":{"id":125551636,"node_id":"MDEwOlJlcG9zaXRvcnkxMjU1NTE2MzY=","name":"Hirola","full_name":"JamesKirkAndSpock/Hirola","private":false,"owner":{"login":"JamesKirkAndSpock","id":33254685,"node_id":"MDQ6VXNlcjMzMjU0Njg1","avatar_url":"https://avatars2.githubusercontent.com/u/33254685?v=4","gravatar_id":"","url":"https://api.github.com/users/JamesKirkAndSpock","html_url":"https://github.com/JamesKirkAndSpock","followers_url":"https://api.github.com/users/JamesKirkAndSpock/followers","following_url":"https://api.github.com/users/JamesKirkAndSpock/following{/other_user}","gists_url":"https://api.github.com/users/JamesKirkAndSpock/gists{/gist_id}","starred_url":"https://api.github.com/users/JamesKirkAndSpock/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JamesKirkAndSpock/subscriptions","organizations_url":"https://api.github.com/users/JamesKirkAndSpock/orgs","repos_url":"https://api.github.com/users/JamesKirkAndSpock/repos","events_url":"https://api.github.com/users/JamesKirkAndSpock/events{/privacy}","received_events_url":"https://api.github.com/users/JamesKirkAndSpock/received_events","type":"User","site_admin":false},"html_url":"https://github.com/JamesKirkAndSpock/Hirola","description":null,"fork":false,"url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola","forks_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/forks","keys_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/keys{/key_id}","collaborators_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/teams","hooks_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/hooks","issue_events_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/issues/events{/number}","events_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/events","assignees_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/assignees{/user}","branches_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/branches{/branch}","tags_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/tags","blobs_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/git/refs{/sha}","trees_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/git/trees{/sha}","statuses_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/statuses/{sha}","languages_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/languages","stargazers_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/stargazers","contributors_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/contributors","subscribers_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/subscribers","subscription_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/subscription","commits_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/commits{/sha}","git_commits_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/git/commits{/sha}","comments_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/comments{/number}","issue_comment_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/issues/comments{/number}","contents_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/contents/{+path}","compare_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/compare/{base}...{head}","merges_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/merges","archive_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/downloads","issues_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/issues{/number}","pulls_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls{/number}","milestones_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/milestones{/number}","notifications_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/labels{/name}","releases_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/releases{/id}","deployments_url":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/deployments","created_at":"2018-03-16T17:55:24Z","updated_at":"2019-08-01T08:11:50Z","pushed_at":"2019-11-25T10:56:18Z","git_url":"git://github.com/JamesKirkAndSpock/Hirola.git","ssh_url":"git@github.com:JamesKirkAndSpock/Hirola.git","clone_url":"https://github.com/JamesKirkAndSpock/Hirola.git","svn_url":"https://github.com/JamesKirkAndSpock/Hirola","homepage":null,"size":26558,"stargazers_count":1,"watchers_count":1,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":5,"license":null,"forks":0,"open_issues":5,"watchers":1,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/135"},"html":{"href":"https://github.com/JamesKirkAndSpock/Hirola/pull/135"},"issue":{"href":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/issues/135"},"comments":{"href":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/issues/135/comments"},"review_comments":{"href":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/135/comments"},"review_comment":{"href":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/pulls/135/commits"},"statuses":{"href":"https://api.github.com/repos/JamesKirkAndSpock/Hirola/statuses/7494bca3d2a0d89b3c2c0ed12203e7be4191a145"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"houndci-bot"}}