{"action":"created","issue":{"url":"https://api.github.com/repos/capistrano/capistrano/issues/1404","labels_url":"https://api.github.com/repos/capistrano/capistrano/issues/1404/labels{/name}","comments_url":"https://api.github.com/repos/capistrano/capistrano/issues/1404/comments","events_url":"https://api.github.com/repos/capistrano/capistrano/issues/1404/events","html_url":"https://github.com/capistrano/capistrano/issues/1404","id":63838857,"number":1404,"title":"Linting cleanliness","user":{"login":"leehambley","id":18952,"avatar_url":"https://avatars.githubusercontent.com/u/18952?v=3","gravatar_id":"","url":"https://api.github.com/users/leehambley","html_url":"https://github.com/leehambley","followers_url":"https://api.github.com/users/leehambley/followers","following_url":"https://api.github.com/users/leehambley/following{/other_user}","gists_url":"https://api.github.com/users/leehambley/gists{/gist_id}","starred_url":"https://api.github.com/users/leehambley/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leehambley/subscriptions","organizations_url":"https://api.github.com/users/leehambley/orgs","repos_url":"https://api.github.com/users/leehambley/repos","events_url":"https://api.github.com/users/leehambley/events{/privacy}","received_events_url":"https://api.github.com/users/leehambley/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-03-23T21:40:25Z","updated_at":"2015-03-30T02:29:36Z","closed_at":null,"body":"So, this was the results of an untuned `rubocop -l` on master, I think one or two of them are actually bugs, and the rest are valid code style points.\r\n\r\n```\r\nrubocop -l\r\nwarning: parser/current is loading parser/ruby21, which recognizes\r\nwarning: 2.1.5-compliant syntax, but you are running 2.1.3.\r\nInspecting 73 files\r\n.....W...W...W.WW............WW..W.WWW...W........WW.....W..............W\r\n\r\nOffenses:\r\n\r\nfeatures/step_definitions/assertions.rb:53:15: W: File.exists? is deprecated in favor of File.exist?.\r\n  expect(File.exists?(file)).to be true\r\n              ^^^^^^^\r\nfeatures/step_definitions/assertions.rb:59:15: W: File.exists? is deprecated in favor of File.exist?.\r\n  expect(File.exists?(staging)).to be true\r\n              ^^^^^^^\r\nfeatures/step_definitions/assertions.rb:60:15: W: File.exists? is deprecated in favor of File.exist?.\r\n  expect(File.exists?(production)).to be true\r\n              ^^^^^^^\r\nfeatures/step_definitions/assertions.rb:65:14: W: Dir.exists? is deprecated in favor of Dir.exist?.\r\n  expect(Dir.exists?(path)).to be true\r\n             ^^^^^^^\r\nfeatures/step_definitions/assertions.rb:71:15: W: File.exists? is deprecated in favor of File.exist?.\r\n  expect(File.exists?(qa)).to be true\r\n              ^^^^^^^\r\nfeatures/step_definitions/assertions.rb:72:15: W: File.exists? is deprecated in favor of File.exist?.\r\n  expect(File.exists?(production)).to be true\r\n              ^^^^^^^\r\nfeatures/support/remote_command_helpers.rb:18:26: W: Unused method argument - path. If it's necessary, use _ or _path as an argument name to indicate that it won't be used. You can also write as safely_remove_file(*) if you want the method to accept any arguments but don't care about them.\r\n  def safely_remove_file(path)\r\n                         ^^^^\r\nlib/capistrano/application.rb:66:16: W: Assignment in condition - you probably meant to use ==.\r\n        if loc = Rake.application.find_rakefile_location\r\n               ^\r\nlib/capistrano/application.rb:104:18: W: Unused block argument - value. If it's necessary, use _ or _value as an argument name to indicate that it won't be used. Also consider using a proc without arguments instead of a lambda if you want it to accept any arguments but don't care about them.\r\n       lambda { |value|\r\n                 ^^^^^\r\nlib/capistrano/application.rb:114:18: W: Unused block argument - value. If it's necessary, use _ or _value as an argument name to indicate that it won't be used. Also consider using a proc without arguments instead of a lambda if you want it to accept any arguments but don't care about them.\r\n       lambda { |value|\r\n                 ^^^^^\r\nlib/capistrano/configuration/question.rb:41:7: W: Do not suppress exceptions.\r\n      rescue Errno::EIO\r\n      ^^^^^^^^^^^^^^^^^\r\nlib/capistrano/configuration/server.rb:151:14: W: Unused block argument - server. If it's necessary, use _ or _server as an argument name to indicate that it won't be used. Also consider using a proc without arguments instead of a lambda if you want it to accept any arguments but don't care about them.\r\n          ->(server) { :all }\r\n             ^^^^^^\r\nlib/capistrano/git.rb:11:21: W: Ambiguous splat operator. Parenthesize the method arguments if it's surely a splat operator, or add a whitespace to the right of the * if it should be a multiplication.\r\n    context.execute *args\r\n                    ^\r\nlib/capistrano/git.rb:33:15: W: Assignment in condition - you probably meant to use ==.\r\n      if tree = fetch(:repo_tree)\r\n              ^\r\nlib/capistrano/hg.rb:9:21: W: Ambiguous splat operator. Parenthesize the method arguments if it's surely a splat operator, or add a whitespace to the right of the * if it should be a multiplication.\r\n    context.execute *args\r\n                    ^\r\nlib/capistrano/hg.rb:30:15: W: Assignment in condition - you probably meant to use ==.\r\n      if tree = fetch(:repo_tree)\r\n              ^\r\nlib/capistrano/scm.rb:28:20: W: Ambiguous splat operator. Parenthesize the method arguments if it's surely a splat operator, or add a whitespace to the right of the * if it should be a multiplication.\r\n      context.test *args\r\n                   ^\r\nlib/capistrano/svn.rb:10:21: W: Ambiguous splat operator. Parenthesize the method arguments if it's surely a splat operator, or add a whitespace to the right of the * if it should be a multiplication.\r\n    context.execute *args\r\n                    ^\r\nlib/capistrano/tasks/console.rake:8:14: W: Assignment in condition - you probably meant to use ==.\r\n    if input = $stdin.gets\r\n             ^\r\nlib/capistrano/tasks/deploy.rake:63:33: W: Unused block argument - host. You can omit the argument if you don't care about it.\r\n      on release_roles :all do |host|\r\n                                ^^^^\r\nlib/capistrano/tasks/install.rake:21:13: W: File.exists? is deprecated in favor of File.exist?.\r\n    if File.exists?(entry[:file])\r\n            ^^^^^^^\r\nlib/capistrano/tasks/install.rake:33:11: W: File.exists? is deprecated in favor of File.exist?.\r\n  if File.exists?('Capfile')\r\n          ^^^^^^^\r\nspec/lib/capistrano/application_spec.rb:37:5: W: Useless assignment to variable - out. Use _ or _out as a variable name to indicate that it won't be used.\r\n    out, _ = capture_io do\r\n    ^^^\r\nspec/lib/capistrano/application_spec.rb:54:23: W: Unused method argument - args. If it's necessary, use _ or _args as an argument name to indicate that it won't be used. You can also write as exit(*) if you want the method to accept any arguments but don't care about them.\r\n    def subject.exit(*args)\r\n                      ^^^^\r\nspec/lib/capistrano/configuration/filter_spec.rb:15:13: W: Useless assignment to variable - f.\r\n            f = Filter.new(:zarg)\r\n            ^\r\nspec/lib/capistrano/dsl/task_enhancements_spec.rb:22:54: W: Unused block argument - t. If it's necessary, use _ or _t as an argument name to indicate that it won't be used.\r\n        Rake::Task.define_task('task', [:order]) do |t, args|\r\n                                                     ^\r\nspec/lib/capistrano/dsl/task_enhancements_spec.rb:58:74: W: Unused block argument - t. You can omit all the arguments if you don't care about them.\r\n        task_enhancements.after('task', 'after_task_custom', :order) do |t, args|\r\n                                                                         ^\r\nspec/lib/capistrano/dsl/task_enhancements_spec.rb:58:77: W: Unused block argument - args. You can omit all the arguments if you don't care about them.\r\n        task_enhancements.after('task', 'after_task_custom', :order) do |t, args|\r\n                                                                            ^^^^\r\nspec/lib/capistrano/dsl/task_enhancements_spec.rb:62:76: W: Unused block argument - t. You can omit all the arguments if you don't care about them.\r\n        task_enhancements.before('task', 'before_task_custom', :order) do |t, args|\r\n                                                                           ^\r\nspec/lib/capistrano/dsl/task_enhancements_spec.rb:62:79: W: Unused block argument - args. You can omit all the arguments if you don't care about them.\r\n        task_enhancements.before('task', 'before_task_custom', :order) do |t, args|\r\n                                                                              ^^^^\r\nspec/support/Vagrantfile:4:47: W: Shadowing outer local variable - config.\r\n    config.vm.define(role, primary: true) do |config|\r\n                                              ^^^^^^\r\n\r\n73 files inspected, 31 offenses detected\r\n```"},"comment":{"url":"https://api.github.com/repos/capistrano/capistrano/issues/comments/87517659","html_url":"https://github.com/capistrano/capistrano/issues/1404#issuecomment-87517659","issue_url":"https://api.github.com/repos/capistrano/capistrano/issues/1404","id":87517659,"user":{"login":"paulschreiber","id":86784,"avatar_url":"https://avatars.githubusercontent.com/u/86784?v=3","gravatar_id":"","url":"https://api.github.com/users/paulschreiber","html_url":"https://github.com/paulschreiber","followers_url":"https://api.github.com/users/paulschreiber/followers","following_url":"https://api.github.com/users/paulschreiber/following{/other_user}","gists_url":"https://api.github.com/users/paulschreiber/gists{/gist_id}","starred_url":"https://api.github.com/users/paulschreiber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paulschreiber/subscriptions","organizations_url":"https://api.github.com/users/paulschreiber/orgs","repos_url":"https://api.github.com/users/paulschreiber/repos","events_url":"https://api.github.com/users/paulschreiber/events{/privacy}","received_events_url":"https://api.github.com/users/paulschreiber/received_events","type":"User","site_admin":false},"created_at":"2015-03-30T02:29:36Z","updated_at":"2015-03-30T02:29:36Z","body":"I fixed most of these:\r\n\r\nThese are the remaining warnings, which I suspect are the actual bugs.\r\n```\r\nlib/capistrano/configuration/question.rb:41:7: W: Do not suppress exceptions.\r\n      rescue Errno::EIO\r\n      ^^^^^^^^^^^^^^^^^\r\nspec/support/Vagrantfile:8:47: W: Shadowing outer local variable - config.\r\n    config.vm.define(role, primary: true) do |config|\r\n                                              ^^^^^^\r\n```"}}