« first day (1382 days earlier)      last day (1873 days later) » 

 
7 hours later…
11:05 AM
in windows & php even like 15 years ago they had built in templates for mm:dd:yy:hh:mm:ss versus any other ... way is rails so far behind in this area?
 
11:17 AM
huh? mm:dd:yy:hh:mm:ss is clearly the wrong default no matter how you spin it.
 
I'm quoting off the top of my head from almost 20 years ago, regardless of syntex, there's an extremely simple process for templating a date/timestamp baked into codebase
 
Every language I've ever used gets you to format it yourself
 
11:32 AM
Hehehe Cereal...we've already kind of established you're quite the Sinatra masochist, but regardless, I'm pointing out that in two languages I worked with almost 20 years ago they were sufficiently advanced as to not need pearl style regex in order to format a timestamp
 
No, I meant every language I've used
So, C#, ruby, python, lua, java, c, c++, AS3, js..
 
c++ has a format handler built in since 1998
 
Yeah, you format it yourself
 
You are ignoring some key words which change the scope of the issue from a globally documented 30 second look up - which everyone in the world can use, to hand crafting a solution ... chat.stackoverflow.com/transcript/message/39710082#39710082 ... "without regex", ... chat.stackoverflow.com/transcript/message/39710000#39710000 ... "template"
 
They all spit something out
It's almost never reasonable
 
11:37 AM
idk...it's never something I've ever heard anyone looking up solutions too before rails
 
So you're saying ruby doesn't have a date string format?
 
my lua programming was just modding someone else's stuff though
 
I guess I don't understand what you're complaining about
 
I'm not sure how to express it in a different way ... "why is rails (closer to) 20 years behind MS on timestamp format handling"
 
Can you give me an example
 
11:39 AM
read upwards in this chat... i've never had go online for a solution for timestamps in php/c++/visual basic, there's a clearly documented template for sticking your serialized timestamp into to get the pretty output, reversing it etc...there is no such thing as "regex" solutions required (unless you fail to open the documention sent with visual studio)
 
Time.now.strftime("%Y-%m-%dT%H:%M:%SZ")
There's your template
 
there we go!
 
That had nothing to do with rails, so I was confused
 
(i don't make solid statements on ruby, don't know it very well only two books in on it so i hestitate to make sweeps on it)
I really do need to finish more books, but it's impossible to read & follow along code examples at work ... then at home there's so much to get done & I never seem to devote time to it
 
I find doing more helpful than reading
 
11:47 AM
yea, I gave up on straight reading my poodr, pheonix in a bottle & basic emberjs straight up except when traveling ... I just never retain it ... if I had the pdf for design patterns I would have done those though
 
I hated my design patterns book
They're not very applicable for languages like ruby
 
maybe that's why i only hear about singleton & like 3 others if that many
 
If you do a project in java, you'll run into way more
because a lot of the design patterns are patterns to get around the constraints of a statically typed language
 
hi Meagar
yea - i bet...never liked java, but forcing myself to use JS & not complain about it...now jquery, jquery is the bee's knees!
 
You know javascript and java are unrelated right
 
12:02 PM
shrug....I've read about 50 pages on the differences & inspiration by the author of JS
 
Is that a yes or a no
 
let me rephrase this .... they are not unrelated according to the guy who wrote javascript in less than 2 days, but he also said they are not the same
 
They're not related
 
shrug, you ever seen the story about the guy who tried to explain how indiana jones costumes were inspired - to the woman who designed them? sorry mate, the literal maker of javascript has written lots on the topic, how embarassing it is that we still used it & how it was kind of a betrayal & if he had known the he never would have turned it etc... you can go argue with the maker of the language if you want
(i've got stuff to do today)
 
12:19 PM
That doesn't change the fact that they're not related, the only thing js has in common with java is curly braces
 
have a great morning cereal!
 
:|
 
1:16 PM
Morning all
 
1:46 PM
Morning
 
1:59 PM
Javascript is still closer to Java than to Ruby
 
true
 
hi guys, yea - cereal has always provided awesome insight & killed the questions he answers, I also really appreciate the insight on design patterns related to the other languages - its just I need a job & an academic debate or just breaking down the communication barrier based on both of our different experiences (or my lack of knowledge or how people explain in different crowds) isn't something I can really afford to engage in - so if I haven't said it today, Thank you Cereal!
 
2:26 PM
@Mirv ts.to_s(:db)
Good morning, all.
 
2:50 PM
Almond butter + bread + bananas + milk = Complete satisfaction.
 
Are the first three combined after putting the bread through a toaster? ;)
 
I wanted cereal for breakfast but forgot to eat, so I had to eat McDonalds on the way to work.
 
Nothing in the toaster! All fresh and soft
 
@qaispak You just mix them together?
 
Something about hot peanut butter is so awesome to me
 
2:52 PM
Mcdonalds egg Mcmuffin + coffee is delightful
 
I had oatmeal brown bread with avocado margarine for breakfast
 
I make an almond butter + banana sandwhich
and wash it down with some milk.
@Cereal sounds like a pre yoga to me haha
 
I was picturing a kind of bread pudding, heh.
 
oh that would be neat!
 
Hm, chat is lagging and firefox is using 28% of my cpu
 
2:53 PM
go chrome :D
 
I was using chrome, just trying out this new firefox build
The quantum engine or whatever it's called
 
btw, I've heard IE isn't bad anymore
is that true?
 
Edge is fine
 
I'll bet the naming committee spent a bit of time naming Edge. They had to make sure that if it went bad, we wouldn't find a good rhyme for it like we did with Internet Exploder.
 
all I could think of was dread.
 
3:02 PM
The committee did its job well.
 
3:42 PM
do you think they use other clever names like, "The Public Safety Committee" ala 'Les Miserables' when referring to themselves?
side note... For rails console ... just found out I could call app.helpers & app.{method} {uri} (which calls the URI in question w/whatever method) ... in addition to previously learned trick of app.{route} (which tells what URI a route helper resolves into) ... super helpful when i'm getting mysterious test errors
From a question on auth'ing users from the rails console - stackoverflow.com/questions/4929078/…
 
4:39 PM
In Rails ... Has anyone ever seen a rails destroy/delete fail - but the controller still reports success? I'm looking thru all my projects & I made a test app, rails scaffolding doesn't generate a check to see if destroy succeeds in the same way they do for if saving does.... IE: if @someVar.save versus @someVar.destroy
 
Well if its a default destroy action it will always return with a success unless you've changed it.
 
modifying a gem to not raise an error when something happens just to suit my current implementation of a code is not monkey patching is it?
 
But you can try and debug it with thing.destroy; thing.errors
 
haven't, that I know of ... there's no dependent destroys or callbacks I know of but getting a method setup to test that
weird, so it works via console, but not test or manually from website...ty!
 
Good luck, sounds like a fun issue to track down
 
4:44 PM
@qaispak make sure you fork it and reference that, otherwise it'll break if you update the gem and you'll be really confused
 
^ this.
 
fork the gem you mean?
 
could you just try/catch the error instead of modifying the code?
 
Yeah. Fork the gem, make the mods to your fork, and point your Gemfile to the fork.
 
and then include my own fork/
my forked copy*
oh
okay
The error shouldn't be raised at all. I don't get it.
what it is checking for isn't too important for my needs anyway
 
5:07 PM
This is what I came up with .... the only association it might be fighting ... 2.3.1 :028 > ary = Dash.reflect_on_all_associations.select { |a| a.options[:dependent] == :destroy }.map(&:name)
Unfortunately since it only fails on the website or in test, having trouble spitting out the errors with your suggestion jared....i've been trying `puts "\n Destroy/Delete error -- #{@dash}\n" based on ...
  test "should destroy dash" do
    puts "#{Dash.count}"
    assert_difference('Dash.count', -1) do
      delete dash_url(@dash)
    end
    assert_redirected_to dashes_url
  end
(it's after the delete dash_url i use the puts)
 
What's a sidebar that shows functions/variables called in an ide
Like, it'd list the functions, and you can click on them to navigate around
 
In rubymine its the Structure tab
 
That sounds about right
Trying to find if I can add something like that to vs code for cobol files
 
OpenCobolIDE has a Navigation Pane
 
Yeah, but it only supports the gnucobol compiler
We use acucobol here
the editor's actually really nice, but being able to compile and add to library in one press in vs code is too good to pass up
 
5:19 PM
Pretty sure those are kinds of Pokemon
 
If it would just let me add an arbitrary command to run, it would be perfect
but it forces gnucobol
 
Is there any way to message someone on github?
 
@<name> in comments ... I believe if you have a bug, the best procedure is to check their readme file to see what forum they use (by default you can open an issues list on the repo & it will auto notify them)
 
I see this old gem he hasn't updated in 2 years but I have small fix for an issue
hmm
 
I'd just file the issue and how to repliate and see if anyone responds
 
5:31 PM
It just never ends, 3rd bike crash this year, this one was fatal. The husband of coworker, 4 kids left behind with her :(
 
Still no explanation on the mysterious failures to destroy/delete .... I even copied the update's version of error checking...

    respond_to do |format|
      if @dash.destroy!
        format.html { redirect_to dashes_url, notice: 'Dash was successfully destroyed.' }
        format.json { head :no_content }
      else
        format.html { redirect_to dashes_url, notice: 'Dash failed to be destroyed.' }
        format.json { head :no_content }
      end
    end
format.html { redirect_to dashes_url, notice: "Dash was successfully destroyed. #{@dash.errors}, #{@dash.errors.empty?}" } # This comes up errors is empty True ... so rails isn't seeing it, guess I goto test the AR relationship next by removing it....then the DB level after
 
 
2 hours later…
8:12 PM
how do you guys know what keyword to use for stuff that homebrew downloads.
like brew install whatever
sometimes it's difficult to find.
 
i usually google for homebrew install [thing i want] then hope they had it noted somewhere
 
sometimes they don't but that's what I do to
I just spend like 20 mins trying to get maven to work
then someone on stackoverflow says use homebrew
blows my mind why it wasn't on their website?
 
There is a built in search ability, but it wouldn't help tell you if you needed to search for "pg" or "postgres" or w/e else
brew search foo
 
I just use cloud9 :)
 
 
2 hours later…
10:03 PM
0
Q: rails5 - Remote form data undefined

Mohammad Areeb SiddiquiTrying to build an ajax form on rails 5. The controller action is returning a correct 200 response with correct json but ajax:success is returning with everything undefined. The form: <%= form_with url: '/search', id: 'search-list-form' do |form| %> <div class="modal-body"> <div cla...

 

« first day (1382 days earlier)      last day (1873 days later) »