skateman/surro-gate

View on GitHub
lib/surro-gate/selector.rb

Summary

Maintainability
A
0 mins
Test Coverage

Method has too many lines. [22/20]
Wontfix

    def select(timeout)
      begin
        read, write, error = @mutex.synchronize { IO.select(@reads, @writes, @sockets, timeout * 0.001) }
      rescue IOError
        # One of the sockets is closed, Pair#ready? will catch it
Severity: Minor
Found in lib/surro-gate/selector.rb by rubocop

This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.

Do not suppress exceptions.
Wontfix

      rescue IOError
Severity: Minor
Found in lib/surro-gate/selector.rb by rubocop

This cop checks for rescue blocks with no body.

Example:

# bad

def some_method
  do_something
rescue
  # do nothing
end

Example:

# bad

begin
  do_something
rescue
  # do nothing
end

Example:

# good

def some_method
  do_something
rescue
  handle_exception
end

Example:

# good

begin
  do_something
rescue
  handle_exception
end

There are no issues that match your filters.

Category
Status