Showing 44 of 45 total issues
Method register_listener
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def register_listener(event_name, topic, subscriber_id, auto_ack, subscriber_opts, sub)
Line is too long. [82/80] Open
Open
# Called on TTIN to inspect the state of the runner in a terminal friendly
- Exclude checks
Line is too long. [89/80] Open
Open
raise InvalidMiddlewareError, middleware unless middleware.respond_to?(:call)
- Exclude checks
Do not suppress exceptions. Open
Open
rescue StandardError
- Read upRead up
- Exclude checks
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
Line is too long. [84/80] Open
Open
tags: %i[event_name subscription status],
- Exclude checks
Line is too long. [94/80] Open
Open
logger.debug("Registered listener for #{subscriber_id} with: #{subscriber_options}")
- Exclude checks
Line is too long. [81/80] Open
Open
30, 60, 120, 300, 1800, 3600, 21_600 # Tasks may be very long-running
- Exclude checks
Line is too long. [95/80] Open
Open
def register_listener(event_name, topic, subscriber_id, auto_ack, subscriber_opts, sub)
- Exclude checks
Line is too long. [100/80] Open
Open
histogram :subscriber_runtime, comment: 'A histogram of the subscriber execution time.',
- Exclude checks
Line is too long. [93/80] Open
Open
"but its name #{found_subscription.topic.name} does not match #{@event_name}"
- Exclude checks
Line is too long. [94/80] Open
Open
builder.use Yabeda::Prometheus::Exporter if defined?(Yabeda::Prometheus::Exporter)
- Exclude checks
Line is too long. [81/80] Open
Open
# Instead of making `start` blocking, expose a way to probe for readiness
- Exclude checks
Line is too long. [94/80] Open
Open
sub = Hanami::Events::CloudPubsub::Subscriber.new(event_name, block, logger: logger)
- Exclude checks
Line is too long. [81/80] Open
Open
# This pattern is similar to Kubernete's healthiness and readniess probes
- Exclude checks
Line is too long. [92/80] Open
Open
requirements_for_all = ::Hanami::Components.component('all').send(:requirements)
- Exclude checks
Line is too long. [88/80] Open
Open
file = parts[:file].sub(/^#{Regexp.escape(File.join(Dir.getwd, ''))}/, '')
- Exclude checks
Line is too long. [81/80] Open
Open
ENV['PUBSUB_EMULATOR_HOST'] ||= 'localhost:8085' if opts[:emulator]
- Exclude checks
Do not suppress exceptions. Open
Open
rescue LoadError
- Read upRead up
- Exclude checks
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
Line is too long. [95/80] Open
Open
sub.retry_policy = retry_policy if sub.retry_policy&.to_grpc != retry_policy&.to_grpc
- Exclude checks
Line is too long. [82/80] Open
Open
# If a gracefully_shutdown times out or fails, this method will be called.
- Exclude checks