« first day (1940 days earlier)      last day (2999 days later) » 
01:00 - 16:0016:00 - 00:00

user5711741
1:51 AM
Hi
 
2:51 AM
hi
 
3:02 AM
Kanye west
 
 
1 hour later…
4:23 AM
moin
 
5:10 AM
A ridiculous hour, @JoeWatkins
 
indeed
 
5:44 AM
0
A: unable to reacquire mutex and pass values correctly between threads

Joe WatkinsI think some of your idea is backwards; It shouldn't be the main context that is waiting, it should be the worker threads waiting for data ... The job of the main thread should be to keep populating the payload and waking one thread at a time to process it. So here's some scribbled code that is...

sunday morning essay
@rtheunissen where's php-ds/ext at ?
 
Still at rtheunissen/ds :S
@JoeWatkins I've been working on the post, and some refactoring..
 
@rtheunissen awww thought it would be open by this weekend ?
 
Me too.. it's at 99% though
Reckon I should get it up on PECL before I post?
(Having no idea what's involved)
 
you got karma for pecl ?
I think people are pretty familiar with github now ...
imo pecl should come when the docbook is done
 
Kk
I got 0 karma
 
5:57 AM
you'll need karma for pecl and docs, make some noise at @Tyrael, I would ...
 
Will do when I have something ready.
Docbook will have to be coming weeks.
 
Hi Guys!!!
 
@rtheunissen I know it's a shit, but it's what people expect, and you'll get much better exposure if your manual pages are indexed by google on php.net ;)
because people don't read blogs, or reddit ... we do, but we are in the minority ... tiny tiny minority ...
 
I completely understand, will feel better about after a few days of rest etc.
You mentioned appveyor before.. did you mean travis?
 
6:03 AM
I didn't, but both need doing I guess
 
I'll migrate to ds within.. half an hour
 
appveyor is only windows
you'll need to enable travis and appveyor because you own repo
I'll commit stuff to make them work if you want ?
 
I'll do a big initial commit soon.
Could make you an owner of the org
Also just a stupid thing... php-ds/ds or php-ds/ext ?
I think ext is better because it's obviously.. the extension, not the bench or test etc
 
might be better to use php-ds/ds, because git clone is gonna be awkward otherwise ?
I like ext better too ...
people complain about stupid shit ...
 
Ooooh duh because "cloning into ext"
-__-
 
6:12 AM
yeah
 
6:23 AM
but then if you need help using git, you are gonna copy paste whatever is in the readme ...
if you don't, then you already know how it's going to behave ...
it might not be worth worrying about then ...
not sure @rtheunissen
 
/ds
 
k
probably best
 
Wes
> Your first Stack Overflow search should be for encodeURIComponent.
:P
mornings
 
rning
 
'nin
 
6:47 AM
õ/
 
aight @JoeWatkins, here it comes.
Repo has more PHP than C o_O
 
7:05 AM
The only things left to do are: CI, stub, README.
 
I'll do CI ... just dropping misses at work, be back in half hour or something @rtheunissen
 
Dinner time over here
Might not be able to do much else until tomorrow. Public holiday though so I've got all day.
 
7:51 AM
yo
@JoeWatkins so your true colours revealed at last, you dirt dirty CodeIgniter user
 
hehe
@rtheunissen did you enable travis/appveyor hooks ?
@rtheunissen can't push to repo ?
 
8:06 AM
@JoeWatkins one sec
@JoeWatkins write permissions set.
I'll do the hooks soon
 
y no public key ?
maybe need to add it to org somewhere, not sure ?
ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAIEA45RF960ogFP77/Iwt6vADnTWb+0neWSaC7j0XWVT1Q4ETSC0temlWIJK70lNqQxT2QV79hDh3MDE7HE5a89mPp8MPJCazYsq+x7glUZp65QWIYIi2/I+kVRomPzDOezCwjzWn7OuK7olw4tRcAuYKQ6zMKMrAVhQc0vjOgsYJ5s= krakjoe@fiji
 
mornin
 
'nin
 
"Key is already in use"
 
:s ...
strange ...
must be supposed to use a different key ...
@rtheunissen think you still need to sign into travis-ci.org to grant permission
 
8:24 AM
Did that just then
@JoeWatkins Travis build has started.
Add to appveyor as well but not sure what to do next re: that
 
yeah, watching ...
I'll sort that ... it might take a few commits, apologize in advance for noise ...
 
That's okay.
 
got fails
 
Yeah var dumps
 
I can't find ds on appveyor ?
> OK
Project not found or access denied.
 
8:32 AM
Hmm.. you are an owner now.
Not sure if that would allow you to get into the appveyor config
 
yeah it doesn't ...
but stranger, why can't I see anything here: ci.appveyor.com/project/php-ds/ds
 
1 sec
It's under my username.. not the org
@JoeWatkins will have to find a different way to test var_dump
 
I had to do build under my name for appveyor
I committed the yml so you can change it when you can figure it out (I can't, total mystery)
let me get the build working first though
 
How to stop selection on the second $ ? regex101.com/r/pK7hD9/1
 
probably won't work, is missing deps for composer, not sure what they are though
 
8:48 AM
@Shafizadeh \$([^\$]*)\$
you don't want want "all" symbols
instead you want "all symbols except $"
 
@tereško In this year, you have helped me more than my teacher ;-) !! Thank you buddy (both Programming and English prespective )
 
you can also use a lazy quantifier like \$(.*?)\$
 
^ that's a good solution too
 
@PaulCrovella Oh yeah ..! Sounds great
@PaulCrovella Why did you call "?" lazy quantifier ?
 
because that's the official name .. I think
 
8:53 AM
ow .. interesting
 
if you use just * it's greedy, it'll try to match as much as possible. if you use *? instead it'll try to match as little as possible - it's lazy
 
@JoeWatkins wtf is with those var_dump tests?
public ${0} => ... ?!
 
@PaulCrovella ha ha ..
 
@Shafizadeh that's what chat rooms are for. I have noticed, that people, who "grow up" in these type of environments (SO chat, IRC, newsgroups), learn a lot both faster and wider range of subjects
 
@Shafizadeh you can do the same thing with other quantifiers too, e.g. ? -> ?? and + -> +? ... for more info see regular-expressions.info/repeat.html#lazy
 
8:56 AM
@tereško Yes :-)
@PaulCrovella Ah, tnx for the link, I will take a look at it
 
@rtheunissen not exactly sure, didn't look very closely
they pass for me ...
 
@Shafizadeh if you want a truly excellent book on the subject, pick up a copy of amazon.com/Mastering-Regular-Expressions-Jeffrey-Friedl/dp/…
 
Locally here as well. If you look at the travis log..
 
btw, @Shafizadeh, did you manage finish your school project?
 
yeah I saw it ...
I'll have a look closely in a while, still trying to figure out av
 
8:59 AM
@PaulCrovella No, I don't need regex very much, 101 is enough for my cases ;-)
@tereško I did ... I want to buy a VPS tomorrow :-) (if God willing)
 
There are 3 things that developer are usually bad at: regex, SQL and javascript
 
Agreed
regex is really vague in first look ( My friend call it the language of God :-) )
 
those also happen to be things that make the difference between "average developer" and "good developer"
@Shafizadeh regex are actually subset of Perl (kinda in same way as json is subset of javascript)
 
9:10 AM
I suck so hard at windows
 
@JoeWatkins What's wrong with it?
 
hehe
@Shafizadeh all of everything
 
@AnmolRaghuvanshiVersion1.0 Can you see the image? (why it is "not found" for me?)
@JoeWatkins :-) what OS are you using?
 
9:15 AM
a proper one, but working on CI in windows ...
 
@Shafizadeh click on it
 
@AnmolRaghuvanshiVersion1.0 twitter is probably blocked in Iran
 
@JoeWatkins ah ..
@AnmolRaghuvanshiVersion1.0 This webpage is not available
 
@tereško ah, yes it is
 
9:16 AM
@Shafizadeh here ya go: i.stack.imgur.com/WXWTN.jpg
 
@Andrea @Ocramius we recently added just that into whoops a few days ago: github.com/filp/whoops/commit/…
 
did you sleep on your keyboard??
 
Wes
nope
it's base64 data :B
 
Wes
i love msie eating glue rofl
 
9:22 AM
@JoeWatkins I'm wondering if it's xdebug affecting the var_dump?
Watching a movie with the ms then sleep.. will finish and publish tomorrow.
Thanks for your help re: appveyor
 
I'll disable xdebug on travis, see how that goes
 
Saw the commit, thanks. Watching..
 
not allowed to create new builds on appveyor now
@rtheunissen av broke ... gotta pop out for a while, should come back to life if you add the right hook ...
 
9:40 AM
@tereško :D
 
10:06 AM
@JoeWatkins webhook is still there. You're an owner again :p
 
Should I write code for those users, who their browsers doesn't support js ? (or js is deactivate on their browsers)
 
@Shafizadeh I would. Something along the lines of: "The site you are currently viewing requires JS enabled to be fully functional, See more information here."
 
good idea
but some users even doesn't know what is JS
For example there is a button in my website for who wants to write an answer for a question, He has to click on that button to see that textarea (in first it is hidden and it shows by JS)
this idea is wrong? and I have to show it in first?
 
10:38 AM
@Shafizadeh then they won't have it disabled
Progressive enhancement is a strategy for web design that emphasizes accessibility, semantic HTML markup, and external stylesheet and scripting technologies. Progressive enhancement uses web technologies in a layered fashion that allows everyone to access the basic content and functionality of a web page, using any browser or Internet connection, while also providing an enhanced version of the page to those with more advanced browser software or greater bandwidth. == History == "Progressive Enhancement" was coined by Steven Champeon at the SXSW Interactive conference on March 11, 2003 in Austin...
also, I think this is what you might be aiming at
the other term is this:
Unobtrusive JavaScript is a general approach to the use of JavaScript in web pages. Though the term is not formally defined, its basic principles are generally understood to include: Separation of functionality (the "behavior layer") from a Web page's structure/content and presentation Best practices to avoid the problems of traditional JavaScript programming (such as browser inconsistencies and lack of scalability) Progressive enhancement to support user agents that may not support advanced JavaScript functionality == A new paradigm == JavaScript historically has had a reputation for bei...
 
10:53 AM
Thank you @tereško
@tereško Look, that textarea is containing some educations about markdown-pattern for who don't know to work with. Also it has a simulator under itself which simulate the final-output. Anyway I want to say, all of that textarea is almost 200 lines of code. So should I print it for every post? (while just 2 or 3 users intend to use it (write a answer))
Don't seems optimize to me ^
 
@Shafizadeh give people without javascript the textarea and a link to a help page about markdown - the preview and any contextual/interactive help would fall under "enhancement"
 
eem, I don't know, maybe this way is the best option
@PaulCrovella Or instead of that link, I can append those help via JS if users want
 
11:25 AM
if user does not have JS, then you cannot use JS to append the help
 
11:50 AM
to hell ..! Who have disabled JS in his browser, isn't deserve the help
 
12:20 PM
"It's quiet." said Roobarb.
"Too quiet." said Custard.
 
Wes
"sssssshhhhhh!" said Mustard
 
12:37 PM
HIIII guys!
 
@Wes youtube.com/watch?v=X6ekzjTVNeY volume and casual racism warning.
 
It's a 'hypertext link' that takes you from one 'website' to another 'website'.
 
LOL I know that!!!!!!!!!!!!!! What's Roobarb ??
 
it's clearly a very small chair
 
12:43 PM
@Shafizadeh not too long ago, disabling JS in the browser was a good practice recommendation
 
Wes
@Danack lol
 
63
A: Why do people disable JavaScript?

haylemOne disables JavaScript in a browser environment because of the following considerations: Speed & Bandwidth Usability & Accessibility Platform Support Security Speed & Bandwidth A lot of applications use way too much JavaScript for their own good... Do you need parts of your interface to be ...

 
Wes
@Danack whistling dixie land now. i'm not racist, i just like the song
 
I wonder if there are people who whistle dixie specifically for the racism
 
@PaulCrovella you mean they ain't just whistling Dixie?
And yes.
 
12:53 PM
like they don't even dig the tune, but YAY RACISM so fuckit
 
Hi. :D
 
I disable my JS in my phone broswer :)
 
I am a JS addict.
I love JS powered websites, so kewl. :D
 
1:11 PM
@Gordon Really interesting ..!
 
Wes
@Andrew you must see 99% of internet broken then
@PaulCrovella i'd even have a confederate flag on my car if i had a red muscle car, but just because of hazzard. am i a bad person? :B
 
Yes. It'd be similar to driving round with Einsatzgruppen markings, because you think the uniforms looked really cool.
 
Wes
i wonder if i watch hazzard now i will think it's racist
 
@Wes you're a bad person for thinking the general lee was red instead of orange
 
^
 
Wes
1:19 PM
@PaulCrovella true that
 
@PaulCrovella NTSC TV sets?
 
what about them?
 
> When compared to PAL in particular, NTSC color accuracy and consistency is sometimes considered inferior, leading to video professionals and television engineers jokingly referring to NTSC as Never The Same Color, Never Twice the Same Color
It possibly was red on Wes' tv...
 
nope, he just sucks
 
Wes
nope, it was orange, but nearly red. "orangered" is the name, or "vermilion" #colornerd
@PaulCrovella also true
 
1:22 PM
I first learned the word "vermillion" from beetlejuice
 
why its don't works ? $results=mysql_query("SELECT COUNT(*) as total from anuncios;");
$data=mysql_fetch_assoc($results);
echo "go" . $data['total'];
 
!!docs mysql_query
 
Please, don't use mysql_* functions in new code. They are no longer maintained and are officially deprecated. See the red box? Learn about prepared statements instead, and use PDO or MySQLi - this article will help you decide which. If you choose PDO, here is a good tutorial.
 
1:27 PM
By now you should be using PDO. — Lucio Sep 13 '13 at 19:09
2013
 
like this $dbh = new \PDO($dbname, $username, $password);
$sth = $dbh->prepare("SELECT COUNT(*) as total from anuncios;");
$sth->execute();
print_r($sth->fetchAll());
 
No not like that no
 
okay that's pretty good
 
@Wes in my phone, unfortunately, I do :(
 
1:38 PM
Packagist Y U SO SLOW!?
 
i did $dbh = new PDO('mysql:host=' .$servername .';dbname='. $dbname.';charset=utf8', $username, $password);
$sth = $dbh->query("SELECT * from anuncios;");
$row_count = $sth->rowCount();
echo $row_count; and now works
Thank you, :)
 
You might want to change your query to something like SELECT COUNT(id) from anuncios
 
Wes
^
 
Or whatever key you have in there
That way you can just do $stmt->fetchColumn(0);
 
@PeeHaa why not COUNT(*) ?
 
1:45 PM
I heard @Ocramius about that at some point. I think it was mysql not correctly optimizing it away
 
was.
today it's one of the many optimization myths.
 
Not sure. Could be.
 
It's not. a COUNT(*) has to verify that all selected fields are not null
that's how it's supposed to work by design, but of course the optimizer (lol, if it works) can catch it
I usually COUNT(1)
 
I was going to say that.....honest.
 
@Ocramius that's my point … but COUNT(1) is absolutely fine too.
 
1:52 PM
s/all selected fields/any of the selected fields
 
Isn't that the same difference?
 
Counting over ['foo', 'bar', null] returns 1, counting over [null, null, null] returns 0
 
Installing dependencies (including require-dev)
  - Installing myclabs/deep-copy (1.5.0)
    Downloading: Connecting...
Could not fetch api.github.com/repos/myclabs/DeepCopy/zipball/…, please create a GitHub OAuth token to go over the API rate limit
Head to github.com/settings/tokens/…
to retrieve a token. It will be stored in "C:/Users/appveyor/AppData/Roaming/Composer/auth.json" for future use by Composer.
 
Oh right
 
what's that about ?
 
1:54 PM
oh god what
oh are we talking about SQL
 
@JoeWatkins you poked the github API too many times. Re-run with --prefer-source
 
@JoeWatkins github has a rate limit. Or just go get a cup of tea.
 
@Andrea isn't SQL nice? :-P
 
@Danack this is on CI, keeps halting job ...
will try prefer-source, thnks @Ocramius
 
@JoeWatkins CI should either have composer auth or always run --prefer-source (travis CONSTANTLY halts because of that, for me)
(having ~100 repos doesn't help)
 
1:56 PM
first time I come across it ...
 
@Ocramius better than PHP. SQL's idea of NULL is very sensible, it's just different to NULL in most programming languages
 
And github have such a shitty attitude/scheme for generating read only keys......
 
Oh, yeah, I like that you can't compare to it
 
@Ocramius yeah, it's a bit like NaN but for data
 
1:57 PM
@Danack I was actually thinking of building a tiny access token rotator
 
SQL actually has a consistent meaning for NULL: missing, unknown data. PHP OTOH, lol
 
@PaulCrovella the cardinality of [[null]] is 0 in most RDBMs. Good luck in taking the SQL92 spec as a reference :-P
The only one that doesn't work like that (IIRC) is MsSQL
note: I'd love to be able to take SQL92 as a reference, but then shitheads and benchmarks happened, and now we have PL/SQL, MySQL, Oci, MsSQL and other stuff
 
Not to mention shitty abstractions / data ccess layers
 
Build your own, if you feel like you got the time to re-do all the hard integration work
 
with blackjack?
 
2:02 PM
And loads of whisky
(you'll need that)
 
@Ocramius tried that once. Was horrible
Which is exactly my point
 
Weird stuff: PDOStatement::rowCount is often rows affected, not rows produced. It returns 0 for SELECT in SQLite.
 
just half the matrix >.<
 
Yeah. Soo much pain in there :(
 
bah, working on something else - SQL rants are not healthy
 
2:05 PM
(Last night I was wondering why my login endpoint couldn't find the email address. rowCount's fault.)
 
@Andrea that's on the Statement … in mysql at least affected rows are bound to a statement … rowCount is not known beforehand and only determined by the client based on the number of received rows.
 
@bwoebi huh, weird
 
it wouldn't be a proper database abstraction if it didn't leak
 
@Andrea yeah… mysql protocol is weird :-D
 
MySQL and SQLite have completely different ideas of what rowCount does then
 
2:09 PM
rather the PDO layer is misnaming things there…
 
Wes
@Andrea mysql has PDO::MYSQL_ATTR_FOUND_ROWS, though
 
@Wes oh, is it customisable?
 
Wes
yes - but it's a mess anyway, there are other rules
for instance rowCount is a boolean when doing INSERT INTO ON DUPLICATE KEY UPDATE iirc
returns 1 when inserts 0 when updates
there is something else too but i don't remember it, it's about LIMIT
 
2:27 PM
Haaaaaaaaaaands
 
Hi @room
whats the best way to save a number with multiple decimal point (i.e. 1.444432353) in a sql db?
 
@CiaranSynnott usually via a DECIMAL type
 
@Ocramius thats wai though, but you can t have Decimal(1,7)
so for example the number 1.0044032 will not store in 1,7
Figured it out usog double :)
cheers!
 
@CiaranSynnott Why do you have a float in the first place? Are you measuring a physical quantity like the resistance of a circuit?
@Ocramius Is there a good name for an 'stub' environment where an app is run in isolation i.e. no database, no github calls. I usually use 'standalone'.....but it seems kind of weird.
 
2:44 PM
@Danack not sure whatcha mean :)
 
So the context is, I generate the config for an app by calling a little script through genenv -p data/config.php data/envRequired.php autogen/appEnv.php centos_guest,dev which generates the config settings that are appropriate to use for centos_guest and dev settings applied on top.
I want to add another bit that says "use the config settings where all SQL implementations are replaced with stub ones. All API implementations to services like github are replaced with stub ones...."etc
stub_all_the_things
...that kind of works.
 
no_kangaroo
 
I have used return; instead of break; in the one case of switch() function. all fine, just I want to know is that standard?
 
3:08 PM
@bwoebi So static closure is useful after all :)
 
@Shafizadeh If the case calls for it, that's perfectly reasonable.
 
good ^
 
is it a bad practice to have a factory inside a factory ...and so on ??
 
3:24 PM
class RecursiveFactory implements FactoryFactory //provides itself
 
Wes
@Andrew code?
a factory using another factory is fine
 
@Wes Haven't coded anything yet, but I just wondered :D
I can see why a IoC container maybe needed :D
 
Wes
3:40 PM
@Andrew meh
automatic injection is cool but most of times not needed
 
I guess it depends but I actually haven't used it before so I cant say
isn't one of the purpose of IoC container is to avoid factory inside factory, and eventually do all the DI and factory on itself??
 
FactoryFactorys must be where you get IteratorIterators.
 
@JoeWatkins where did you find all these pics ...lol
 
the interweb has them ...
 
Wes
3:55 PM
@Andrew i'm saying it adds unnecessary complexity. depends on what you are doing... if you realize you have so many classes that injecting stuff is taking a big part of your time then you should start thinking using an automatic dic, otherwise imho it's better if you do it yourself... especially because teaches you something important
also factories using other factories... you can find them in dic containers too, but you don't have to construct them yourself
 
@NikiC yes and now shut up, lol … Well, yea… it has some performance advantage, but no real utility still.
 
@Andrew kinda yes, but sometimes is the only reasonable solution that you have
of course your factory shouldn't be producing a factory
 
01:00 - 16:0016:00 - 00:00

« first day (1940 days earlier)      last day (2999 days later) »