A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/rubocop/rubocop/issues/14248 below:

Lint/EmptyInterpolation and Lint/LiteralInInterpolation crash · Issue #14248 · rubocop/rubocop · GitHub

Hi guys,

Thanks for the good work!

Expected behavior
_ = "assertion failed: #{1.0} != #{1.0}"
_ = "assertion failed: #{..2} != #{..2}"
Actual behavior
$ bundle exec rubocop rubocop/empty_interpolation.rb
Inspecting 1 file
An error occurred while Lint/EmptyInterpolation cop was inspecting rubocop/empty_interpolation.rb:1:4.
To see the complete backtrace run rubocop -d.
An error occurred while Lint/LiteralInInterpolation cop was inspecting rubocop/empty_interpolation.rb:2:4.
To see the complete backtrace run rubocop -d.
E

Offenses:

rubocop/empty_interpolation.rb:1:1: C: [Correctable] Style/FrozenStringLiteralComment: Missing frozen string literal comment.
_ = "assertion failed: #{1.0} != #{1.0}"
^
rubocop/empty_interpolation.rb:1:26: E: [Correctable] Lint/LiteralInInterpolation: Literal interpolation detected.
_ = "assertion failed: #{1.0} != #{1.0}"
                         ^^^
rubocop/empty_interpolation.rb:1:36: E: [Correctable] Lint/LiteralInInterpolation: Literal interpolation detected.
_ = "assertion failed: #{1.0} != #{1.0}"
                                   ^^^
rubocop/empty_interpolation.rb:3:1: C: [Correctable] Layout/TrailingEmptyLines: 1 trailing blank lines detected.

1 file inspected, 4 offenses detected, 4 offenses autocorrectable

2 errors occurred:
An error occurred while Lint/EmptyInterpolation cop was inspecting rubocop/empty_interpolation.rb:1:4.
An error occurred while Lint/LiteralInInterpolation cop was inspecting rubocop/empty_interpolation.rb:2:4.
Errors are usually caused by RuboCop bugs.
Please, update to the latest RuboCop version if not already in use, and report a bug if the issue still occurs on this version.
https://github.com/rubocop/rubocop/issues

Mention the following information in the issue report:
1.76.0 (using Parser 3.3.8.0, rubocop-ast 1.45.0, analyzing as Ruby 2.7, running on ruby 3.3.8) [arm64-darwin24]
RuboCop version
$ bundle exec rubocop -V
1.76.0 (using Parser 3.3.8.0, Prism 1.4.0, rubocop-ast 1.45.0, analyzing as Ruby 3.3, running on ruby 3.3.8) [arm64-darwin24]
  - rubocop-minitest 0.38.1
  - rubocop-performance 1.25.0

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4