Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dotenv's tagged method conflicts with SemanticLogger's #497

Closed
kolobock opened this issue Mar 1, 2024 · 1 comment
Closed

Dotenv's tagged method conflicts with SemanticLogger's #497

kolobock opened this issue Mar 1, 2024 · 1 comment

Comments

@kolobock
Copy link

kolobock commented Mar 1, 2024

Steps to reproduce

SemanticLogger is used as default Rails logger in the application.
Once we call dotenv/load we got error.
This started to be reproduced at v3.0.3 (#489)

Expected behavior

Dotenv should load ENVs without any issue.

Actual behavior

LocalJumpError:
  no block given (yield)
# /ruby/3.2.0/gems/semantic_logger-4.15.0/lib/semantic_logger/base.rb:190:in `block in tagged'
# /ruby/3.2.0/gems/semantic_logger-4.15.0/lib/semantic_logger/semantic_logger.rb:319:in `fast_tag'
# /ruby/3.2.0/gems/semantic_logger-4.15.0/lib/semantic_logger/base.rb:197:in `tagged'
# /ruby/3.2.0/gems/dotenv-3.0.3/lib/dotenv/rails.rb:93:in `block in <class:Rails>'
# /ruby/3.2.0/gems/railties-7.0.8.1/lib/rails/initializable.rb:32:in `instance_exec'
# /ruby/3.2.0/gems/railties-7.0.8.1/lib/rails/initializable.rb:32:in `run'
# /ruby/3.2.0/gems/railties-7.0.8.1/lib/rails/initializable.rb:61:in `block in run_initializers'
# /ruby/3.2.0/gems/railties-7.0.8.1/lib/rails/initializable.rb:60:in `run_initializers'
# /ruby/3.2.0/gems/railties-7.0.8.1/lib/rails/application.rb:372:in `initialize!'
# ./config/environment.rb:5:in `<top (required)>'
# ./spec/rails_helper.rb:7:in `<top (required)>'

System configuration

dotenv version: >= 3.0.3

Rails version: 7.0.8.1

Ruby version: 3.2.3

@bkeepers
Copy link
Owner

bkeepers commented Mar 1, 2024

Duplicate of #493, fixed in 3.1.0

@bkeepers bkeepers closed this as completed Mar 1, 2024
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

No branches or pull requests

2 participants