Some things to try:
-
Restart the rails console; changes to your models will only get picked up by a rails console that is already open if you do
> reload!
(although I have found this to be unpredictable), or by restarting the console. -
Is your model file called “phone_number.rb” and is it in “/app/models”?
-
You should double-check the “–sandbox” option on your rails console command. AFAIK, this prevents changes. Try it without the switch.