On Sun, Dec 11, 2011 at 1:16 AM, Cleverlemming <cleverlemming / gmail.com> wr=
ote:
> Hail Caesars!
>
> I'm wondering why the instance variable "@spree_invoice_number" is out
> of scope in both the authorize and the create_transaction methods in
> the appended code. Both of the aforementioned methods are called after
> the create_profile method, where the instance variable is
> initialized. =A0I checked to make sure the instance variable name is
> unique in both the application and the gem repository.
>
> Thanks in advance for any suggestions!

Can you show the caller code? From your description and the code,
everything looks good.
Can you try with a simpler version of your class:

class Gateway::AuthorizeNetCim < Gateway
  attr_accessor :spree_invoice_number

  def authorize(amount, creditcard, gateway_options)
    logger.debug("variable is: #{@spree_invoice_number}")
  end

  def create_profile payment
    @spree_invoice_number =3D 42
  end
end

Jesus.