« first day (2686 days earlier)      last day (2267 days later) » 
00:00 - 15:0015:00 - 00:00

@FélixGagnon-Grenier Good at dad jokes and naming things, shit at fixing dns lib
 
!!dave
 
@‌DaveRandom should work on the process wrapper.
 
Oooh, it's updated!
 
3:05 PM
kinda nice that does not keep history :P
@PeeHaa you saw nothin
 
@Ekin I wish I had. was that a password? git status? unsayable things?
gods, the curiosity is killing me
 
just alt+tab'd wrong to rm -rf some test logs
/me can leave the office now, laters o/
 
Google: 90% of our engineers use the software you wrote (Homebrew), but you can’t invert a binary tree on a whiteboard so fuck off.
 
@FélixGagnon-Grenier you do not need to start your test methods with "test"
you can add
/**
 * @test
 */
also, I would recommend use this style for naming unit test methods public function User_must_have_Towel_when_traveling()
 
3:16 PM
hmmm... I rarely snake case ;)
 
you should, for unit tests
 
@DejanMarjanovic quora.com/…
 
Wes
@tereško but be sure to have a comfortable mouse wheel
 
@Wes sure, but the test methods need to be verbose
and having more than 4 words in camelCase is a terrible idea
 
Wes
yeah i agree
 
3:23 PM
@tereško that does allow for easier reading
 
Morning.
 
Wes
\o
 
@Gordon Well... I cannot binary too and I wrote nothing nobody uses and still work in best company in germany :P
Makes a little sense but depends on which position he applied to.
 
@DejanMarjanovic you do? Why haven't I seen you in our office then?
 
burn!
 
3:32 PM
@Gordon That's funny, I will fire your colleagues.
snap-burn!
 
@DejanMarjanovic what for? they already are on fire and delivering the hottest shit on earth ;)
 
double-burn!
 
@Gordon well I actually thought about code centric :D
 
@DejanMarjanovic it's very nice working there.
 
yes, I pay them very well
 
3:35 PM
Hi, everyone. I am working in codeigniter, I am using multiple databases. Now I want to switch to other database but it's not working.
I use the
$this->load->database('default');
but it not works. anyone can help
 
@DejanMarjanovic you work here?
3
 
@Wes You can collapse them
 
lol
 
Wes
ha
 
3:38 PM
@DaveRandom go away brit schlenkerla.de
 
I think he wasn't about the beer but about the "wank" in wankhaus
but I have a schlenkerla in the fridge
liquid bacon ftw
 
I lost a sense of humour (en_gb), I see nothing funny in Bad Fucking too
 
Wes
when your bug report is reviewed by someone that clearly put zero effort into it....
i think it's a "dumb reports wall" if reporter insists when they actually look at the report
i'm sure many do that :B
 
3:56 PM
Broken links in ext/standard/mt_rand.c – #75996
 
Is 500kb a decent chunk file size for sending large documents to a client? Each chunk means an additional API request to the file storage server
 
> Each chunk means an additional API request to the file storage server
Can't you stream the chunks instead?
 
Wish I could. Their service has public or private mode. In private mode there's no streaming endpoints
 
Request chunks of 1GB :P
 
Right now huge docs are causing memory issues, so I was going to use their ability to specify a byte-range when downloading to do it in chunks instead.
 
4:09 PM
Alternatively just don't put it all in memory?
 
Well it's got to go somewhere, right? it's either all or nothing unless you add a byte range in
 
It has to get somewhere, but it doesn't have to go into memory
 
Sounds like witchcraft to me
 
Think the f* family of functions. fopen/fread/fwrite/fsockopen etc
But requesting chunks may still be valid as it allows resuming of downloads if some huge transfer got borked
 
Ah, that's what I mean by it's all or nothing. The API call to get the document will return the entire thing (or the byte range requested) as part of an API response, wrapped in json or xml. The PHP script opens a stream to php://output and writes each chunk to it as it comes. Sounds like I might be missing something?
 
4:21 PM
> wrapped in json or xml.
quizzical_dog.jpg
 
ikr Dan.It's missing yaml
 
Yeah, I'm using their SDK so I don't actually know their response format
 
oh you are using their sdk
Well if their sdk puts it all in memory their sdk is poop :P
 
Oh actually it doesn't look like the response is wrapped in anything if you directly call it, but yes their SDK does download it to memory on call
If I can just make the request myself it should be fine to stream \o/
 
4:38 PM
    $matches = [];
    preg_match_all('/([^\r\n]+)(?:\r\n|\r|\n)/m', file_get_contents($this->path), $matches);
    return $matches[1];
would you keep the $matches = []; initialization line because more explicit, or remove it because anyway it will be dynamically created?
 
Remove it
Also what does that regex do :P
 
it does not feel more "right" to you?
@PeeHaa match lines
 
You mean declaring it yourself?
 
Nope
Can't you just do file($this->path)?
 
4:41 PM
it seems to keep the endline characters as part of the string?
 
Not by default afaik
 
Morning.
 
phpinfo() reports wrong extension_dir path – #75997
 
let me rephrase. it keeps the endline characters as part of the string.
;)
 
wat
 
4:42 PM
> Failed asserting that two strings are equal.
--- Expected
+++ Actual
@@ @@
-'line'
+'line\r\n
+'
 
It really shouldn't
oh sorry
Default is keep
Add the FILE_IGNORE_NEW_LINES flag
 
yeah, was looking for that ;)
 
:-)
 
lol yeah that definitely pass the test
 
:-)
 
4:43 PM
but meh regex!!! ;)
 
heheheh
Commit the regex. At least it's still in history :P
 
Maybe you can help me too now :P
Is it possible to convert a documentfragment into a proper dom node?
 
you're asking the react guy?
 
I have a fragment, but I need to add children to it. Currently I add the fragment to the dom and do a queryselector hoping I get just added element back
@FélixGagnon-Grenier lol right...
:P
 
4:46 PM
srsly though, I wish I could help :)
 
No worries. I just retract my post about using file() and you should act like you haven't seen it
 
:D
 
already commited n all
history has been made
 
Wes
Love this little detail when it goes to password entry. https://www.reddit.com/r/web_design/comments/7z7f8n/animated_login_avatar/ https://t.co/DbeGAOFyQo
 
4:51 PM
@FélixGagnon-Grenier \o/
 
you guys make it hard on keeping motivated on what I want to do... lately my obsession is learning Korean, but also wanting to go back to programming... it's hard for me to balance two projects at the same time
 
we're really good at giving the illusion of getting things done
 
almost have the korean alphabet memorized though :D
 
use korean variable/method names :P
 
I thought about that... but that would just get confusing
plus single letter vars and stuff...
 
5:03 PM
Holy cow, it worked
 
Now open a beer
 
I think this room can transfer alcoholism.
 
you're telling me
saw something on reddit that said alcoholism can lead to early dementia
didn't read the article though, just the headline
 
Or you know, liver failure.
 
stick to one drink a night, or one drink every other night and you should be fine
 
5:06 PM
@Tiffany that sounds like a very sane way to do newspaper. can't see what could possibly go wrong ;)
 
(in my opinion)
 
I get drunk every night now.
 
@FélixGagnon-Grenier there are several negatives to alcoholism, so I chalked it up to another negative... but headline could definitely be stretching the truth too.
@Allenph when I used to drink craft beer semi-regularly, I'd stick to a beer a night. that was enough to get me tipsy. I completely dropped alcohol when I found out it was a migraine trigger. I'm not strict about the "no drinking" thing... considering I have beer in my fridge right now, but I just don't drink it that often
 
I don't like beer. I just hit like 3 or 4 shots all at once every hour for a couple of hours every night.
 
I dunno - if you see it becoming a problem in your life, look at ways to reduce the amount you drink
o_o
like if it's negatively affecting your social life, your work life, your health, whatever... then look at ways to stop or find alternatives
or reduce the amount you drink
 
5:10 PM
It's not really affecting me.
 
that's the scary part
 
@Allenph do you get hangovers?
 
Not really.
 
lucky you
 
I'm just going to be a drunk until I move to Colorado next year.
Then I'll never touch alcohol again.
 
5:12 PM
anyway, need to start getting ready for work. we had a delayed opening because of icy roads, but gotta be in at noon... presuming my headache goes away
switch to marijuana? :P
 
Yeah. I got arrested for it before here and it messed me up pretty good.
But it's definitely my drug of choice.
 
Try crack.
 
I would definitely use it more frequently if 1) it was legal in IL, and 2) if it didn't have a long-term negative effect to ADHD
goes back to that "use in moderation" though
 
@DaveRandom You sound like a CIA agent in a black slum in 1960s America.
 
5:14 PM
shit, I've been rumbled
 
lol
 
^ Rofl.
Where do you put entities that belong to more than one aggregate @Wes?
&& / || @Patrick
 
Wes
i don't have entities that belong to more than one aggregate
i feel i am ignored :B
 
We've already talked about this, haven't we?
 
5:21 PM
posted on February 22, 2018 by CommitStrip

 
Wes
a gillion times :D
the only things you might think to share is value objects
 
Value objects have no behavior right?
 
Wes
define behavior
 
@Allenph They have no identity.
 
It looks like the people who wrote these APIs I'm connecting to are using DDD or something very similar.
They have a customer aggregate with a name and an address object inside.
And it looks like name and address are used in multiple places.
They do indeed have IDs though.
 
5:26 PM
Those are probably entities then.
 
Which is exactly why I asked Wes that question.
 
@PeeHaa I think that works.. :x the SDK is built as an extension of guzzle 3.x, so I think this might have solved it
$outputStream = fopen('php://output', 'wb');
$request = $cloudClient->get($object->getUrl(), null, ['sink' => $outputStream]);
$request->send();
 
Awesome \o/
BTW is guzzle based on curl?
 
I have never been entirely clear on what effect the b flag has, anyone actually know?
 
binary safe, that's all I know :V
 
5:30 PM
PHP doesn't usually distinguish between binary and text
 
@PeeHaa I was wondering the same thing. I haven't dug into it though.
 
AFAIK curl also has a directive to allow streaming
 
@PeeHaa "no hard dependency on cURL, PHP streams, sockets, or non-blocking event ..."
 
ah
 
it certainly was cURL-based at inception, I think there are now adapters for all sorts of things
I remember watching a talk on it at phpnw when it was still a new shiny thing
 
5:32 PM
> TypeError: Object.keys(...).reduce(...) is undefined
JS is confusing
o/ food
 
Wes
> your mom is undefined
 
is it fair to test whether the streaming works by using memory_get_usage?
 
probably not
you don't know what else will be allocated during the call
 
True. I took a reading without sending any request as a base, then took readings from a "streamed" version vs the non streamed one. The streamed one is just larger than the file size, the non streamed one is just over 2x the file size
Not sure if that means it's still just downloading the entire contents before writing it to the stream given, or whether that would happen anyway and that usage is unavoidable
 
well that would seem to indicate that the stream works I suppose, since the diff is basically the size of the file
 
5:41 PM
@PeeHaa Yes
At least the version I have in this app
Which I think is... 6
 
Ah no, it's still the same. The only reason it was 2x is because I was saving the contents to a variable
 
github.com/guzzle/guzzle/blob/master/src/Client.php#L351 (I know that's for a very specific thing, but nice comment for general too ;))
 
3 messages moved to Trash
 
nothing happened.
 
hmmmmmmmmm
hey @tereško, my twig install has \Twig_Environment in global, why can't I haz Twig\Environment?
 
5:46 PM
not sure
there was some fackery with it regarding autoloaders
 
Yup. Literally just send an fopen call to the URL instead and the memory usage is a minimal amount higher than if I had not made a request at all..
$authToken = $cloudClient->getConfig('request.options')['headers']['X-Auth-Token'];
$fileStream = fopen($object->getUrl(), 'rb', false, stream_context_create([
    'http' => ['method' => 'GET', 'header' => 'X-Auth-Token: ' . $authToken]
]));
$outputStream = fopen('php://output', 'wb');
stream_copy_to_stream($fileStream, $outputStream);
 
@Sean PHP memory usage has nowhere near a 1:1 map with operations
 
6:11 PM
Hello,I am trying to build a face in hope application with php?Any suggestions?
 
u wot m8
what is a "face in hope" application?
 
face in hole* sorry
 
@DaveRandom He wants to build your face. With PHP. You should be flattered
 
@D.'s this just raises more questions
 
I am looking for apis to build this,there are none in php only c++ or .net...
basically merge two images,okay this can be done,but how to detect a users face and more importantly merge it at a certain location on the other image
 
6:17 PM
@PeeHaa ^
 
yes exatly hahaha
 
Wes
wtf did i just see
 
research
@D.'s this seems to be entirely client-side
 
Wes
i always look at the room in the worst moments
 
I did @DaveRandom there are no apis,all day I have been doing the same thing
even OpenCv is in c++
 
6:19 PM
!!? javascript image manipulation
 
Search for "javascript image manipulation -site:w3schools.com" (https://www.google.com/search?q=javascript+image+manipulation+-site%3Aw3schools.com&lr=lang_en)
• CamanJS - Javascript Image Manipulation - What is CamanJS? CamanJS is (ca)nvas (man)ipulation in Javascript. It's a combination of a simple-t… (http://camanjs.com/)
• Pixel manipulation with canvas - Web APIs | MDN - 30 jan. 2018 - Until now we haven't looked at the actual pixels of our canvas. With the ImageData o… (https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API/Tutorial/Pixel_manipulation_with_canvas)
 
start there ^
 
@DaveRandom lolwat
@DaveRandom Not sure I like that being on the web though :P
 
uhhh too late :-P
 
@MadaraUchiha will fix it :)
 
6:22 PM
need to get it mod-deleted
 
@Leigh Ah I see
 
the js dont do what I asked for anyway I think this chat has taken a different direction
 
@PeeHaa He's going to edit Daniel Lowery's face over the other guy? :P
 
@D.'s all of the image manipulation on that site is implemented in JS using canvas
 
evening room
 
6:25 PM
Yes but It doesnt get the face,it does only zooming,and different layers
 
I will it in more details
 
Hello guys! First time here! How's it going?
I need some basic explanation on how a module for PrestaShop works. I have the source code.. so If someone is willing to look into it and tell me how the flow is going, i will really appreciate it
Any1? :/
 
6:40 PM
oh boy
> By running sudo npm under a non-root user (root users do not have the same effect), filesystem permissions are being heavily modified. For example, if I run sudo npm --help or sudo npm update -g, both commands cause my filesystem to change ownership of directories such as /etc, /usr, /boot, and other directories needed for running the system. It appears that the ownership is recursively changed to the user currently running npm.
And that people is why everybody should just work under root directly :P
 
what the actual shit
 
Reminds me of that rm -Rf thing with a space in it :P
Although this is actually fixable
 
I called him paranoid back then, but the previous tech lead at my company asked me to write a small service to do the whole FE build process in an isolated machine instead of prod servers. :D
 
is it bed time yet?
 
WTF you actually pull pre-releases by default?
 
6:52 PM
me? no, npm is a stable version but still away from prod machines :P
 
No was talking about:
 
@PeeHaa amazing
 
npm install -g npm
 
That downloads pre releases
For whatever reason
 
6:53 PM
javascript, mainly
 
:P
Gotta love the naming though github.com/npm/npm/commit/…
 
ahh... wow..
 
gods, that will give me fuel for the npm vs composer discussions at work for ages to come
 
var correctMkdir = require('../utils/correct-mkdir.js')
hehehehehe
fwiw that correctmkdir is the actual faulty one :D
 
6:54 PM
> // annoying humans and their expectations!
3
 
lol! Didn;t even notice that one :D
 
lol
 
fwiw, my current printing project is a warhammer 40k bolt rifle
yes, this is fucking awesome
 
@PeeHaa if you name something "correct", "better" or "improved", you are basically setting yourself up to fail
 
6:58 PM
:D So true
 
@DaveRandom or final...
:P
 
lol
 
ArrayAccess's numeric strings are converted to integers – #75998
 
Surely that's a dupe
 
Wes
yes
a bug that will never be fixed :P
 
7:03 PM
@FélixGagnon-Grenier I have this one printed. It's pretty cool. NASA has a lot of models for printing
 
@pmmaga Did it crash? :P
 
@PeeHaa It's still going! ;)
 
did you really print all the pieces at once correctly?
 
@FélixGagnon-Grenier Well, after a 2nd or 3rd attempt IIRC it was a couple of years ago
also, if for some weird reason you ever want to check out an STL as ASCII I've got you covered :D
 
7:07 PM
@pmmaga nice
 
@pmmaga lol. I'm not sure how to cope with that concept just yet ;P
 
hehehe
 
Wes
can't believe english doesn't have a word for a single hair
 
can't "hair" designate only one?
 
Wes
it can but it's ambiguous
 
7:41 PM
ok bye ppl, gud nite
 
Wes
i'm hungry
can someone lend me some food
 
how do we do that?
 
As long as you're willing to pay interest Wes.
 
Wes
i cannot afford
 
8:37 PM
Anyone finding GitHub slow?
status shows it's fine
But for me it's like a JavaScript program
 
It's kinda slowish yeah
 
that must be the npm fuckery flooding every js related repo on github
 
 
1 hour later…
10:03 PM
Can anyone help me with an sql query in php?
 
@FélixGagnon-Grenier Wow
What a fucking clusterfuck.
 
:D
 
11:12 PM
> We apologize for any inconvenience, but an unexpected error occurred while you were browsing our site. It’s not you, it’s us. This is our fault. Detailed information about this error has automatically been recorded and we have been notified.
That doesn't happen often for SO
 
yup
I've only seen it once or twice iirc
 
hahaha
I'm tempted to comment something very not politically correct
 
lol
 
11:40 PM
@PeeHaa lol
 
11:50 PM
@Wes That local ID thing worked like a charm. Thanks.
 
00:00 - 15:0015:00 - 00:00

« first day (2686 days earlier)      last day (2267 days later) »