Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.0
ruby-version: 3.4
- name: Install dependencies
run: bundle install
- name: Run RuboCop against BASE..HEAD changes
Expand Down
10 changes: 10 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,28 @@ on: [push]
jobs:
test:
strategy:
fail-fast: false
matrix:
ruby-version:
- '3.0'
- '3.1'
- '3.2'
- '3.3'
- '3.4'
gemfile:
- gemfiles/Gemfile.rails61
- gemfiles/Gemfile.rails70
- gemfiles/Gemfile.rails71
- gemfiles/Gemfile.rails72
- gemfiles/Gemfile.rails80
exclude:
# rails 6.1 requires ruby < 3.4
- ruby-version: '3.4'
gemfile: 'gemfiles/Gemfile.rails61'
# rails 7.0 requires ruby >= 2.7, < 3.4
# https://www.fastruby.io/blog/ruby/rails/versions/compatibility-table.html
- ruby-version: '3.4'
gemfile: 'gemfiles/Gemfile.rails70'
# rails 7.2 requires ruby >= 3.1
# https://www.fastruby.io/blog/ruby/rails/versions/compatibility-table.html
- ruby-version: '3.0'
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
## [Unreleased]
* no unreleased changes

## 2.3.3 / 2025-11-24
### Fixed
* Support Ruby 3.4, Rails 8.0 [backported from v2.4.3]
* Fix ruby 3.4 frozen string literal warnings [backported from v2.4.3]

## 2.3.2 / 2024-11-21
### Fixed
* Support Ruby 3.2 and 3.3, Rails 7.1 and 7.2. Drop support for Ruby 2.7, Rails 6.0
Expand Down
8 changes: 4 additions & 4 deletions app/helpers/ndr_error/errors_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ def highlighted_trace_for(error)

error.backtrace.map do |line|
css_classes = 'trace-item'
css_classes << ' stack-only' unless highlighting.include?(line)
css_classes += ' stack-only' unless highlighting.include?(line)

content_tag(:span, line, class: css_classes)
end
Expand Down Expand Up @@ -59,7 +59,7 @@ def downstream_fingerprint_link(print)
def ticket_link_for(fingerprint, small = false)
text = glyphicon_tag('asterisk') + ' View ticket'
css = 'btn btn-default'
css << ' btn-xs' if small
css += ' btn-xs' if small

url = fingerprint.ticket_url
link_to(text, /^http/i =~ url ? url : "http://#{url}", class: css)
Expand Down Expand Up @@ -87,7 +87,7 @@ def purge_button_for(fingerprint)

def previous_button_for(error)
css = 'btn btn-default'
css << ' disabled' if error.nil?
css += ' disabled' if error.nil?
text = glyphicon_tag('chevron-left')
path = error.nil? ? '#' : error_fingerprint_path(error.error_fingerprint, log_id: error)

Expand All @@ -96,7 +96,7 @@ def previous_button_for(error)

def next_button_for(error)
css = 'btn btn-default'
css << ' disabled' if error.nil?
css += ' disabled' if error.nil?
text = glyphicon_tag('chevron-right')
path = error.nil? ? '#' : error_fingerprint_path(error.error_fingerprint, log_id: error)

Expand Down
5 changes: 5 additions & 0 deletions gemfiles/Gemfile.rails80
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
source 'https://rubygems.org'

gemspec path: '..'

gem 'rails', '~> 8.0.0'
2 changes: 1 addition & 1 deletion lib/ndr_error/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@

# Contains the version of NdrError. Sourced by the gemspec.
module NdrError
VERSION = '2.3.2'
VERSION = '2.3.3'
end
9 changes: 8 additions & 1 deletion ndr_error.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Gem::Specification.new do |s|

s.required_ruby_version = '>= 3.0'

s.add_dependency 'rails', '>= 6.1', '< 7.3'
s.add_dependency 'rails', '>= 6.1', '< 8.1'

# Support rails 6.1 with Ruby 3.1
s.add_dependency 'net-imap'
Expand All @@ -45,6 +45,13 @@ Gem::Specification.new do |s|
# https://bugs.ruby-lang.org/issues/19371
s.add_development_dependency 'psych', '< 5'

# Workaround build issue on GitHub Actions with ruby <= 3.1 when installing sass-embedded
# Versions 1.77.0 and above require ruby >= 3.2 for packaged x86_64-linux binaries
# but say they're compatible with ruby 3.1.
# 1.76.0 has a bug that was fixed in 1.77.1, which we can't use yet.
# https://github.com/sass/dart-sass/issues/2239
s.add_development_dependency 'sass-embedded', '~> 1.75.0' if RUBY_VERSION.start_with?('3.1') # rubocop:disable Gemspec/RubyVersionGlobalsUsage

s.add_development_dependency 'mocha'
s.add_development_dependency 'test-unit', '~> 3.0'

Expand Down