gregbeech/xenon

View on GitHub

Showing 51 of 51 total issues

unexpected token error
Open

    %i(set add remove).each do |name|
Severity: Minor
Found in xenon-http/lib/xenon/headers.rb by rubymotion

unexpected token tRPAREN
Open

    def unmarshal(body, as:)

cannot assign to a keyword
Open

    def initialize(scheme, token: nil, params: {})
Severity: Minor
Found in xenon-http/lib/xenon/auth.rb by rubymotion

module definition in method body
Open

module Xenon
Severity: Minor
Found in xenon-http/lib/xenon/auth.rb by rubymotion

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.
Open

          yield *values

This cop checks for ambiguous operators in the first argument of a method invocation without parentheses.

Example:

# bad

# The `*` is interpreted as a splat operator but it could possibly be
# a `*` method invocation (i.e. `do_something.*(some_array)`).
do_something *some_array

Example:

# good

# With parentheses, there's no ambiguity.
do_something(*some_array)

Useless assignment to variable - value.
Open

              value = convert_param_type(value, settings[:type]) if settings.has_key?(:type)

This cop checks for every useless assignment to local variable in every scope. The basic idea for this cop was from the warning of ruby -cw:

assigned but unused variable - foo

Currently this cop has advanced logic that detects unreferenced reassignments and properly handles varied cases such as branch, loop, rescue, ensure, etc.

Example:

# bad

def some_method
  some_var = 1
  do_something
end

Example:

# good

def some_method
  some_var = 1
  do_something(some_var)
end

class definition in method body
Open

  class GenericCredentials
Severity: Minor
Found in xenon-http/lib/xenon/auth.rb by rubymotion

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.
Open

            yield *values

This cop checks for ambiguous operators in the first argument of a method invocation without parentheses.

Example:

# bad

# The `*` is interpreted as a splat operator but it could possibly be
# a `*` method invocation (i.e. `do_something.*(some_array)`).
do_something *some_array

Example:

# good

# With parentheses, there's no ambiguity.
do_something(*some_array)

TODO found
Open

      # extras -- TODO: move these into header rules?

TODO found
Open

            tree = Xenon::Parsers.const_get("#{base_name}Header").new.parse(s) # TODO: HeaderParser would be better
Severity: Minor
Found in xenon-http/lib/xenon/headers.rb by fixme

TODO found
Open

        fail_with 500, error.message # TODO: Only if verbose errors configured
Severity: Minor
Found in xenon-routing/lib/xenon/api.rb by fixme
Severity
Category
Status
Source
Language