Skip to content

Fix uninitialized constant CustomDeviseMailer on new org user invite (Resolves #5745) - #5762

Open
apostergiakis wants to merge 1 commit into
rubyforgood:mainfrom
apostergiakis:5745-fix-custom-devise-mailer-load
Open

apostergiakis wants to merge 1 commit into
rubyforgood:mainfrom
apostergiakis:5745-fix-custom-devise-mailer-load

Conversation

@apostergiakis

Copy link
Copy Markdown

Resolves #5745

Description

Bumps devise_invitable 2.0.13 → 2.0.14, as agreed in the issue.

2.0.13 resolves Devise.mailer in an on_load(:action_mailer) hook. Without eager loading (e.g. development), that hook can fire while CustomDeviseMailer is still loading, which raises uninitialized constant CustomDeviseMailer. 2.0.14 contains only the upstream fix (scambra/devise_invitable#929).

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Added spec/lib/custom_devise_mailer_load_spec.rb, which boots a fresh non-eager-loaded process, since CI eager-loads and hides the bug. It fails on 2.0.13 and passes on 2.0.14. Related mailer, invite and admin specs pass locally.

… a cold-loaded process (rubyforgood#5745)

Bump devise_invitable 2.0.13 -> 2.0.14. 2.0.13's :action_mailer load
hook resolved Devise.mailer while CustomDeviseMailer was still being
autoloaded, so the first invite in a non-eager-loaded process failed.
2.0.14 (scambra/devise_invitable#929) contains only that fix.

Adds a spec that boots a fresh non-eager-loaded process, since CI
eager-loads and hides the failure.

Resolves rubyforgood#5745

This branch has not been deployed

No deployments
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.

[BUG]: New User add for New Org page fails with error

1 participant