{"action":"created","issue":{"url":"https://api.github.com/repos/PerlDancer/Dancer2/issues/943","labels_url":"https://api.github.com/repos/PerlDancer/Dancer2/issues/943/labels{/name}","comments_url":"https://api.github.com/repos/PerlDancer/Dancer2/issues/943/comments","events_url":"https://api.github.com/repos/PerlDancer/Dancer2/issues/943/events","html_url":"https://github.com/PerlDancer/Dancer2/issues/943","id":93585747,"number":943,"title":"VERSION sub doesn't validate the given argument","user":{"login":"miyagawa","id":3499,"avatar_url":"https://avatars.githubusercontent.com/u/3499?v=3","gravatar_id":"","url":"https://api.github.com/users/miyagawa","html_url":"https://github.com/miyagawa","followers_url":"https://api.github.com/users/miyagawa/followers","following_url":"https://api.github.com/users/miyagawa/following{/other_user}","gists_url":"https://api.github.com/users/miyagawa/gists{/gist_id}","starred_url":"https://api.github.com/users/miyagawa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miyagawa/subscriptions","organizations_url":"https://api.github.com/users/miyagawa/orgs","repos_url":"https://api.github.com/users/miyagawa/repos","events_url":"https://api.github.com/users/miyagawa/events{/privacy}","received_events_url":"https://api.github.com/users/miyagawa/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-07-07T17:35:43Z","updated_at":"2015-07-07T19:11:26Z","closed_at":null,"body":"perl's UNIVERSAL VERSION sub is supposed to validate a supplied argument, when it is given.\r\n\r\n```\r\n➜  ~  perl -e 'use Data::Dumper'\r\n➜  ~  perl -e 'use Data::Dumper 11'\r\nData::Dumper version 11 required--this is only version 2.154 at -e line 1.\r\nBEGIN failed--compilation aborted at -e line 1.\r\n```\r\n\r\nDancer2's VERSION sub defined in #879 #882 #883 don't pass the argument (`@_`) to its SUPER sub, meaning `use Dancer2 99` or `perl -MDancer2\\ 99` will just pass without checking the version, which is incorrect.\r\n\r\nSee perldoc UNIVERSAL for more about this behavior.\r\n\r\nYou should at least pass the argument to the super sub. You might also want to invest a bit in dzil setup so that it keeps the `$VERSION` value  in the repository .pm files. That way you don't need to override `VERSION` sub in the first place."},"comment":{"url":"https://api.github.com/repos/PerlDancer/Dancer2/issues/comments/119306793","html_url":"https://github.com/PerlDancer/Dancer2/issues/943#issuecomment-119306793","issue_url":"https://api.github.com/repos/PerlDancer/Dancer2/issues/943","id":119306793,"user":{"login":"xsawyerx","id":54725,"avatar_url":"https://avatars.githubusercontent.com/u/54725?v=3","gravatar_id":"","url":"https://api.github.com/users/xsawyerx","html_url":"https://github.com/xsawyerx","followers_url":"https://api.github.com/users/xsawyerx/followers","following_url":"https://api.github.com/users/xsawyerx/following{/other_user}","gists_url":"https://api.github.com/users/xsawyerx/gists{/gist_id}","starred_url":"https://api.github.com/users/xsawyerx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xsawyerx/subscriptions","organizations_url":"https://api.github.com/users/xsawyerx/orgs","repos_url":"https://api.github.com/users/xsawyerx/repos","events_url":"https://api.github.com/users/xsawyerx/events{/privacy}","received_events_url":"https://api.github.com/users/xsawyerx/received_events","type":"User","site_admin":false},"created_at":"2015-07-07T19:11:26Z","updated_at":"2015-07-07T19:11:26Z","body":"Good point. Will commit, push, and release tomorrow. A release is due for a while now."}}