« first day (3171 days earlier)      last day (1759 days later) » 

12:29 AM
@FélixGagnon-Grenier Ha! My friend said the same thing!
@Wes lol- so stepping over a nail? Well... that is better than stepping on one- so I'll take it!
 
12:54 AM
@StatikStasis lol that friend has great taste :P
 
Not sure where to ask this, but is there any commonly used spec for entity/database? We have OpenApi openapis.org for API specification. Is there any for entity/database model?
 
@AdhikaSetyaPramudita what are you hoping this spec would allow you to do?
 
@Danack something like: I would share this spec to different ORM-aware framework, and then (with code generator I built, specific for those framework), scaffold the required Model class.
I wonder if there already a standard for this, rather than building my own syntax
 
@AdhikaSetyaPramudita although it's attractive on the surface, this turns out to be a 'bad idea'. The time take to write the model classes by hand is small compared to the limitations enforced by using code generation to have them automatically built.
Symfony has something for generating code from a database - symfony.com/doc/2.2/cookbook/doctrine/reverse_engineering.html
which might be a good starting point, but I'm not aware of anything that starts with just a spec.
 
1:10 AM
@Danack *in most languages
there's one (and only one) exception to that for me, which is C#, and only because of the partial keyword
 
@DaveRandom shame traits weren't more like that...
 
I have kicked around an idea with traits and interfaces in PHP, may revisit it at some point
@Danack yes and no. The main "no" is that it's simply not practical with autoloading, and also I have come to realise over time that it's not totally stupid to separate the type and the implementation like that... a trait should always be accompanied by an interface (imo) but it's not completely ridiculous to do that in such a way that the trait is not the only implementation
scoping in traits is weird unintuitive tuitive though
"tuitive" is now a word and you should use it
From a technical standpoint, I don't think partial is practical without AOT compilation, it certainly isn't sanely doable with a dynamic on-demand symbol loading model a la PSR-4
Related: I am serious considering adopting the IFoo naming scheme for interfaces in PHP. The number of times I have spent ages trying to come up with a non-horrible name for a class because I have given the actual correct name to an interface...
 
meh. StandardFoo or FooImpl or DefaultFoo all work for me......and then the others are FakeFoo, AlwaysFailsFoo, AlwaysWorksFoo...
 
using IFoo since years
works fine for me
 
1:23 AM
cant hear ya
bigger picture plz
 
@Danack don't see how those are any better tbh, just moving the problem somewhere else. I also quite like the quick visual indicator when reading method signatures on MSDN that an arg type is an interface.
 
And on that bombshell, nn.
 
FooImpl sounds like it implements the stuff and not like its an interface...
sounds horrible imho
 
...Impl is horrible, and Default... implies the existence of another implementation within the same scope (which is often not the case). Standard... isn't as bad but it's visual clutter, I... is less so
and I'm used to it in windowsy things
@Stricted FooImpl would be an implementation of the interface Foo
 
oof
that sounds even worse
 
1:28 AM
that's the thing, I've been told old many times by many people for suggesting IFoo but I'm going to stop listening to them
 
havent done proper oop in php since months... have to get back using php more often
 
it's shaping up really nicely IMO
 
have seen interfaces names InterfaceFoo
 
I still love C# like no other though
 
dunno IFoo sounds and looks better imo
 
1:30 AM
I could fit my list of gripes with C# in handwritten notes on one sheet of paper, no other language comes close to that
 
using c# aswell but im not bound to one language
most of my server side scripting is done in php (much more flexible than bash and i hate python...)
 
@Stricted well no, things rarely are and never should be (imho)
and yeh, sod C# for web
 
doing stuff with c and going back to c# or php is fun
or the other way around
i always fuck something up
what is even more fun is using php and git+gitlab-ci to fully manage 5 bind9 nameservers
 
sure, the difference is that when you fuck something up in C you basically have to hold the entirety of everything you have ever know about computer science in you head at once. In PHP you just add a liberal sprinkling of var_dump()s :-P
just setting up gdb needs a masters degree
 
agree
have no degree in cs nor did i ever learn anything properly
just learning by doing
 
1:35 AM
@DaveRandom tuitive, as opposed to intuitive?
 
@Stricted why the f are you running 5 name servers? :-P
 
still havent fully understood alot of things but i get along quite good
 
are you google?
 
@DaveRandom redundancy
5 nameservers in 5 different countrys :D
just for fun
 
shits and gigs yo
bind is a mad piece of software as well, that config file is getting on for apache levels of wtf
@Tiffany see message above
(yes)
 
1:37 AM
hey its fun fetching ~2k dns entrys from a mysql database, storing everything in a json json file, pushing that into a git repo, using gitlab-ci to process that json file with php and writing the zones files, pushing them into yet another git repo so that the slaves can fetch changes :D
 
lol mysql
"we run our own name server for speed" yeh have fun with that
 
well the webapp has to store the data somewhere
and i wanted to decouple the backend from the frontend
 
@DaveRandom ...I ran into that problem more often than I probably should've when I was working on the coding problem
I might finish that off next week and upload it...
 
@DaveRandom the nameservers itself use local zonefiles so they are pretty fast
 
@Stricted I have a drawer you can use if you want, has a few pairs of pants in it atm but I can clear it out
brb 3min
in fairness @Stricted I haven't used mysql since 5.6... does it have schemas yet?
 
1:43 AM
idk
this database exists since ~2010
havent done anything with mysql lately
 
or useful user defined types/functions or just generally some features
 
to be fair i havent done anything webrelated in a year or so
mostly just some server side scripting with php
or just plain messing with android (building roms is fun sometimes)
 
I know they changed some of the default behaviour to be saner (ansi quotes, implicit joins and the like)
@Tiffany I rarely have a project where it doesn't happen at least once
well, libraries anyway
API boundaries are the usual culprit
@Stricted never really touched mobile in any form, too much front-end for my liking (and I don't like Java and I detest obj-C)
 
oh i dont touch any java stuff
usually linux kernel (c)
or some hal's (c++)
or just makefiles
 
oh that I would be more interested in
 
1:49 AM
java is mostly apps and framework stuff that you dont really need to touch
 
make can fuck off, but that's just generally true of autotools
 
(others can do that :P)
these are not normal makefiles tho
 
Java is also improving tbf
 
you just describe in them what you want to have compiled and some device characteristics
 
....in which case, wouldn't XML be better? Or even JSON if you must
 
1:52 AM
ask google :D
they started to switch to "blueprints"
which are basically json files
 
I may check that out at some point
I need to do it eventually anyway as I need to figure out how NFC works
 
2:45 AM
o/
 
 
1 hour later…
4:47 AM
> I pray for proper aspect ratio
lol
 
Good Morning
 
 
2 hours later…
7:09 AM
@ThW Whats wrong with DI a Singleton DB Instance to all your needs?
the one wont exclude the other
 
8:00 AM
puckish impish, whimsical
 
 
1 hour later…
9:24 AM
@DaveRandom agree.
 
10:13 AM
$fh = @fopen($filenameToServe, 'r');

// I want the next line to return false
$contents = stream_get_contents($fh);
Is there a way to make that code return false for $contents, that doesn't involve unmounting a filesystem?
 
10:39 AM
posted on June 21, 2019

Before I write anything else, longtime reader/friend Rene Rosa (aka Evil Adam) is doing a marathon Twitch stream tomorrow (June 22nd at 12pm EST). He will be playing the game Bloodstained: Ritual of the Night and performing crazy stunts and actions as the day goes on. This is to help raise money to care for his father who has brain cancer. Rene is a super talented musician behind the band E

 
11:01 AM
o/
 
morns
 
11:31 AM
\o
 
11:52 AM
@NikiC Should I continue to work on adding return types, or you’ll try to automate with stubs?
 
I head you're Dutchie now @GabrielCaruso ?
 
 
1 hour later…
1:05 PM
@Wes It's for an internal site to show data in reference to productivity. Do you have any tips on how to make it not so flat?
 
1:59 PM
@Shafizadeh or @mega6382 what's this mean? ههههههههههههه
Is it like "lol" or "haha"?
 
@Tiffany :-) .. Depends on the context it can mean either "hahaha" or "a sarcastic sound"
 
@Shafizadeh it's "haha" then. Talking to an Arabic player in a game. The game automatically translates most stuff okay, but that one it didn't. I made a kind of joke.
 
I see :-) ..
 
Wes
@StatikStasis for a starter, that violet and blue are horrible together
 
Alternative color palette idea?
@Wes This is what I was working with: colourco.de/freebuild/…
 
Wes
2:16 PM
as i said, the palette is not bad per se, it's how you use it
for example i wouldn't put colors of similar hue too close
needs more hue contrast
 
ok- that helps.
 
Wes
if i were you i'd start from a 2 colors palette, plus plenty of white, black and gray scale colors
 
What do you think of transparent textured backgrounds?
@Wes Such as ones found here: transparenttextures.com
 
Wes
depends, i do use them but depends
depends. :B they must be very geometric
 
Sometimes they look nice at first but then they get old to me after a while. Hard to tell at first glance whether I will like it.
 
Wes
2:33 PM
the colors are better now, remove any gradient and text shadow and rounded borders you have :B
can you jsfiddle it?
 
well, I just had my first BSOD in windows 10
 
Wes
i think i never had a bsod since windows vista and onwards
which is quite surprising lol
 
The headers will be replaced with 60x60 icon images.
 
@Wes I figured out the reason: I was trying ot run an android emulator, but had Hyper-V enabled ... for some reason Hyper-V interferes with emulators/virtualization, so I had to disable it temporarily
 
Wes
2:59 PM
i haven't seen vendor prefixed linear gradient in a while :B
why's that? :B
it was supported in win10 also i think
 
@Wes Is it not needed anymore? Can you just do "linear-gradient" now? You can tell how much I work with CSS.
 
Wes
yes i can :B
 
Well that's awesome. Fewer lines needed.
 
Wes
are these columns of a table? headers, of a table?
 
hmm... when I removed the vendor prefixes the gradients went all crazy
Where you see TDG, PD, etc. Those will be icons representing some metric that the associate will see. Below it will be data pulled from a database based on their personal numbers/metrics/productivity.
 
Wes
3:09 PM
yes because the syntax has changed
 
Had to change the degree of the gradient.
 
Wes
linear-gradient(to bottom right, cs, cs, cs, cs)
where to bottom right is to bottom left, to bottom, to top, basically any direction in 45deg steps
or, obviously, linear-gradient(32deg, cs cs cs)
cs is a color stop, a color followed by a percentage/offset
 
Wes
3:32 PM
@StatikStasis but is it a grid, like a table?
 
Yes
7 columns; 3 rows.
 
Wes
3 rows more apart the ones i see?
 
There are just 3 rows total. First row is where the headers are, 2nd row is where the numbers are, 3rd row has only the gradient on the bottom.
 
is there a possibility where PDO would not create an exception yet still an insert query would return false?
 
Wes
3:48 PM
@FélixGagnon-Grenier everything is possible with databases. that sounds like a pain in the butt
 
$pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
ini_set('display_errors', 1);
error_reporting(E_ALL);
$stmt = $pdo->prepare($sql);
$result = $stmt->execute($values);
var_dump($result); // false, but no exception
@Wes yeah I er... generally rely on .ini doing its job, and am unsure what I am looking at now..
 
Wes
maybe you have a custom error handler that eats notices and co?
 
yeah that could be it.. it's an include based codebase using iframes... everything's possible :)
... actually that could very much be it, let me remove every try catch ever
wait, you said error handler. ugh.
 
Wes
install debugger? :B
 
Wes
3:56 PM
you should be able to step in the error handler if any, i think.
 
oh gods.
well, this was helpful, had to manually check error info stackoverflow.com/questions/2518354/…
 
@FélixGagnon-Grenier yeah,....been working on it....
https://github.com/php/php-src/pull/4288
https://bugs.php.net/bug.php?id=77490
 
yes like... exactly that
thank you for your hard work :)
lol, with the added twist that the array passed to ? parameters is 1-indexed! (in this current case)
also... reopen-pls stackoverflow.com/questions/2518354/…, that question is actually not a duplicate of the other one? Or we leave it be, since it will be fixed eventually?
 
I'd save the thanks for when it's actually fixed: twitter.com/MrDanack/status/1142463203395473408
 
Wes
4:06 PM
@StatikStasis jsfiddle.net/yk7p2raz i'm not good with dark bg
 
@Tiffany this means hhhhhhhhhhm
From right to left those are a lot of “h”s and on the end is an “m”
 
@Wes What does this do or affect? #hud > div > div {
This looks nice.
 
Wes
selects all divs that are direct children of divs that are direct children of id="hud"
aka css child selector
 
@Shafizadeh this cannot be hahahaha, because there is no “A” in there, if there were “A”s then those would not be joined together like that
 
@mega6382 some languages (Korean) use repeated Hs to indicate laughter
it's a colloquialism
 
4:20 PM
Bit the “m” at the end means otherwise, dont you think
 
@mega6382 could be accidental
 
@Wes Thank you Wes!
 
or another colloquialism
 
yeah, definitely could be
 
@FélixGagnon-Grenier my slayer is overleveled because I'm having too much fun rolling over monsters with cyclone. "Pardon me, coming through"
 
4:24 PM
nothing wrong there :P
 
#lazyweb can you have userscripts on mobile chrome?
I really like the swipe right for reply in WhatsApp and I want it to work in here
 
Wes
4:58 PM
@DaveRandom do you know how to install the php sdk if that's a thing, in a idea plugin?
ah, looks like the sdk is included with the plugin itself :B
@StatikStasis how do you call that scroll thingy in music and video industry that speeds up audio/video playback, that resets back automatically to 1x speed when not touched
 
5:16 PM
In MySQL, does anyone know what's the default max value for a field that is set as a double without any precision values?
For example, double(5,1) tells me its 5 digits maximum in the column, but how many digits if the column is just double?
 
@DemCodeLines I believe you will find answer to your question in the first few paragraphs here
er wait wrong link, sec
bottom line is biggest number is something like 1.7e308, which is freaking big, if you forget some precision
 
5:32 PM
How do you determine if that's the maximum range? If I query for the metadata of a field using mysql's API, I only know that the field type is a double, not if (m,d) parameters have been specified. Since the maximum value depends on those parameters being there, it's not really possible for me to determine that maximum size then, right?
For example, I see length=22 and decimals=31 in the field's metadata when the data type is just double (not double(m, d)). That doesn't make any sense because you can't have 31 decimal places while the maximum length is only 22. Interesting thing is that I can insert a number that is far greater than 22 digits in length into this column.
 
@Wes There is a shuttle and a jog wheel on video controllers that allow you to go back and forward. I'm sure some of them will go back to regular play after letting go of the wheel.
Heading home- later.
 
Wes
@StatikStasis nope, not that. there is also a digital version of it in avidemux... upload.wikimedia.org/wikipedia/commons/b/bd/Avidemux_2.6.1.png on the bottom right, that wheel with the red line
 
Apparently 30 is the maximum decimal number for a double field. 31 now doesn't make sense even more.
Maybe they should have considered putting this in their API docs.
 
5:49 PM
@Wes That's called a jog wheel also. Just a digital version of it.
 
Wes
i can't find a real one that looks like the digital one
... whatever tho :B
 
6:43 PM
PCRE2 version check in configure fails for "##.##-xxx" version strings – #78197
 
7:33 PM
@Danack Yes, I'm. Living in Amsterdam since last week. I hope we can meet really son sir
 
7:49 PM
One more thing I noticed, if you insert a very large value into a double field (2.2250738585072014E+9999), it will accept it without throwing an out of range error.
 
Wes
@DaveRandom nope, looks like i need to install this <depends>com.jetbrains.php</depends>
but no idea how
 
Wes
8:13 PM
i did it
i created a plugin that creates a pop up that says "poop up"
 
@Wes you must be really bored
 
Wes
8:37 PM
debugger doesn't work, obviously
 
... so Chromecast doesn't support Prime Video ... .......
 
8:49 PM
^ from phone at least. I guess I can do it from my desktop, which is arguably better since I don't have to worry about my phone dying mid-show.
 
@Tiffany So I watched the first Good Omens
kinda has potential, but after Chernobyl, it was a hard watch
 
9:38 PM
segmentation fault php build-in server 7.3.2 – #78198
 
10:31 PM
@Tiffany OK, so I was on phone earlier and just checked from my laptop now, and it seems that it is not an "m" at the end but another "h" because the loop is facing left rather than up or down(could be either depending on the font) which would indicate an "m". Also, the thing is that I haven't ever read Arabic without the accents(which indicates how you pronounce a consonant, either "AA", "ee", "i", "u" etc).
Because in Arabic, depending on the context vowels themselves are often ignored and the pronunciation is based on the sentence structure. Unlike in Urdu(my native language), where there are no accents and the pronunciation is entirely based on the vowels, which caused me to make my earlier assumption.
So, it is entirely possible that the sound made from all those consecutive "h"s is "hahaha..." or whatever.
 
Wes
10:53 PM
evenings
 

« first day (3171 days earlier)      last day (1759 days later) »