Hi Bernard!

One more tip here is the DRYML extension 
(https://github.com/ddnexus/dryml-firemarker)  for the Firefox Firebug 
debugger (https://addons.mozilla.org/de/firefox/addon/firebug/): 

It helped me here to get in the right track of thinking, because I was not 
sure, if I was in the name-one hobo-bootstrap-ui case or the name-one 
hobo_jquery-ui as I have enabled both.
A short look in the DRYML markers and I knew the full tag hierarchy that 
created my HTML (it was hobo-bootstrap-ui ).
Then I saw, that there was no real code change in the hobo-bootstrap-ui Gem 
for months and that put my focus back to the server. Getting data at all 
does not mean getting the right data...

A second step, that helped me was getting out for some hours to reset my 
brain.
When I saw the issue in the beginning, it was a big kickback. Working on an 
app tor meanwhile 9 months and suddenly one important feature is broken, 
that causes frustration.
The name-one autocompletion is really an awesome feature of hobo, I really 
missed it yesterday.

I see you calling yourself a "beginner" again. We are always beginners, I 
am using active_model_serializers now for about three weeks. That's how 
programming is, if you want to improve your
portfolio and your skill set. But I think that is also the interesting 
part, to get new stuff to try out every day.

Before I annoy you, one last tip. I tend to write debugging info these days 
in an extra logfile using a small class I created:

class JobLogger

  def self.info(message)
    @joblogger ||= Logger.new("#{Rails.root}/log/#{Rails.env}_jobs.log")
    @joblogger.ap(message, :info) unless message.nil?
  end

 

# similar methods for warn, error, fatal, debug

end


so using statements like 
    JobLogger.debug("This is my debug message")
writes a nice message with timestamp and process id to the log.

Now the awesome part: There is this gem awesome-print that can format 
objects nicely and color them. Putting it in the gemfile and bundling 
provides the ap method I already used above.
 e.g. JobLogger.debug(User.first.address.first) gives not only output, it 
is nicely formatted and colored! (this is my company's public address, no 
worries)

<https://lh4.googleusercontent.com/-ZJlsIgIp20g/U9owv8YaI4I/AAAAAAAAAUk/DTo8OwKnvV8/s1600/address.png>

I know about awesome_print for three days, so "absolute beginner" here.

Ciao,
Stefan

-- 
You received this message because you are subscribed to the Google Groups "Hobo 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/hobousers.
For more options, visit https://groups.google.com/d/optout.

Reply via email to