# Payment Gem error

**URL:** <https://www.ruby-forum.com/t/payment-gem-error/61207>\
**Category:** Ruby\
**Created:** [May 21, 2006, 7:15pm UTC](https://www.ruby-forum.com/t/payment-gem-error/61207 "2006-05-21T19:15:50Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Robert\_MannI](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/ac91a4/32.png) [@Robert\_MannI](https://www.ruby-forum.com/u/Robert_MannI)\
**Post date:** [May 21, 2006, 7:15pm UTC](https://www.ruby-forum.com/t/payment-gem-error/61207/1 "2006-05-21T19:15:50Z")

</div>

Hi!

I’m getting this error when trying to initialize Payment::AuthorizeNet

couldn’t find HOME environment – expanding `~/.payment.yml' /usr/local/lib/ruby/gems/1.8/gems/payment- 1.0.1/lib/payment/base.rb:21:in`expand\_path’

Any ideas what this could be?

The payment source code that throws the error is:

prefs = File.expand\_path(options[:prefs] || “~/.payment.yml”)

Executing File.expand\_path("~/.payment.yml") in IRB works fine.

Any ideas? Thank alot…

Rob

---

<div class="post-metadata">

**Author:** ![Robert\_MannI](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/ac91a4/32.png) [@Robert\_MannI](https://www.ruby-forum.com/u/Robert_MannI)\
**Post date:** [May 22, 2006, 4:03pm UTC](https://www.ruby-forum.com/t/payment-gem-error/61207/2 "2006-05-22T16:03:53Z")

</div>

On 5/21/06, Robert MannI [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> The payment source code that throws the error is:
> 
> prefs = File.expand\_path(options[:prefs] || “~/.payment.yml”)
> 
> Executing File.expand\_path(“~/.payment.yml”) in IRB works fine.

Try using a full path name (like “/home/username/.payment.yml”),  
rather than something with a tilde (~).

-A
