From: Magnus Holm <judofyr@gmail.com>
To: rack-devel@googlegroups.com
Subject: Re: Rack::Lint - Content-Length is nil in Passenger
Date: Mon, 29 Jun 2009 17:16:13 +0200 [thread overview]
Message-ID: <391a49da0906290816l38773a99u73471f88724a6b63@mail.gmail.com> (raw)
In-Reply-To: <694b2ab5-2bb7-4d77-8b3c-976dde14eeb7@b14g2000yqd.googlegroups.com>
Try putting the ContentLength-middleware above Lint.
2009/6/29, Joe Fiorini <joe@faithfulgeek.org>:
>
> I'm at the starting phase of building a web app using Rack. I'm trying
> to add in some useful middleware on top of the Lobster demo. I want to
> ensure my app always matches the spec, so I'm using Rack::Lint.
> However, this immediately bombs out telling me the Content-Length is
> nil. My config.ru looks like this:
>
> require 'rack'
> require 'rack/lobster'
>
> use Rack::ShowExceptions
> use Rack::CommonLogger
> use Rack::ShowStatus
> use Rack::Lint
> use Rack::ContentLength
> run Rack::Lobster.new
>
>
> But even if I take it down to this:
>
> require 'rack'
> require 'rack/lobster'
>
> use Rack::Lint
> use Rack::ContentLength
> run Rack::Lobster.new
>
> it still breaks! I'm running the app on Passenger. It does work,
> however, if I run straight through the rackup executable. Perhaps
> Passenger is mangling my env hash? If I take out Rack::Lint and run it
> (via Passenger), the headers do show a valid Content-Length. Weird,
> eh?
>
> Perplexed,
> Joe
>
--
//Magnus Holm
next prev parent reply other threads:[~2009-06-29 15:16 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-29 0:56 Rack::Lint - Content-Length is nil in Passenger Joe Fiorini
2009-06-29 15:16 ` Magnus Holm [this message]
2009-06-29 15:38 ` Yehuda Katz
2009-06-30 22:16 ` Hongli Lai
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://groups.google.com/group/rack-devel
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=391a49da0906290816l38773a99u73471f88724a6b63@mail.gmail.com \
--to=rack-devel@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).