« first day (1391 days earlier)      last day (3558 days later) » 

11:00 PM
@DaveRandom What's that?
 
sorry Mosho said it I didn't think it's offensive if he's using it having in mind he's been here longer
@SufiDeveloper haji, why don't you check your hangouts
 
Well IMO that's just never acceptable in any situation anywhere from anyone on the internet because it's just too weighted
 
ok I shall now from now on, you are free do delete it if you can and suspend me
I accept my punishment
 
@ziGi Doing it. Thought Google notified me if you someone sent a message on hangouts
 
I wish it weren't that way but it kind of is
 
11:03 PM
@ziGi @Mosho was quoting the movie from the previous image.
 
I was quoting Last Real N**ga Alive
what can I do that people make songs like those
 
how was that relevant to the conversation
 
@ziGi I don't have the power and I wouldn't even if I did, because everyone gets fair warning, only repeat/serial offenders need actual retribution
 
What about accepting apologies and have a normal conversation friends? It's late and we're highly susceptible to stress. Just sayin.
 
^
Thank you Sufi
 
11:06 PM
anyone here use mongoose
null and null
for doc and err
i also have an app.js but the prev file is where the issue is
 
Welcome bro
 
@SufiDeveloper +1
 
@tejas-manohar I have
 
11:07 PM
thats app.js
@ziGi would you take a look?
 
I am
 
routes.js (probably issue) - pastebin.com/8xPaQKhB
app.js (mostly just setting up stuff) - pastebin.com/UBg8nVdF
 
which line gives you the error
when you debug
 
no errors
just null and null
for doc and err
in the console.log
 
if you install
some IDE that supports node debugging it'd be easier like this I can't tell you anything
cause I'm a bit tired to do mind compilation
 
11:12 PM
@ziGi are you able to clone locally if i give you a git repo
right now
?
 
@tejas-manohar Zigi is suspended and can't chat for 30 minutes
 
@copy
 
@roger
 
@KendallFrey
 
@HoneyBadger
 
Ell
11:18 PM
What did zigi do?
 
Said "nigga"
 
why
oh
wow
thats terrible
like actually terrible
has anyone else worked with mongoose
 
What can I say.
 
Ell
That does not warrant suspension o.O
Imho that doesn't even warrant apology
 
Yes it does
Though ziGi is my only hope, thats terrible
 
Ell
11:20 PM
I don't think either of us will change each others minds so let's not go into it I guess
 
how is your debugging going?
I wasn't around for the context, but it very well could warrant apology.
 
Luggage: my debugging is not progressing opsitively
im trying and trying
used node debugger
its a logicalerror not a syntax one
 
right, but if you log each step and make sure you have the right result, then..
 
i dont
i know where the issue is
 
@tejas-manohar Yeah, I'd try more "console.log" debugging than messing around with the debugger
 
11:23 PM
its right at that spot
maybe my schemnas arent exposed?
 
That can be tested by console.log(), too. Link me your code again, please.
you should have gotten and eror when you did your .findOne() if the model wasn't setup.
 
then i didnt
i console logged the err
and the model exists
i see it in mongohub
 
linky linky linky
 
11:27 PM
github
i forgot your account name
i want to run your code and try it myself.
@Loktar Are you a jQuery hater / lover / other?
 
A bit of a hater
more so when idiots are using it
not jQueries fault as much as people
 
Hm. I recommend it to people. I like that I can use css3 selectors without worrying about what the browser supports natively.
 
I really love the jquery API
but if I'm honest, I only really use it for prototyping
 
Generally only use it to set classes and find elements. I don't alter the dom much. I use templates for that.
 
then why do you even use jquery?
are you supporting IE8?
 
11:31 PM
no
 
For pretty much anything jQuery does, there's a smaller tool that does it better.
 
Well.. yes, in some projects
 
@Retsam exactly
@Luggage querySelector/all.
 
it's ofetn a pre-req. I use bootstrap, too, which uses it
Like I said, don't have to worry about what querySelector can support in the user's browser. Are you seying querySelector is very well supported after EI 8?
 
Like, for example, $.Deferred() is an abomination against man.
 
11:34 PM
In my latest project, I barely touch it. It's just there for bootstrap. I do all my dom manipulation thorugh knockout.js
Which, I assume someone will tell me is also horrible. :)
 
@Luggage yeah its supported in everything after 8
 
all the selectors that jquery supports are?
though, really, i'm not that demanding.. not sure why I care.
i use selectors that are pretty basic.
 
Ell
I use jQuery to select stuff quickly
And animation
 
shudders
 
@tejas-manohar I'm willing to run your app myself and debug it with you. Give me a link to the code. Loosing interest.
 
11:36 PM
jQuery animation is terrible
 
It's always worked and I haven't had performance problems. I just don't have motivation to change. there are more intersting part of my project than if my selctor is the those optimum.
 
Ell
I've never tried anything else
 
I guess thats the difference
 
But I don't need it. I know how to do things without any abstraction layer at all.
 
its just about knowing when and why you need it honestly
 
11:38 PM
It's just familiar and gets the job done so I can move on.
Anywho..
it's AJAX api is kinda inconsistent. i really like superagent's.
I still use jquery for all the reasons mentioned.. and my calls are all organized such that i could swap out jquery for something else with fairly minimal effort..
corrected above to "ajax"
Do you have any routing libraries you really like?
 
javascript data type checking
possible?
 
That's a big question.
 
i want to pass an array of strings and i'm looking for ideas as to how to make a good estimate of the data type of the elements
 
Easy. It's an array of strings.
 
Ah
yeah
 
11:44 PM
lol
 
:)
 
let me rephrase
user uploads csv i want to take a stab at the data type for a specific column. ideas?
 
@hanleyhansen Everything is possible
You just have to believe
 
i believe @copy i believe
 
@copy ... for a price
 
11:45 PM
I have to rename myself to believe
 
Good for you, Chris Hanson
 
Very different question.
 
!!define luggage
 
@SufiDeveloper [luggage](http://en.wiktionary.org/wiki?curid=38129) The bags and other containers that hold a traveller's belongings.
Jonathan Swift
I am gathering up my luggage, and preparing for my journey.
 
#lolflags
 
11:47 PM
You'll just have to sample some rows adn try to guess. e.g., "The first 8 rows were all integers, i guess it's a number column.
 
switch statement and typeof?
 
since it's a csv, you'll be working with strings until you start structuring the data
in other words, typeof will be useless.
 
@hanleyhansen What do you need the type for?
 
I suggest just finding a library to parse CSV for you.
so you don't have to deal with commas inside strings and all that jazz.
unless this is an educational experiment and you want to do it youself. It's a 'solved problem' most likely.
 
@DaveRandom flag for someone < 10K == suspension flags fro > 10K the lol, nice
 
11:49 PM
@copy the user will get to select the type but UX thinks we should make an educated guess
 
Ell
@hanleyhansen it's probably only going to be primitives, right?
No uploading 2d arrays or whatwhat
 
definitely @eli
 
@hanleyhansen Oh
 
just primitives
 
@ziGi I didn't flag yours either, the whole reason I came to talk to you was to find out if you were being an asshole or just typing without thinking
 
11:50 PM
second one
 
@hanleyhansen Yeah, making a guess is reasonable, unless it's too hard or error-prone
 
I know, so I didn't validate your flag
 
good I just wanted to make a point
thank you :)
 
Ell
Well, if it's just primitives it isn't many things it can be
basically integer, real, string, date/time
 
test in the order of most specific format to least (i.e. strings are last)
 
11:52 PM
@copy the user will get to change it so i'm not too worried. i guess this was educational as well. i spend most of my day in python so i was looking for some suggestions
@Luggage (like)
@Ell maybe bools too?
 
Ell
@hanleyhansen Yeah that too likely
 
Well, tools like Excel will sample a number of rows. If all the items parse as a valid integer, then it's an integer, etc.
 
i wonder how typeof is implemented
 
it's internal. javascript has types internally.
 
It doesn't parse strings :)
 
11:54 PM
you'll have strings.
 
(typeof "42" === 'string')
 
typeof will always === 'string'
 
What you really should be curious about is how JS primitives are parsed
For example, if it starts with a " or ', it's a string
 
that's great but they'll all be strings
 
If it starts with a digit or ., it's a number
@hanleyhansen Yeah, you'll need to adapt
But it shouldn't be too hard
Tell me what kind of data 15 is
 
11:56 PM
List all the types you need to support. Come up with a 'test' for each one. Then, for your sample rows check "do all the rows validate as the first type? no? try the second.
your test could be an attmept to parse, a regex, etc.
 
i like that waterfall idea. how's this sound as far as order? bool, date/time, real, integer, string
 
regex is probably a good solution
 
at first glance, seems like a good order.
 
The first 3 are mutually exclusive, so it shouldn't be terribly important
 
11:59 PM
date/time regex will be a pain
 
@hanleyhansen Number("42") == "42"
 
depends how fancy you want to get
 
true. i can just say "whoops, guess i was wrong" and call it a day
 
(that's the PHP way, which has basically the same problem)
 

« first day (1391 days earlier)      last day (3558 days later) »