Ruby on Rails Wednesday, October 1, 2014

Debug the code directly using debugger, binding or pry.

try this (assuming thing is your variable)

thing.save

You should see a message "false" telling you that the object wasn't saved

then type

thing.errors

and you should see what the validation errors are
-Jason




On Sep 30, 2014, at 9:16 PM, Jan Yo <lists@ruby-forum.com> wrote:

> I do a create on an Active Record model in a controller and it's doing
> something strange. It's primary key (id) is nil, created/updated are
> nil as well.
>
> A few of the columns/attributes are nil as well. The model instance
> gets created but the id is nil.
>
> Rspec fails for the model because its id is nil (because it's being
> passed to other models)
>
> Any ideas?

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/1A5D5920-B83A-4D96-A150-9727491AA09F%40datatravels.com.
For more options, visit https://groups.google.com/d/optout.

Ruby on Rails

We've used pusher.com in production for 2+ years with no issues. Pubnub is an option as well, but their packet size restrictions were/are(?) too small for us. Both have clean APIs, need no extra stuff (e.g. Redis), give nice stats, etc. Looking at ActionController::Live, the main diff seems to be whether you maintain and scale the functionality or someone else does it for you through a simple API and $20/month.

-Chris

On Tuesday, September 30, 2014 9:54:26 AM UTC-7, Ruby-Forum.com User wrote:
I'm starting a new Rails project probably using 4.1 or 4.2.  The project
needs the ability for user's browsers to get updates via push
notifications.  I know that Rails 4 kinda sorta added that but the last
time I looked it was shaky.

To sketch out what I'd like: suppose a user is looking at a page.
Think of it as a user looking at a history of activity for a project.
Another users does an update.  I want the first user's browser to get
the new update.  I don't think will work in this situation so I'm
looking for the server to push the updates out.

What is the current technology?  Does Rails 4.1 or 4.2 have everything
it needs or do I still need some add on gems?  If so which ones?  If
Rails is complete, what are some areas of the Rails documentation to
review?

Thank you for your time,
pedz

--
Posted via http://www.ruby-forum.com/.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/feeaee37-aafd-4558-ab9a-022e3dff5da3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Ruby on Rails

Let me know if you need any help
Ive beem playing w the html5 audio video stuffs and also have qtss and icecast2 servers setup

On 30 September, 2014 10:32:53 PM PDT, Sai Ch <lists@ruby-forum.com> wrote:
Finally man after long time one person reply for this question.

Thanks @Clayton for your suggestion.I want to try in my app.

--
Sent from my Android