« first day (2132 days earlier)      last day (2830 days later) » 

3:01 PM
INFO  org.apache.solr.core.SolrCore  – [select] webapp=/solr path=/mlt/ params={q=id:"E%3D5"&qt=mlt&fq=-db_type:g+-db_type:q+-db_type:db&rows=5&wt=json} status=0 QTime=1
It's status 0 what the shit why are you saying success when nothing happens >:(
 
TIL photos of thalassophobia are nightmare fuel
 
my easy money so far has been on mining plutonium, zinc, and that blue one
starts with an H
 
@SterlingArcher We successfully did nothing!
 
made 1.5 mil to buy my new ship and am already at like 600k again
@ssube I upgraded my gun with +3 spread shot or w/e
 
3:05 PM
@rlemon Heridium?
 
gun only gets two shots per reload now, but I take down almost everything in those two shots.
@BenFortune probably, tbh I should just google these things
 
You guys seen the mods?
 
@rlemon I had that for a while but found a bouncing machine gun, which I'm liking better.
 
right now I'm torn, there is a couple crashed ships I know about and they all have shittier weapons and drives, but one or two more storage.
I can't construct all of the current upgrades, otherwise it is no question
 
anyone good with nginx?
 
3:08 PM
depends
 
I'm not bad
 
is nginx good at you?
 
just wondering if you can proxy-pass websockets through port 80 into a node.js app
 
service @jAndy stop
 
HAMMERTIME!
 
3:10 PM
@jAndy sure
we balance all our sockets
 
means.. can nginx run on http default port and kind of auto-detect incoming websocket requests, tunneling those through internal ports on the machine
 
you just have to make sure they're pinned to a backend
 
@SterlingArcher so you're into metalcore, have you heard Converge?
 
@ssube maybe I'm confused about it, but can you only expose port 80 on your server, let nginx do all the default http stuff and deliver files, but if a ws-request comes in, detect that and proxy that through on the server? Or do you have to have another open port for the websocket stuff open
 
@jAndy they go over the same port
 
3:14 PM
@NathanJones don't think so
 
sockets start as an http request
they get upgraded with some header negotiation, but you don't treat them differently
 
well then I don't get it really. Here (firewall network) I can't do any websocket requests to my server, while it works for me at home.
upstream websocket_proxy {
server 127.0.0.1:3000;
server mydomain.com:3000;
}

and on the virtual server part I do the connection upgrade stuff alongside

proxy_pass http://websocket_proxy;
 
@jAndy Please don't post unformatted code - hit Ctrl+K before sending, use up-arrow to edit messages, and see the faq.
 
@SterlingArcher Historically, Olympic Boxing has been the most controversial event.
 
Unreal. I got so mad watching the fight just now
Poor guy looked like he was crying. 19 years old, robbed twice
 
@Trasiva uh, wait, he didn't tour the house before buying it?
 
@NathanJones agh, too thrashy for me. Not my style
 
@littlepootis You usually don't when you buy them at foreclosure auctions. They're generally 'as is' purchases. The real estate companies don't either, they just care about getting their money.
 
3:20 PM
@SterlingArcher yeah, they're really heavy for metalcore, they almost sound like death metal sometimes. they have some great riffs, though.
 
@Trasiva ah, it was an auction.
 
@littlepootis Yep, the payments hadn't been made in several months. A police officer knocked on the door and didn't receive a response (at that point they should have considered it a welfare check and entered the house). After that, the bank took the house back and auctioned it.
 
@ssube if I setup my ws-server with a listening port to let's say 8010, why would I need nginx (or any reverse-proxy)? Browser could directly communicate over port 8010 to my ws-server no?
 
@jAndy you never want to expose node to the internet directly
a) it's an app server and they should never be WAN facing, b) it's not terribly strict or secure, and c) you should have some balancing/routing further out
 
@ssube yes I know, that's why I want to avoid that exposing.. but I only seem to find examples where nginx just proxies on a different port to the machine where the ws-server script is listening
so what is the solution to this? Let the node/ws-server run on port below 200? I can't listen on 80 simultanously obviously?
 
3:35 PM
node can't run below 1024
 
@Trasiva s/Olympic//
 
@ssube it can?
 
boxing is and always has been a shit show for corruption
 
@ssube so what is the solution then? How to run a ws-server which gets data from nginx which tunnels all the data through port 80?
 
@littlepootis if you run it as root, which isn't a real option
@jAndy I'm not sure what your problem is, tbh
 
3:36 PM
@ssube you can let a program use ports < 1024 iirc. No root needed.
 
@littlepootis in most real systems <1024 is reserved ports.
 
Has anyone here worked with doing tests with redux/react? If you have a simple action that requests a resource via fetch, how is that supposed to be unit tested? I have the following:
  it('Should retrieve 25 documents', function (done) {
    const fn = Actions.retrieve();
    expect(fn).to.be.a('function');
    const dispatch = spy();

    fn(dispatch);

    setTimeout(() => {
      // ???
      expect(dispatch.calledWith({
      })).to.be.true;
      done();
    }, 10000);
  });
 
you need sudo rights to listen on those ports
 
@rlemon I know
 
@littlepootis only if you fuck with a bunch of kernel settings
and even then, you should never have your application running as root
and code injection stuff will have full control
that's why you run a proxy
 
3:37 PM
with nginx proxying, why do you care what ports things are on?
 
@ssube as I just explained, I run nginx as static file server and all default http stuff, but I simultanously run a node ws-server which should deal with web-socket data. You can't setup the ws-server without a listening port right.. so there is always another "open port" aside 80
you can't avoid that can you
 
can I avoid direct port access?
clearly not what I want to be visible.
 
@jAndy you just open it locally, so it's not really open
 
@ssube I run must things as nobody anyways
 
mhh yea, port scanners spot that as ppp
 
3:39 PM
    # I just started using this. static files, fallback to asking node (including websockets)
    root /home/myapp/static
    location / {
        gzip_static on;
        try_files $uri @node_proxy;
    }

    location @node_proxy {
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        proxy_http_version 1.1;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header Host $host;

        proxy_pass localhost:3000;
 
@jAndy if you set it up right, port scanners won't see it unless you run them locally
node should almost always be bound to localhost only
 
but yeah, for real applications, use nginx.
 
I have that very same config
question is
does this: require( 'socket.io' ).listen( 3000 );
open a port on the machine or not
 
listening and opening are not the same
unless you have some crazy DHCP/UPNP setup, nothing can open a port
 
alright.. so that I was pretty hard confused about
 
3:42 PM
iptables/firewalld controls open/closed/deny
 
Oh, also there's CAP_NET_BIND_SERVICE. Which lets normal plebs bind to < 1024.
 
the application can listen on any port, regardless of open-ness
ports on localhost are always open
 
anyway, I'm wondering why I can't connect to my ws-server then here behind a nitty firewall
if it all runs over port 80
 
so you set node to bind only on localhost (not your public IP) and nginx to bind on the public
 
Guys, a reminder for competent devs looking for some OS work: There's always things to do on Miaou.
 
banana
 
@rlemon Fuck, she burned his ass so bad he's rioting in Milwaukee.
 
@DenysSéguret is the trello board still being used/maintained?
 
@GNi33 yes, but discussing is probably more efficient, in order to find a task
 
sure, but it's a nice list of open tasks
oh, okay
 
3:48 PM
Note that there's also a new documentation on making plugins: github.com/Canop/miaou/blob/master/plugins/README.md
because that's where most of the work goes
 
@jAndy JUST the websocket stuff isn't working? Do you have the first 2 lines form my location @node_proxy { above?
 
I often implement features which could appear to be core as plugins just to make them easier to grasp and maintain, and to reduce core complexity
 
@Luggage I might got fooled entirely.. as soon as I load socket.io and try to make a call to io(), it spams with: `polling-xhr.js:250GET domain.com/socket.io/?EIO=3&transport=polling&t=LQPCFlJ 404 (Not Found)"
and I have no clue why, it get's entirely loaded as AMD module, why would it try to request the socket.io library
 
that's it trying to reach the server, i think.
 
@GNi33 Example of some things I won't put in the Trello board: investigate some details on pg named prepared statements to make sure everything is alright
 
3:54 PM
yea, that's not a request for the library, that's socket.io trying to connect.
 
"domain.com" ? Is that normal ? A kind of placeholder ?
 
that's saying something within polling-xhr.js, on line 250, is sending a request to x
 
#MakeTheOlympicsMoreExciting The Hammer Crotch Event. https://t.co/gf9lamgj6s
 
Looks to me like it's using some defaults that don't apply in your case
Try giving it a url to connect to.
 
or STOP giving it a domain that is wrong, maybe.
also, ensure /socket.io is proxied.
// all you need to connect, usually.
import io from 'socket.io-client';
let socketIoConnection = io();
 
4:01 PM
@DenysSéguret alright, so best to just jump in to miaou and chat with you about it a bit?
 
> In order to be available, they must be installed, that is usually just copied to the ̀"plugins" directory of Miaou.
@DenysSéguret can't the provided path be outside of miaou?
> Now that the plugin is enabled, it will be available next time you restart Miaou:
 
@FlorianMargaine Today: not always, only the server part. I just noted a few minutes ago that this could be made better
 
@DenysSéguret fun tidbit to add: add a signal handler (e.g. SIGHUP) to reload the list of plugins
 
4:05 PM
yes
 
why not?
 
or maybe I don't understand what you mean
 
kill -SIGHUP $(pgrep node) would reload the list of plugins
 
you want a hot plugin loading capacity in miaou ? without stopping the server ?
 
4:07 PM
it's a nifty feature, but not the most useful
great for dev, not so much prod
 
Everything is initialized using the plugins list, as they can have so many impacts (they can literally do what they want). Making it possible to stop/start them when everything is running would really mean a reduction of their capacity. I don't see the need
@ssube What would it bring for dev ? How would sending a signal be better than restarting ?
 
@DenysSéguret faster
 
It's fast enough, as in you don't have time to alt-tab to your browser anyway that it's already running
The only slow (well, somewhat slow) thing is when many users reconnect at the same time but I would have to reconnect them anyway if the list of plugins was changing
In any case, you can work on that, first step being finding a strategy, but I won't do it myself.
 
@MadaraUchiha Thanks. I am working on removing the IDs. The scrolling is still weird even with overflow: auto on the ol. plnkr.co/edit/CapFNSrQL1UKI8CRcneo?p=preview
 
4:22 PM
@Loktar so recently I've been addicted to SJW Freakouts on youtube. It's so cringy I just smile
 
haha yeah so cringey man
 
It's amazing. Yet I don't want to live on this planet
We need to terraform mars so we can gtfo
 
we don't need to leave
send them
 
@SterlingArcher Or have fun with it. Send all the SJWs to the middle east.
 
australia 2.0
 
4:25 PM
Let them try and deal with the issues over there.
Why send them to Mars? Save money, dump 'em all into a conex and dump them in the ocean.
 
Space Justice Warrior
 
!!define SJW
 
@Luggage SJW (countable, pejorative) Initialism of social justice warrior.
 
Some Juicy Watermelon
 
I love when they get all froggy when I'm wearing some sort of military affiliation stuff.
They're very pro-veteran around here, they just get ate up, and I don't have to do a thing.
 
4:34 PM
Suddenly Just Wondering
 
hmmm, any body have any strong opinions about getting the contents of a file via a file opener vs just using exec with something like 'cat <filepath>'?
 
@rlemon fffuuuuu that is so scary
 
logging is one of the most dangerous professions
 
console logging?
 
4:36 PM
That's why I disable all logging on my servers.
 
it's so dangerous it used to break ie
 
@Rooster in node? is this once during startup or multiple times?
 
eh, well it wont be in node, but if it were in node, wondering opinions. Its going to be part of a comand line status checking tool. Pretty much just looking at a small config files values in /etc
 
in node, the fs module
 
Well, if not node, what? if a shell script, then, of course, cat away.
if node: var fileContents = fs.readFileSync('<filepath>', 'UTF-8');
 
4:39 PM
exec('cat whatever', (stderr, stdout, err) => {
  // stdout
});
 
But I have no real preference for 'not node' since it's a fairly large category.
 
argument order may be off. I'd have to check
 
right^ rlemon
ya, thats what I was looking at
 
but why do that, when you could use the fs module
 
is there a good reason to not just do that
is the fs module much easier though
 
4:40 PM
@rlemon please don't do that
 
^
@FlorianMargaine don't tell me, tell Rooster
 
yea, two. Reason one, there are easier ways. Reason two: YOU AREN'T USING NODE. :)
 
@Rooster yes, you're spawning multiple processes for absolutely no reason
 
kk, thats the sort of feedback I was looking for
 
another reason: I'm going to track you, find you, and get you if you ever do that.
 
4:41 PM
getCHOO
sure sure
i wonder what languages that might be a better approach in
it makes sense to me not to do it in node
 
for reading a file, any language. We need more details.
 
now that you pointed that out
 
I never said don't use node, YOU said you weren't
 
dude, if I told you what I had to write this in, you might throw up
 
Try me.
 
4:43 PM
perl :0
 
@towerofnix Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
 
you must use perl?
 
perl is a great language to write in.
 
4:44 PM
I barely threw up at all, btw.
 
i dont know, writing in perl makes me feel like Im wasting my life
but that thought ^ also seems stupid to me
in some ways anyway
 
I'll repeat
> perl is a great language to write in.
 
@FlorianMargaine no spamming, please.
 
why do you feel that way
 
:)
 
4:45 PM
all the damn dereferencing
 
Are you forced to use perl?
 
kind of
theres this giant codebase
 
a giant codebase of perl? Find a new job. :)
 
ultimately were migrating it to node
idk
 
Learn to love another language and, in time, hate it like you hate perl. Then learn a new one, and so on.
 
4:47 PM
i already know a bunch
i get decision making power here
hence the move to node
also, looking for jobs sucks
recruiters are gross
the perls really not that bad
my main beef with it is that its not really a transferable skill
like if I go somewhere else, probably not going to be able to use perl knowledge
besides the general problem solving sort of stuff that goes along with really any language
 
right
 
i kind of dont mind working in any language that I might use somewhere else
like the last shop, had to do python/ruby/java/js
that was fun :)
the perls fun as well
just a nagging voice in the back of my head warning about the future
 
If you use enough languages and pick them up, you should be fine.
 
I say everyone just use ColdFusion. Obviously it's the best solution.
 
If you are someone that gets their head into one language and forgets how the other work, then you should care more
 
4:52 PM
Just write C
 
swift/rust/go
 
i was looking at clojure and elixir
and go
actually
ya its fine
im more concerned about the perception of perl on a resume I guess
but then again, that might just be me
 
well, i can't speak for others, but as long as that's next to some other experience that shows you wern't doing JUST perl, it's not a negative.
 
I don't think anyone would care about Perl being on your resume (Unless they're hiring you for a Perl dev position)
 
fair enough
 
4:55 PM
I still use awk.
 
hehe, awk has been useful for weird things for me in the past
but I cant find a consitent use for it
same with sed
actually, I really want to learn LISP
as I heard it does things that will change how you think about solving problems in general
 
It really does. It took me a few tries before I "got" it.
 
isn't clojure a lisp dialect?
 
Yep. For JVM.
ClojureScript compiles Clojure to JS.
 
@JonClements Any reason why Code Review isn't one of the migration options on SO?
 
5:05 PM
@Trasiva plenty of meta posts on why, so yes :)
 
Well okay, I'll dig through meta then. I just feel bad using the mod flag to migrate.
 
you should almost never have to raise those flags. Very few things belong on code review.
I think I've flagged/closed maybe a half dozen questions for that, ever
 
It's the second one in roughly three weeks.
 
Kez
5:21 PM
good evening peeps
 
hey guys, is using a browser plug in the only way to access the users filesytem (for reading and writing to files)?
I'm reading conflicting info but the majority of posts say that FileSystem API is dead
 
Kez
I have a slight issue, I'm trying to create a very simple collapse/expand script, however everything is within a foreach loop (php) and i can't seem to get each collapse/expand to have their own respective id. any suggestions? thanks p.s i have tried incrementing the id with jquery.
 
user2620028
whats up peoples
 
user2620028
did JS chat die? its mid day on a wednesday and no one is really here
 
Kez
@HatterisMad yeah it's dead
 
5:38 PM
dead like filesystem API?
 
Is it possible to determine buffer lengths using big endians ?
 
@KarmaDoe sure
fs stat will give you file info
 
And if it comes from 'data' events ?
Should i use fs stat on data buffers incoming to server socket ?
 
nah, you need to send metadata before the file
 
there are no files, just received buffers tho.
 
5:42 PM
do the buffers represent files?
 
No
 
well, you need to send metadata one way or another
that or read the entire thing into memory, which isn't great
 
They are hex encoded binary strings.
I´ll see what i can dig up, thanks for the pointers.
 
Hey, anyone up for a little data-transformation challenge? I've got data in one format and am trying to massage it into a totally different structure and could use some help using underscore map / filter etc
 
@RickBarkhouse Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
 
5:51 PM
@RickBarkhouse that's definitely a map/reduce job. Do you have an example you can post somewhere (jsfiddle, jsbin, etc)?
 
yeah I could put it in a codepen, one minute
ok here we go: jsfiddle.net/p4a31341
 
@RickBarkhouse hm, interesting output. Gimme a sec.
 
I've managed to construct everything except the items arrays
 

« first day (2132 days earlier)      last day (2830 days later) »