{"action":"created","comment":{"url":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/comments/31384193","id":31384193,"diff_hunk":"@@ -385,7 +375,150 @@ def reloadModule(self, moduleName):\n \t\telse:\n \t\t\tdeferList.addCallback(lambda result: self.loadModule(moduleName))\n \t\treturn deferList\n-\t\n+\n+\tdef verifyConfig(self, config):\n+\t\t# Verify the configuration values that are used in the core first.\n+\n+\t\t# IRCd\n+\t\tif \"server_name\" not in config:\n+\t\t\traise ConfigValidationError(\"server_name\", \"required item not found in configuration file.\")\n+\t\tif not isinstance(config[\"server_name\"], basestring):\n+\t\t\traise ConfigValidationError(\"server_name\", \"value must be a string\")\n+\t\tif len(config[\"server_name\"]) > 64:\n+\t\t\tconfig[\"server_name\"] = config[\"server_name\"][:64]\n+\t\t\tself.logConfigValidationWarning(\"server_name\", \"value is too long\", config[\"server_name\"])","path":"txircd/ircd.py","position":94,"original_position":94,"commit_id":"8dbbfac1e626cc341ee3cf86c56cec902042b6cf","original_commit_id":"8dbbfac1e626cc341ee3cf86c56cec902042b6cf","user":{"login":"ElementalAlchemist","id":115662,"avatar_url":"https://avatars.githubusercontent.com/u/115662?v=3","gravatar_id":"","url":"https://api.github.com/users/ElementalAlchemist","html_url":"https://github.com/ElementalAlchemist","followers_url":"https://api.github.com/users/ElementalAlchemist/followers","following_url":"https://api.github.com/users/ElementalAlchemist/following{/other_user}","gists_url":"https://api.github.com/users/ElementalAlchemist/gists{/gist_id}","starred_url":"https://api.github.com/users/ElementalAlchemist/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ElementalAlchemist/subscriptions","organizations_url":"https://api.github.com/users/ElementalAlchemist/orgs","repos_url":"https://api.github.com/users/ElementalAlchemist/repos","events_url":"https://api.github.com/users/ElementalAlchemist/events{/privacy}","received_events_url":"https://api.github.com/users/ElementalAlchemist/received_events","type":"User","site_admin":false},"body":"Can we add to the warning that the server name was truncated?","created_at":"2015-05-30T20:26:21Z","updated_at":"2015-05-30T20:26:21Z","html_url":"https://github.com/ElementalAlchemist/txircd/pull/116#discussion_r31384193","pull_request_url":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/116","_links":{"self":{"href":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/comments/31384193"},"html":{"href":"https://github.com/ElementalAlchemist/txircd/pull/116#discussion_r31384193"},"pull_request":{"href":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/116"}}},"pull_request":{"url":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/116","id":35543333,"html_url":"https://github.com/ElementalAlchemist/txircd/pull/116","diff_url":"https://github.com/ElementalAlchemist/txircd/pull/116.diff","patch_url":"https://github.com/ElementalAlchemist/txircd/pull/116.patch","issue_url":"https://api.github.com/repos/ElementalAlchemist/txircd/issues/116","number":116,"state":"open","locked":false,"title":"Limit changes and config validation","user":{"login":"Heufneutje","id":1357231,"avatar_url":"https://avatars.githubusercontent.com/u/1357231?v=3","gravatar_id":"","url":"https://api.github.com/users/Heufneutje","html_url":"https://github.com/Heufneutje","followers_url":"https://api.github.com/users/Heufneutje/followers","following_url":"https://api.github.com/users/Heufneutje/following{/other_user}","gists_url":"https://api.github.com/users/Heufneutje/gists{/gist_id}","starred_url":"https://api.github.com/users/Heufneutje/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Heufneutje/subscriptions","organizations_url":"https://api.github.com/users/Heufneutje/orgs","repos_url":"https://api.github.com/users/Heufneutje/repos","events_url":"https://api.github.com/users/Heufneutje/events{/privacy}","received_events_url":"https://api.github.com/users/Heufneutje/received_events","type":"User","site_admin":false},"body":"Since we're still in the breakage phase of txircd 0.4, I give you a breaking, yet valuable in my opinion, change.\r\n\r\nSo let's go over the things that are in this PR:\r\n- Replacement of a lot of magic numbers with configurable equivalents. I kinda took this upon myself because the amount of magic numbers we have bothered me. Making these configurable is, in my opinion, a change that will not only make the codebase cleaner and assure that these numbers are always the same in all cases (see my fix in TOPICLEN for an example on this one), but also make txircd a lot more configurable for our users. One could argue that a lot of these numbers should never be changed, but I prefer going the InspIRCd route of \"configurable but discouraged\" over \"not configurable at all\". Besides, we already had some of them configurable. It doesn't really make sense to make some configurable and some hardcoded.\r\n\r\n- The addition of a few new limits. We did not yet have limits on our gecos, our AWAY messages and our KICK reasons. In my opinion they should be present since I was working on the limits anyway, I added them. The default values were taken from InspIRCd.\r\n\r\n- Modularization of extra ISUPPORT tokens. The last change is for the ISUPPORT dictionary generation, which now allows modules to add their own tokens on top of the default ones we already have. In theory we could even move the tokens that belong to core modules to their respective modules, but I'll let you be the judge on that one.","created_at":"2015-05-15T19:29:27Z","updated_at":"2015-05-30T20:26:21Z","closed_at":null,"merged_at":null,"merge_commit_sha":"31528f2169c9a4aa43e3cc74b38857e038f9e702","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/116/commits","review_comments_url":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/116/comments","review_comment_url":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ElementalAlchemist/txircd/issues/116/comments","statuses_url":"https://api.github.com/repos/ElementalAlchemist/txircd/statuses/8dbbfac1e626cc341ee3cf86c56cec902042b6cf","head":{"label":"Heufneutje:limit-overhaul-and-isupport","ref":"limit-overhaul-and-isupport","sha":"8dbbfac1e626cc341ee3cf86c56cec902042b6cf","user":{"login":"Heufneutje","id":1357231,"avatar_url":"https://avatars.githubusercontent.com/u/1357231?v=3","gravatar_id":"","url":"https://api.github.com/users/Heufneutje","html_url":"https://github.com/Heufneutje","followers_url":"https://api.github.com/users/Heufneutje/followers","following_url":"https://api.github.com/users/Heufneutje/following{/other_user}","gists_url":"https://api.github.com/users/Heufneutje/gists{/gist_id}","starred_url":"https://api.github.com/users/Heufneutje/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Heufneutje/subscriptions","organizations_url":"https://api.github.com/users/Heufneutje/orgs","repos_url":"https://api.github.com/users/Heufneutje/repos","events_url":"https://api.github.com/users/Heufneutje/events{/privacy}","received_events_url":"https://api.github.com/users/Heufneutje/received_events","type":"User","site_admin":false},"repo":{"id":28537151,"name":"txircd","full_name":"Heufneutje/txircd","owner":{"login":"Heufneutje","id":1357231,"avatar_url":"https://avatars.githubusercontent.com/u/1357231?v=3","gravatar_id":"","url":"https://api.github.com/users/Heufneutje","html_url":"https://github.com/Heufneutje","followers_url":"https://api.github.com/users/Heufneutje/followers","following_url":"https://api.github.com/users/Heufneutje/following{/other_user}","gists_url":"https://api.github.com/users/Heufneutje/gists{/gist_id}","starred_url":"https://api.github.com/users/Heufneutje/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Heufneutje/subscriptions","organizations_url":"https://api.github.com/users/Heufneutje/orgs","repos_url":"https://api.github.com/users/Heufneutje/repos","events_url":"https://api.github.com/users/Heufneutje/events{/privacy}","received_events_url":"https://api.github.com/users/Heufneutje/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Heufneutje/txircd","description":"Twisted IRC Daemon","fork":true,"url":"https://api.github.com/repos/Heufneutje/txircd","forks_url":"https://api.github.com/repos/Heufneutje/txircd/forks","keys_url":"https://api.github.com/repos/Heufneutje/txircd/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Heufneutje/txircd/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Heufneutje/txircd/teams","hooks_url":"https://api.github.com/repos/Heufneutje/txircd/hooks","issue_events_url":"https://api.github.com/repos/Heufneutje/txircd/issues/events{/number}","events_url":"https://api.github.com/repos/Heufneutje/txircd/events","assignees_url":"https://api.github.com/repos/Heufneutje/txircd/assignees{/user}","branches_url":"https://api.github.com/repos/Heufneutje/txircd/branches{/branch}","tags_url":"https://api.github.com/repos/Heufneutje/txircd/tags","blobs_url":"https://api.github.com/repos/Heufneutje/txircd/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Heufneutje/txircd/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Heufneutje/txircd/git/refs{/sha}","trees_url":"https://api.github.com/repos/Heufneutje/txircd/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Heufneutje/txircd/statuses/{sha}","languages_url":"https://api.github.com/repos/Heufneutje/txircd/languages","stargazers_url":"https://api.github.com/repos/Heufneutje/txircd/stargazers","contributors_url":"https://api.github.com/repos/Heufneutje/txircd/contributors","subscribers_url":"https://api.github.com/repos/Heufneutje/txircd/subscribers","subscription_url":"https://api.github.com/repos/Heufneutje/txircd/subscription","commits_url":"https://api.github.com/repos/Heufneutje/txircd/commits{/sha}","git_commits_url":"https://api.github.com/repos/Heufneutje/txircd/git/commits{/sha}","comments_url":"https://api.github.com/repos/Heufneutje/txircd/comments{/number}","issue_comment_url":"https://api.github.com/repos/Heufneutje/txircd/issues/comments{/number}","contents_url":"https://api.github.com/repos/Heufneutje/txircd/contents/{+path}","compare_url":"https://api.github.com/repos/Heufneutje/txircd/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Heufneutje/txircd/merges","archive_url":"https://api.github.com/repos/Heufneutje/txircd/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Heufneutje/txircd/downloads","issues_url":"https://api.github.com/repos/Heufneutje/txircd/issues{/number}","pulls_url":"https://api.github.com/repos/Heufneutje/txircd/pulls{/number}","milestones_url":"https://api.github.com/repos/Heufneutje/txircd/milestones{/number}","notifications_url":"https://api.github.com/repos/Heufneutje/txircd/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Heufneutje/txircd/labels{/name}","releases_url":"https://api.github.com/repos/Heufneutje/txircd/releases{/id}","created_at":"2014-12-27T13:21:15Z","updated_at":"2015-04-29T07:42:15Z","pushed_at":"2015-05-30T20:05:08Z","git_url":"git://github.com/Heufneutje/txircd.git","ssh_url":"git@github.com:Heufneutje/txircd.git","clone_url":"https://github.com/Heufneutje/txircd.git","svn_url":"https://github.com/Heufneutje/txircd","homepage":null,"size":3946,"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":"dev/next"}},"base":{"label":"ElementalAlchemist:dev/next","ref":"dev/next","sha":"24aaf072fc62b5eae54d9b715b06715f48c9de68","user":{"login":"ElementalAlchemist","id":115662,"avatar_url":"https://avatars.githubusercontent.com/u/115662?v=3","gravatar_id":"","url":"https://api.github.com/users/ElementalAlchemist","html_url":"https://github.com/ElementalAlchemist","followers_url":"https://api.github.com/users/ElementalAlchemist/followers","following_url":"https://api.github.com/users/ElementalAlchemist/following{/other_user}","gists_url":"https://api.github.com/users/ElementalAlchemist/gists{/gist_id}","starred_url":"https://api.github.com/users/ElementalAlchemist/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ElementalAlchemist/subscriptions","organizations_url":"https://api.github.com/users/ElementalAlchemist/orgs","repos_url":"https://api.github.com/users/ElementalAlchemist/repos","events_url":"https://api.github.com/users/ElementalAlchemist/events{/privacy}","received_events_url":"https://api.github.com/users/ElementalAlchemist/received_events","type":"User","site_admin":false},"repo":{"id":6614056,"name":"txircd","full_name":"ElementalAlchemist/txircd","owner":{"login":"ElementalAlchemist","id":115662,"avatar_url":"https://avatars.githubusercontent.com/u/115662?v=3","gravatar_id":"","url":"https://api.github.com/users/ElementalAlchemist","html_url":"https://github.com/ElementalAlchemist","followers_url":"https://api.github.com/users/ElementalAlchemist/followers","following_url":"https://api.github.com/users/ElementalAlchemist/following{/other_user}","gists_url":"https://api.github.com/users/ElementalAlchemist/gists{/gist_id}","starred_url":"https://api.github.com/users/ElementalAlchemist/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ElementalAlchemist/subscriptions","organizations_url":"https://api.github.com/users/ElementalAlchemist/orgs","repos_url":"https://api.github.com/users/ElementalAlchemist/repos","events_url":"https://api.github.com/users/ElementalAlchemist/events{/privacy}","received_events_url":"https://api.github.com/users/ElementalAlchemist/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ElementalAlchemist/txircd","description":"Twisted IRC Daemon","fork":true,"url":"https://api.github.com/repos/ElementalAlchemist/txircd","forks_url":"https://api.github.com/repos/ElementalAlchemist/txircd/forks","keys_url":"https://api.github.com/repos/ElementalAlchemist/txircd/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ElementalAlchemist/txircd/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ElementalAlchemist/txircd/teams","hooks_url":"https://api.github.com/repos/ElementalAlchemist/txircd/hooks","issue_events_url":"https://api.github.com/repos/ElementalAlchemist/txircd/issues/events{/number}","events_url":"https://api.github.com/repos/ElementalAlchemist/txircd/events","assignees_url":"https://api.github.com/repos/ElementalAlchemist/txircd/assignees{/user}","branches_url":"https://api.github.com/repos/ElementalAlchemist/txircd/branches{/branch}","tags_url":"https://api.github.com/repos/ElementalAlchemist/txircd/tags","blobs_url":"https://api.github.com/repos/ElementalAlchemist/txircd/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ElementalAlchemist/txircd/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ElementalAlchemist/txircd/git/refs{/sha}","trees_url":"https://api.github.com/repos/ElementalAlchemist/txircd/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ElementalAlchemist/txircd/statuses/{sha}","languages_url":"https://api.github.com/repos/ElementalAlchemist/txircd/languages","stargazers_url":"https://api.github.com/repos/ElementalAlchemist/txircd/stargazers","contributors_url":"https://api.github.com/repos/ElementalAlchemist/txircd/contributors","subscribers_url":"https://api.github.com/repos/ElementalAlchemist/txircd/subscribers","subscription_url":"https://api.github.com/repos/ElementalAlchemist/txircd/subscription","commits_url":"https://api.github.com/repos/ElementalAlchemist/txircd/commits{/sha}","git_commits_url":"https://api.github.com/repos/ElementalAlchemist/txircd/git/commits{/sha}","comments_url":"https://api.github.com/repos/ElementalAlchemist/txircd/comments{/number}","issue_comment_url":"https://api.github.com/repos/ElementalAlchemist/txircd/issues/comments{/number}","contents_url":"https://api.github.com/repos/ElementalAlchemist/txircd/contents/{+path}","compare_url":"https://api.github.com/repos/ElementalAlchemist/txircd/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ElementalAlchemist/txircd/merges","archive_url":"https://api.github.com/repos/ElementalAlchemist/txircd/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ElementalAlchemist/txircd/downloads","issues_url":"https://api.github.com/repos/ElementalAlchemist/txircd/issues{/number}","pulls_url":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls{/number}","milestones_url":"https://api.github.com/repos/ElementalAlchemist/txircd/milestones{/number}","notifications_url":"https://api.github.com/repos/ElementalAlchemist/txircd/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ElementalAlchemist/txircd/labels{/name}","releases_url":"https://api.github.com/repos/ElementalAlchemist/txircd/releases{/id}","created_at":"2012-11-09T13:49:39Z","updated_at":"2015-04-30T03:59:21Z","pushed_at":"2015-05-30T20:05:08Z","git_url":"git://github.com/ElementalAlchemist/txircd.git","ssh_url":"git@github.com:ElementalAlchemist/txircd.git","clone_url":"https://github.com/ElementalAlchemist/txircd.git","svn_url":"https://github.com/ElementalAlchemist/txircd","homepage":null,"size":7180,"stargazers_count":3,"watchers_count":3,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":1,"forks":2,"open_issues":1,"watchers":3,"default_branch":"dev/next"}},"_links":{"self":{"href":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/116"},"html":{"href":"https://github.com/ElementalAlchemist/txircd/pull/116"},"issue":{"href":"https://api.github.com/repos/ElementalAlchemist/txircd/issues/116"},"comments":{"href":"https://api.github.com/repos/ElementalAlchemist/txircd/issues/116/comments"},"review_comments":{"href":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/116/comments"},"review_comment":{"href":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ElementalAlchemist/txircd/pulls/116/commits"},"statuses":{"href":"https://api.github.com/repos/ElementalAlchemist/txircd/statuses/8dbbfac1e626cc341ee3cf86c56cec902042b6cf"}}}}