Skip to content

chore: remove dead turbo-rails monkey patches initializer - #159

Open
detail-app[bot] wants to merge 1 commit into
masterfrom
detail/dead-code/chore-remove-dead-turbo-rails-monkey-patches-initi-6e718d
Open

chore: remove dead turbo-rails monkey patches initializer#159
detail-app[bot] wants to merge 1 commit into
masterfrom
detail/dead-code/chore-remove-dead-turbo-rails-monkey-patches-initi-6e718d

Conversation

@detail-app

@detail-app detail-app Bot commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Removed config/initializers/hotwire_turbo_monkey_patches.rb, which patched two upstream turbo-rails bugs, both fixed in the pinned turbo-rails 2.0.23:

  • The ActionCable eager-load workaround (turbo-rails#512) is now done by turbo-rails' own 'turbo.no_action_cable' initializer (lib/turbo/engine.rb:29-33), with the same guard and target path, making the local do_not_eager_load line fully redundant.
  • The BroadcastStreamJob.perform_later 'content: content.to_str' override (turbo-rails#535) is unreachable from Plutonium: the only production broadcast path is Broadcaster.broadcast -> Turbo::StreamsChannel.broadcast_stream_to (broadcasts.rb:98-105), which is synchronous and never dispatches the job. Upstream also self-coerces .to_str at its only perform_later callsite (broadcasts.rb:74), and Plutonium passes a plain String, so even if reached the override would be a no-op.

No code referenced the file; it was glob-loaded by the plutonium.initializers railtie initializer (lib/plutonium/railtie.rb:38-40) alongside four other live initializers, which remain.

History

  • Last materially changed April 2024

Dead Code PRs can be configured here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant