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

Deprecation warning with Rack 3 #198

Closed
nickstanish opened this issue Nov 7, 2023 · 1 comment · Fixed by #201
Closed

Deprecation warning with Rack 3 #198

nickstanish opened this issue Nov 7, 2023 · 1 comment · Fixed by #201

Comments

@nickstanish
Copy link
Contributor

Environment

Provide at least:

  • Ruby Version: 3.2.2
  • Rails Version. 7-1-stable branch
  • Semantic Logger Version: 4.14.0
  • Rails Semantic Logger Version: 4.12.0 (though using this fix fix: remove undef :broadcast since ActiveSupport::Logger dropped it #194)
  • Other Application/framework names and versions (e.g. Puma, etc.). Rack 3.0.8
  • Rails configuration. Only need the settings related to Rails Semantic Logger and Semantic Logger.
  • Full Stack Trace, if an exception is being raised.

Note:

Expected Behavior

Deprecation warning is resolved

Actual Behavior

Running rails server outputs a deprecation warning traced back to this line:

require("rails_semantic_logger/extensions/rack/server") if defined?(Rack::Server)

Rack::Server is deprecated and replaced by Rackup::Server
=> Booting Puma
=> Rails 7.1.1 application starting in development
=> Run `bin/rails server --help` for more startup options

Rack 3 moved Rack::Server to Rackup::Server https://github.com/rack/rackup/blob/eaea24a3d64a1b117df943a9d06779e659bb61af/lib/rack/server.rb#L6-L10

Pull Request

  • Consider submitting a Pull Request with a fix for the issue.
    • This is particularly helpful when running newer Rails versions, since we are not running it yet.
  • Or, even a Pull request that only includes a test that reproduces the problem.
@reidmorrison
Copy link
Owner

A pull request would be most welcome.

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 a pull request may close this issue.

2 participants