Skip to content

Commit

Permalink
fix(tmp): add hack to restore methods visibility after Sentry patch
Browse files Browse the repository at this point in the history
  • Loading branch information
palkan committed Jan 31, 2022
1 parent 2f12376 commit 99a289a
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lib/anycable/rails/railtie.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,13 @@ class Railtie < ::Rails::Railtie # :nodoc:
end
end

# Temp hack to fix Sentry vs AnyCable incompatibility
# See https://github.com/anycable/anycable-rails/issues/165
initializer "anycable.sentry_hack", after: :"sentry.extend_action_cable" do
next unless defined?(::Sentry::Rails::ActionCableExtensions::Connection)
Sentry::Rails::ActionCableExtensions::Connection.send :public, :handle_open, :handle_close
end

# Since Rails 6.1
if respond_to?(:server)
server do
Expand Down

3 comments on commit 99a289a

@kvirani
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @palkan can you publish 1.2.1 so that I can work around this issue as well? Please and thanks in advance!

@kvirani
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: For now I've worked around it by using the tag from github:

gem 'anycable-rails', github: 'anycable/anycable-rails', tag: 'v1.2.1'

But ideally it picks it up from rubygems too

@palkan
Copy link
Member Author

@palkan palkan commented on 99a289a Feb 18, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.