New OS, more pane! (Passenger preference pane v1.3)

Eloy Duran, 02 Sep 2009, 17:20 in ruby on rails, tools, releases, os x, and rubycocoa, last updated 02 Sep 2009, 18:16 (edit).

As Snow Leopard was released, I saw lots of talk on the interwebs about the Passenger preference pane not working on the new kitten OS. Which frankly was to be expected, but unfortunately Apple had not supplied me with a developer seed. Maybe next time…

Oh by the way, fun fact! What I did find is that NOT having your application up-to-date for a new OS release is actually pretty good marketing stuff. The Passenger preference pane had about 380 watchers for a while, but during the last few days we (finally) reached 400 watchers! Thanks a lot guys! Can’t wait for the next OS upgrade so we can beat Passenger with their 776 watchers ;-).

Now where was I… Ah yes.

The pain involved in the update:

So in order to help everybody out as soon as possible, I’ve created a version which will work on both PPC and Intel machines, as well as OS X 10.5 and 10.6. This means that it will want to load System Preferences.app in 32-bit mode. But since many preference panes currently need that, we didn’t deem it a show stopper.

The real problem in getting the Passenger preference pane to run in 64-bit mode would be that System Preferences.app wants to use the Objective-C garbage collector. And rightfully so. But the only way to support this easily would be to use MacRuby, which as of yet is not stable enough. But expect the next version of the preference pane to use MacRuby and be a happy 10.6 citizen.

One last note: Apple Help in a preference pane, ugh. As ironic as it may sound, there’s not much help out there, either in the form of documentation or on how to debug it. Expect a separate post on this.

Change goodies:

  • Mac OS X 10.6 support, although still in 32-bit mode:
    • Bundle RubyCocoa.framework in the preference pane. (Ticket #2 & #8)
    • Made the Apple Help work on both 10.5 and 10.6.
  • Added a check at launch, which verifies if all your application hostnames are registered in the hosts database (Directory Services). If not, add them. Obviously this is especially handy for people upgrading from 10.5 to 10.6, but also comes in handy when editing vhosts by hand.
  • Added preference pane Info.plist keys so the help shows up in the Help menu.
  • Use proper capitalization for the Apache conf ”Directory” directive.
  • When the user changes the path to an application, also replace this in the @user_defined_data string. (Ticket #4)
  • Various source cleanups.

Most users probably want to download the “stable” 1.3 release.

If you’ve added your hostnames to /etc/hosts in the meantime, then you can safely remove those again as the preference pane will add these to the hosts database on startup.

If you understand why stable has been quoted, you can track development and contribute on: http://github.com/alloy/passengerpane.

Please report any bugs you may find at: http://github.com/alloy/passengerpane/issues.

Comments

  1. Graeme Mathieson about 1 hour later: (delete)

    You rock, thank you! I've been missing my Passenger Prefpane while I've been messing with the developer build of Snow Leopard.

    Of course, next time, you could always ask a company who is a member of ADC to "employ" you to make sure it works. I believe that, as an employee, you'd get access to their developer seeds... :)

  2. Dr Nic about 4 hours later: (delete)

    Not sure if you mentioned it, but does this fix any issues it had with RubyCocoa 1.0.0 on Leopard? I downgraded RC to 0.13.2 and it started working again (v1.2)

  3. Manfred Stienstra about 4 hours later: (delete)

    Nic, the Pane bundles it's own RubyCocoa right now so we can reliably run on multiple architectures, you shouldn't have any conflicts or problems with the version installed on your computer any more.

  4. Dr+Nic about 4 hours later: (delete)

    Awesome, thanks!

  5. Tim Riley about 9 hours later: (delete)

    Nice work, Eloy & team. Thanks for the update!

  6. shane about 10 hours later: (delete)

    Thanks Eloy! What is the "passenger_pane_config.rb.ports" file in the bundle for? I'm asking because this update didn't fix prefpane for me...

  7. Manfred Stienstra about 15 hours later: (delete)

    Shane, the passenger_pane_config.rb is explained in README.rdoc. If you have problems with running the Pane, please gather logging information from the Console and post a ticket to http://github.com/alloy/passengerpane/issues.

  8. shane about 16 hours later: (delete)

    Manfred, yeah that portion of the readme didn't make sense to me. Maybe because I figured if that ...rb.ports file belonged inside Passenger.prefPane/Contents/Resources/ wouldn't it already be there? Am I missing something?

    Anyway I put that file inside Passenger.prefPane and it's still not working. What terminal command should I run to check the error log?

  9. Eloy Duran about 17 hours later: (delete)

    Shane, you can use /Applications/Utilities/Console.app to check the console messages. The ...rb.ports file is if you use Apache from MacPorts, that's why it's not inside the prefpane bundle, because the one inside the bundle by default uses the Apple supplied Apache.

  10. Manfred Stienstra about 17 hours later: (delete)

    Shane, you should only more passenger_pane_config.rb.ports if you've installed Apache 2 by hand. If you're using the default Apache 2 that comes with Mac OS you don't have to do anything.

    Please start Console.app, you can find it in /Applications/Utilities. After that search for Passenger. You can copy-paste any relevant lines from Console.

    Please open a ticket for further discussion, I don't want to turn the comments into a support forum (;

  11. brookr 1 day later: (delete)

    THANK YOU!

  12. Charlie 1 day later: (delete)

    Thanks for the documentation.

  13. Jan-Willem 1 day later: (delete)

    Tnx for the update!

  14. mm 2 days later: (delete)

    THANK YOU!

  15. Joost Schuur 5 days later: (delete | show email)

    I can't seem to get 1.3 to install under Snow Leopard. I get a 'Could not load Passenger preference pane.' error in the System Preferences and 'principalClass is nil' logged to the console.

    Details in the bug report here: http://github.com/alloy/passengerpane/issues#issue/12

  16. Adam 6 days later: (delete)

    You are awesome, thanks!

  17. Christophe Porteneuve 11 days later: (delete | show email)

    OK, so my 1.2 Pref Pane actually worked (although it forced a 32-bit SysPrefs reload), but since I tried to install 1.3 it won't, and replacing it (or deleting it + reinstalling) 1.2 doesn't work anymore.

    So in trying to install the "compatible" version I killed my pref pane, which used to work despite being on Snow Leopard.

    Argh!

    The console has 2 lines on every attempt to load:

    14/09/2009 12:49:49 [0x0-0x9d09d].com.apple.systempreferences 2009-09-14 12:49:49.206 System Preferences[9199:903] -[PassengerLoader initWithBundle:]: unrecognized selector sent to instance 0x26d8d0
    14/09/2009 12:49:49 [0x0-0x9d09d].com.apple.systempreferences 2009-09-14 12:49:49.206 System Preferences[9199:903] [NSPrefPaneBundle instantiatePrefPaneObject] (/Library/PreferencePanes/Passenger.prefPane): error occurred during instantiation.

    This happens for both the 1.2 and 1.3 versions.

    Help!

  18. Julien Palmas 29 days later: (delete)

    Hi guys, and thx for the good work !

    Is passenger pref pane scheduled to be working with NGinx anytime soon ?

    I like running the same web server on my dev box and on my production server, and I heavily use NGinx ;-)

  19. Manfred Stienstra 29 days later: (delete)

    No, we're not going to work on nginx support. If anyone wants to contribute nginx support we will consider including it.

  20. Jeff Schoolcraft 60 days later: (delete | show email)

    I'm trying to get v1.3 to work on 10.5.6 but I'm having some issues, http://pastebin.com/m1627fd36

    I'm using ruby 1.8.7 from MacPorts and I installed RubyCocoa 1.0.1 from source using macport ruby.

  21. Manfred Stienstra 60 days later: (delete)

    Jeff, can you post the problem as a ticket to GitHub?

  22. Jeff Schoolcraft 60 days later: (delete | show email)

    Seems reinstalling the pref pane after I build RubyCocoa solved my issues.

  23. Steve 85 days later: (delete | show email)

    Snow Leopard + Passenger prefPane FAIL. Any help would be greatly appreciated.

    http://github.com/alloy/passengerpane/issues/#issue/28

  24. Steve 85 days later: (delete | show email)

    OK I feel sheepish. Forgot to restart Apache by ticking and unticking "Web Sharing". :*)

Add your comment

In order to fight spam on this blog, posting comments from a browser without javascript is currently not supported.