title: Eager loading of deleted records with paranoia's default scope
body: <p>I'm using the <a href="https://github.com/radar/paranoia" rel="nofollow noreferrer">paranoia</a> gem to "soft-delete" records. Now I need to eager load these records, some of which might have been deleted, for an associated model. Paranoia adds this <code>default_scope</code> to the "paranoid" model:</p>
  
  <pre><code>default_scope :conditions =&gt; { :deleted_at =&gt; nil }
  </code></pre>
  
  <p>So in effect, I have these (simplified) models:</p>
  
  <pre><code>class Product
    has_many :orders
    default_scope :conditions =&gt; { :deleted_at =&gt; nil }
  end
  
  class Order
    belongs_to :product
  end
  </code></pre>
  
  <p>What I'm trying to achieve is to eager-load the products when accessing orders:</p>
  
  <pre><code>Order.includes(:product)
  </code></pre>
  
  <p>This (from <a href="https://stackoverflow.com/questions/4758145/how-to-use-unscoped-on-associated-relations-in-rails3">How to use unscoped on associated relations in Rails3?</a>) does not work here:</p>
  
  <pre><code>Product.unscoped { Order.includes(:product) }
  </code></pre>
  
  <p>I know I could create a custom <code>belongs_to</code> relationship to <em>add</em> conditions (as in <a href="https://stackoverflow.com/questions/6169828/eager-loading-nested-association-and-scope">Eager loading nested association and scope</a>), but I can't find a way to <em>remove</em> existing ones, if that's even possible.</p>
  
  <p><strong>Question:</strong> How do I prevent the default scope from being applied to the eager loading query?</p>