Pivotal Labs

Main menu

Skip to primary content
Skip to secondary content
  • About
  • Case Studies
  • Team
    • Executives
    • Locations
      • San Francisco (HQ)
      • Boston
      • Boulder
      • Denver
      • London
      • Los Angeles
      • New York
  • Community
    • Blogs
    • Tech Talks
    • Events
  • Careers
    • Lifestyle
    • Principles & Practices
    • Benefits
    • FAQ
    • Apply
  • Tools
  • Contact
    • Press Room
    • Press Releases
    • In The News
    • Press Kit
  • All
  • Labs
  • Standup
  • Tracker

Standup 3/31/2011: Process.spawn pwns all yer codez!

David Goudreau
Thursday, March 31, 2011

Interestings

Get your Rails mentoring on at RailsBridge this April 8th & 9th @ the Modcloth offices in downtown SF. It’s very rewarding.

If you have nested_attributes updating an attribute that is NOT in your attr_accessible attribute list on your ActiveRecord model you won’t get an exception – it will just silently fail. It will, however, output a warning line to your Rails log file. Fun for the whole family.

Using popen to open a process actually calls ‘sh -c’ to open your process, so the process you just ran is actually the child of the ‘sh -c’ process you just ran. This makes tracking down PIDs simply wonderful. :-) You can use ‘exec’ instead and your process will be the parent process. But if you’re using the new hotness you can instead use Process.spawn in Ruby 1.9.

  • 0 Shares
  • Share on Facebook
  • Share on Twitter

One comment

  1. Jack Dempsey says:

    I’ve been bit by attr_accessible quietly failing too many times. Any thoughts on patching it to allow for a setting to tell it to raise?

    March 31, 2011 at 2:06 pm

Add New Comment Cancel reply

Your email address will not be published.

David Goudreau

David Goudreau
San Francisco

Recent Posts

  • Standup 4/1/2011: April Fool's edition
  • Standup 3/29/2011: Git it!
  • Standup 7/1/10 – Caching Apache images that have ?123456789
Subscribe to David's Feed

Author Topics

agile (14)
  • About
  • Case Studies
  • Team
  • Community
  • Careers
  • Tools
  • Contact
  • Labs
  • Events

Contact Us

contact@pivotallabs.com
+1 415-77-PIVOT
TwitterLinkedInFacebook

Pivotal Tracker

Tracker is the award-winning agile project management tool that enables real-time collaboration around a shared, prioritized backlog.
Visit pivotaltracker.com >