« first day (1751 days earlier)      last day (3187 days later) » 

10:00 PM
just ask your question, we'll see if we can respond
 
is there any http2 server in node
 
> don't ask if you can ask, just ask
 
something you can use in production ?
 
what is node.js?
a jQuery plugin, like javascript?
 
it is a server implemented in javascript
 
10:02 PM
@Neoares protip: when someone talks about production he's hopefully not screwing around, so we don't screw around with them
@user568109 he's a troll
 
production is serious business
 
@user568109 just wondering, did you try google? I see quite a few links that could be pretty useful
just try "http2 in node"
 
user365265
is the ES6 Set object ready for custom search queries ? where can i find any examples ?
 
10:05 PM
that happens to be gsoc project and not very active
wanted to know what other people use
 
why is my data not displaying?! codepen.io/Feners4/pen/EjONEe
 
@user568109 I barely see any mention of gsoc
@feners did you try a proper question on SO?
 
@towc i did, and I've been googling for like two days now trying to solve this..
 
@feners did you try breaking it down in smaller pieces to see what works and what doesn't?
 
10:10 PM
No worries found a better library github.com/indutny/node-spdy
And indutny is the author so I can trust it
 
@user568109 check the code?
 
@towc yeah, It's supposed to work.. from what I understand..
 
@feners everything? Then why does it not work in the end?
@feners A is working, B is working, A+B is not working, check whether you implemented the + correctly, if you're so sure A and B are working
 
@towc Thats my problem, I mean I believe my problem to be about jade or angular..
 
I'm sure you'll figure that out if you run the proper tests and check everything on a smaller scale
re-write it all if necessary
or try using debugger
 
10:14 PM
yea, Im just gonna rewrite this
 
make sure every value is exactly what it is supposed to be, and don't only guess it is, prove it
 
10:32 PM
@rlemon is it ok to flag non-sarcastic racist messages? Also, do they deserve a temp ban?
mosho, help us out?
 
this has to be a troll
 
@Purag I really hope
 
guys...do not feed. lol
 
!!mute mate64
 
cap's not around :/
 
10:34 PM
She still dead :(
 
wait, how does mute even work?
oh, cap is an admin in the group?
 
@Purag a bot is an owner of this room, we can feed her commands and she can do stuff about it
 
right i know about the bot lol
 
it's just easier, only other owners can feed most commands
 
#don'tfeedthetroll
 
10:36 PM
what exactly does mute do?
 
@Purag just doesn't let them speak. Admins can do that
 
mmm i see
 
I can't wait to see what comes out of my report. Does this make me cool, now?
 
@Callum you're one of the cool guys, yeah
 
28 messages moved to Trash
5
 
10:39 PM
Yay! One step closer to not being a bench warmer!
 
in the meantime, there's an option to not display his messages, just click on the avatar, and click ignore under actions
 
I kick-muted @mate64 for obvious reasons (see moved messages above). I'll be on for the next half hour or so, ping me if there's a problem.
 
as always @Zirak comes to save the day
is it a bird? Is it a plane? It's Zirak!
 
btw @Mosho as room owners we have kick-muting; click on a user's avatar on the list to the right and hit "kick-mute". See meta.stackexchange.com/a/239226/220449
 
I thought there was going to be a vote thing on whether I should be promoted as RO or not some time ago... it never happened, can I do something about it or should I move to the corner and cry?
 
10:45 PM
There actually hasn't been a room meeting for a couple of months now...we should probably do something about it.
 
hey guys
i see i didnt miss anything good
 
@DanieClawson nope
hey danie! You're the one from codepen, right? We must have crossed paths before
 
haha! yeah! was just about to say the same
 
do you need anything?
 
oh no, just procrastinating :)
frustrated today cuz flexbox has turned out to be such a head trap for me, so just taking it easy
 
10:52 PM
@DanieClawson is something not working? I have nothing to do, I could help
 
anyone used bit vectors in JS before?
 
bit vectors? 0.o
is that a thing?
as in fixed-length binary numbers used to store toggleable data or am I misinterpreting?
 
yeppers
 
I can help probably, what do you need?
 
writing a parser that needs to keep track of "states" of rules in a given context-free grammar
 
10:57 PM
and you're using bit vectors because... ?
 
to store those states in a wickedly efficient way
 
as far as I know they're just to do extreme optimizations, I'd reccomend you pull it off with normal arrays first, then it will be easy to port it to bit vectors
 
and, allegedly, there's a nice and neat algo for transitive closures, which is probably helpful in determining which parse to use
i have done it in arrays :)
specifically, this will be slow for a large series of tokens, because we need to check for duplicate states.
 
and what's your problem with porting it to bit vecs?
 
i was just wondering if anyone had done it, and if they had resources on best practices? I've never implemented one. and I'd like to know what the best way is to map bit patterns to the states of those rules.
I don't think I'm planning on implementing it soon...I want to finish an early stage compiler and then optimize it
but I'd like to start thinking about it now. I know parsing will be slow for big files.
 
11:01 PM
think about it, it's just binary
the Xth position in there would be ( N / 2^(X-1) ) % 2
but that's just maths and it's not efficient
you can use the right shift (>>) operator instead
array[x] = ( n >> x ) % 2
it shifts to the right by x places
so if you had 110101001, by shifting it to the right 2 places you get 1101010, then just % 2 and you get the last digit
if you're looking for efficiency, don't use n.toString(2)[x], but it's certainly more readable
and remember, now the places are counted from right to left, but still starting from 0
 
gimme your bits pls
 
wait, what are you talking about right now? lmao
 
@Purag giving you a little tour of how to implement a binary vector
if by binary vector we mean the same thing
 
The Wikipedia page on Binary is really helpful if you need to start at the beginning
 
AND with 1 to extract the last digit
i'm well-versed in binary lol
 
11:06 PM
@Purag completely forgotten about that...
wooooops
 
hahahaha
all good man, all good
implementing the operations I'm not concerned about
plus, states will map to more than one bit
 
array[x] = ( n >> x ) & 1
then
 
right on.
will have to perform scaling on x to get the right offset depending on the length of the mapping i determine
 
@Purag then:
 
I had to learn some of this when I was working on my NES emulator in js. I quit working on it :( I might pick it up again
 
11:08 PM
array[x] = ( n >> x*bits ) & ( 2^bits-1 )
 
i have never understood all this binary stuff its like latin to me
 
but in essence, I'm currently contemplating what mapping I will use. i need the fewest bits possible, but the problem is that this isn't static...i might need more bits depending on how many rules the grammar has
 
@Purag there's no problem with that
 
shouldn't be a problem though. ceil(log_2(# rules)) and just store that somewhere...let the bit vector class do it
 
It's just basic binary ops, I'm sure you'll figure that out pretty easily
 
11:11 PM
yeah. my real struggle is figuring out that mapping
 
You should probably write an optimised version first, then some test cases, then optimise it
 
should I find every permutation of a state and just map them consecutively from 000...000 to 111...111? or should I be more clever? let the first two, three, etc bits reference the rule in the grammar, the next couple bits the position in the rule which we have so far parsed, blah blah?
serious considerations to be made. haha
 
btw, if your objective is to find something better than Earley, you won't
just saying
 
no, i want the bit vectors to replace my earley sets
this is what marpa does
 
Hey
 
11:14 PM
i do a lot of looping on those earley sets, and for each iteration I'm comparing all the members of two objects
it's nasty and will be painfully slow
comparing two numbers for equality though...much cheaper
 
how can I remove a variable if it is in any array in object?
 
@crusty did you google?
the words you're looking for are "remove element from array in JS"
 
nope
from every array in object
which consists of multiple arrays
 
you have an object with several array members?
 
@crusty you just loop through them
google is nice and will show you this MDN link on array.splice
 
11:18 PM
hmm... I already figured out how to remove a specific element
just don't know how to loop through arrays
 
your object looks like this:
 
var objectA = {"prochnica":[], "wypelnienie":[], "korona":[], "amalgamat":[], "u_przyszyjkowy":[], "brak_zeba":[]};
 
@crusty google "loop through object keys in JS"
 
google will as always be nice and give you this MDN link on the for...in loop
 
11:20 PM
And google 'mdn filter' while you're at it.
 
looking it all up
for (var array in objectA) {
and later on "for" loop for arrays?
 
@crusty or array.filter or for(){array.splice}
 
@towc hey
 
@catgocat hey
I did my talk btw! I forgot to ping you!
 
no
 
11:24 PM
wait, I'll give you a link
 
are you joking?
 
there you go, I'm really sorry for not having pinged you: youtube.com/watch?v=dQw4w9WgXcQ
 
I guess "for (var j = 1; j < array.length; j++) {" would do?
 
> The uploader has not made this video available in your country.
 
@crusty javascript arrays start at 0
 
11:25 PM
@crusty then array.splice, yeah
@copy dang...
 
@towc I was already expecting you to give me a link to that.. too predictable
 
@catgocat :P
@copy it was "never gonna give you up" btw
 
@Purag right :)
 
@towc if youre that bored i guess you could take a look at the thing i was whining about lol codepen.io/cl4ws0n/pen/pJqWJg
its all css tho
 
@crusty Using array iteration methods such as forEach will help to avoid such mistakes.
 
11:27 PM
it works fine on my pc but implodes dramatically on a tablet
 
@DanieClawson also add -webkit-flex to it
safari still needs it
 
@towc You evil genius
 
i thought codepen did that automatically
 
@KingMob not my usual mistake. just copied this loop here from my other function :D
 
yeah it does hit view compiled
 
11:28 PM
@DanieClawson it should... that may not be the only problem, but it's what came to my mind first
 
yeah it was a good guess
just for comparison this is what it should look like s3-us-west-2.amazonaws.com/s.cdpn.io/94348/rig_editor.jpg
 
@DanieClawson what happens on tablet? Can I get a screenshot?
 
yeah one sec
 
this is what I get btw
what browser are you using on that image? This is chrome
 
that's... colorful
 
11:32 PM
@Mosho stoned much?
 
@towc extremely caffeinated
why
 
color reference
anyway
 
it's what I see
are you color blind
 
@DanieClawson the only thing that seems to be way off is the direction...
@Mosho was trying to play tricks :P
 
11:35 PM
right, wondering if that may be something in the auto prefixer? like the safari spec maybe changed or something
 
@DanieClawson prefixfree (it's what CP uses) first tries to guess the user's browser, then prefixes based on that. Maybe it's not guessing the right browser out of your tablet
try adding them in manually
 
okay, ill try that
 
literally just copy-paste from the compiled version to the non-compiled one. You can always get back
 
@DanieClawson news?
 
11:42 PM
@Zirak I know, was on mobile
 
well, it looks the same on my phone. waiting to get screenshot back on tablet (i dont have one myself so having my mom test :D)
super professional, ik
 
yup ;)
 
with a single elimination round system, im trying to use a treeNode. I have to halves of the brackets. so am i correct i use a tree node with 1 left node and 2 right nodes(1 up and 1 down)? or do i really have got the whole treeNode thing wrong?
if this makes sence ^^
 
yeah her new shot looks the same as well
 
@DanieClawson as in "same as before" or "same as pc"?
 
11:52 PM
same as before, sorry
 
ok...
are you sure it didn't cache it?
 
yeah i sent her a fork of it
 
also, find out the exact version of safari and run it against caniuse
 
good thinking, ok
 
everything suspicious like align-self, flex-wrap, make sure there's no collision between box and flex... all of those
 
11:57 PM
now that i think about it more, everything that is regular flex-flow and not given an intrinsic size works fine, so its gotta be one of those, i guess?
 
@DanieClawson try... I have no idea
 
For anyone who's a pro at Node.JS
0
Q: App throwing variable reference error when variable is a function argument

DemCodeLinesI am building a backend in the MEAN stack and have come across an issue. The point of the app is simple: Upload a file and it saves it to the server. However, I am stumbled upon a problem. The code breaks and throws the following error in the console when I hit the "Submit" button: <h1>photo is ...

 

« first day (1751 days earlier)      last day (3187 days later) »