Any Potion Store gurus in SF?

9 views
Skip to first unread message

sgehrman

unread,
Jan 4, 2012, 7:08:13 PM1/4/12
to Potion Store Discussions

I'm getting ready to launch my app with Potion Store. I set it all up
and it's on Heroku and it all seems to work just fine, but I'm nervous
that if something goes wrong I'll be stuck since I don't know much
about Ruby or how the code works. It would be great to have someone
verify my setup and someone I can call when there is a problem or an
update is needed.

I'll pay per hour or whatever makes sense. Email me. sgehrman at
gmail

Thanks,

-steve

Autumn Sales

unread,
Jan 8, 2012, 3:22:22 AM1/8/12
to potion...@googlegroups.com
Hey Steve,

I'm not in SF, but I've done three production Potion Stores and dozens of testing/development deployments, so I have a pretty good feel for everything.  You can contact me through my website if you want to talk further:


Regards,
Daniel


--
You received this message because you are subscribed to the Google Groups "Potion Store Discussions" group.
To post to this group, send email to potion...@googlegroups.com.
To unsubscribe from this group, send email to potion-store...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/potion-store?hl=en.


sgehrman

unread,
Jan 12, 2012, 6:20:43 PM1/12/12
to Potion Store Discussions
OK, I'll probably need help, I'm doing a bit of testing now and just
got this error:

500 error. I was trying to delete a product from the admin products
page. Is there a simple solution?

Thanks,

2012-01-12T23:08:39+00:00 app[web.1]: Processing
Admin::ProductsController#destroy (for 199.188.194.106 at 2012-01-12
15:08:39) [DELETE]
2012-01-12T23:08:39+00:00 app[web.1]: Parameters:
{"action"=>"destroy", "_method"=>"delete", "id"=>"6",
"controller"=>"admin/products"}
2012-01-12T23:08:39+00:00 app[web.1]:
2012-01-12T23:08:39+00:00 app[web.1]: ActiveRecord::StatementInvalid
(PGError: ERROR: update or delete on table "products" violates
foreign key constraint "line_items_ibfk_product_id" on table
"line_items"
2012-01-12T23:08:39+00:00 app[web.1]: DETAIL: Key (id)=(6) is still
referenced from table "line_items".
2012-01-12T23:08:39+00:00 app[web.1]: : DELETE FROM "products" WHERE
"id" = 6):
2012-01-12T23:08:39+00:00 app[web.1]: app/controllers/admin/
products_controller.rb:76:in `destroy'
2012-01-12T23:08:39+00:00 app[web.1]: /home/heroku_rack/lib/
last_access.rb:15:in `call'
2012-01-12T23:08:39+00:00 app[web.1]: /home/heroku_rack/lib/
date_header.rb:14:in `call'
2012-01-12T23:08:39+00:00 app[web.1]: /home/heroku_rack/lib/
static_assets.rb:9:in `call'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/connection.rb:76:in `pre_process'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/connection.rb:74:in `catch'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/connection.rb:74:in `pre_process'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/connection.rb:57:in `process'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:256:in `run_machine'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:256:in `run'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/connection.rb:42:in `receive_data'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/backends/base.rb:57:in `start'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/server.rb:156:in `start'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/controllers/controller.rb:80:in `start'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/runner.rb:177:in `send'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/runner.rb:177:in `run_command'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/lib/thin/runner.rb:143:in `run!'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/lib/ruby/gems/
1.8/gems/thin-1.2.6/bin/thin:6
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/bin/thin:19:in
`load'
2012-01-12T23:08:39+00:00 app[web.1]: /usr/ruby1.8.7/bin/thin:19
2012-01-12T23:08:39+00:00 app[web.1]:
2012-01-12T23:08:39+00:00 app[web.1]:
2012-01-12T23:08:39+00:00 app[web.1]: Rendering /app/public/500.html
(500 Internal Server Error)
2012-01-12T23:08:39+00:00 heroku[router]: POST store.cocoatech.com/
admin/products/6 dyno=web.1 queue=0 wait=0ms service=316ms status=500
bytes=807

Andy Kim

unread,
Jan 12, 2012, 6:56:27 PM1/12/12
to potion...@googlegroups.com
This is happening because you have orders with that product as a line item. To be able to delete that product, you'll need to delete all line item rows that reference that product from the database.

- Andy

sgehrman

unread,
Jan 12, 2012, 7:16:34 PM1/12/12
to Potion Store Discussions
that was my guess. Thanks for confirming.

-steve

sgehrman

unread,
Jan 12, 2012, 7:17:58 PM1/12/12
to Potion Store Discussions
One more question.

Is there a simple command to reset my database? I want to rebuild it
and erase everything to start from scratch.

Thanks,

-steve


On Jan 12, 3:56 pm, Andy Kim <a...@potionfactory.com> wrote:

Andy Kim

unread,
Jan 12, 2012, 7:31:52 PM1/12/12
to potion...@googlegroups.com
You could drop the database and create it again and recreate the tables using the rake db:migrate task.

If you're using pgAdmin, you could do this through a UI. If not, the sql command is "drop database <db name>"

- Andy

Reply all
Reply to author
Forward
0 new messages