What is the “env” variable in Rack middleware?
问题 I know a Rack middleware filter is a Ruby class with an initialize and a call method. I know the call method takes an "env" argument. Something like this: class MyFilter def initialize(app) end def call(env) end end My question is: what exactly is the "env" argument sent to "call"? Is this the same as the Rails ENV environment (ie. development, testing, production). Thanks! 回答1: env is just a hash. Rack itself and various middlewares add values into it. To understand what the various keys are