Dan Langille | 7 Jan 03:19 2012

Patches 0.4.4 for PostgreSQL 9.x

Attached are patches for 0.4.4 to enable running on PostgreSQL 9.x

There may be more issues, but these are what I've found so far.

Attachment (Pentabarf0.4.4-Postgresql9-patch.diff): application/octet-stream, 3782 bytes


Dan Langille - http://langille.org

pentabarf mailing list
David Raison | 31 Jan 22:11 2012

Pentabarf submission/login going in circles


I have three posts to make, I'll create a separate thread for each one
of them.

Here's number one:

I'm running pentabarf from github with postrgres-8.4 and using fastcgi
with apache.
Whenever I go to http://cfp.haxogreen.lu/submission/login, it redirects
me back to http://cfp.haxogreen.lu/submission

Also, if you go to http://cfp.haxogreen.lu/submission, you'll find that
no conference is listed, even though I have one defined and in the
submission phase.

Here's the production log: (apache error log not showing up any error

Processing SubmissionController#index (for 178.254.102.*** at 2012-01-31
22:06:10) [GET]
  Parameters: {"action"=>"index", "conference"=>"login",
Redirected to http://cfp.haxogreen.lu/submission
Filter chain halted as [:init] rendered_or_redirected.
Completed in 4ms | 302 Found [http://cfp.haxogreen.lu/submission/login]

Processing SubmissionController#index (for 178.254.102.*** at 2012-01-31
22:06:10) [GET]
(Continue reading)

David Raison | 31 Jan 22:14 2012

Fastcgi trouble with status headers in application_controller.rb

Here's number two.

I had trouble getting the http-authentication to work with fastcgi since
it seems to be very picky when it comes to headers.

I had to comment line 36 in application_controller.rb in order to not
have it complain:

[Tue Jan 31 21:37:14 2012] [error] [client 178.254.102.***] FastCGI:
comm with server
"/var/www/haxogreen.lu/pentabarf/rails/public/dispatch.fcgi" aborted:
error parsing headers: duplicate header 'Status'

So in the end, my transaction_wrapper now looks like this:

def transaction_wrapper
    response.content_type ||= Mime::HTML
    Momomoto::Database.instance.transaction do
      if auth
        # if auth succeeds we continue
      elsif not performed? then
        # if auth failed and nothing has been rendered we return 401
        #response.headers["Status"] = "Unauthorized"
        response.headers["WWW-Authenticate"] = "Basic realm=Pentabarf"
:file=>'auth_failed.rxml',:status=>401,:content_type=>'text/html' )
(Continue reading)