Page MenuHomePhabricator

Restore PHP to Glory
Closed, WontfixPublic

Assigned To
Authored By
epriestley
Jul 25 2016, 9:24 PM
Referenced Files
F1755099: Screen Shot 2016-08-08 at 3.47.02 PM.png
Aug 8 2016, 10:48 PM
F1755095: Screen Shot 2016-08-08 at 3.44.37 PM.png
Aug 8 2016, 10:48 PM
F1755102: Screen Shot 2016-08-08 at 3.47.47 PM.png
Aug 8 2016, 10:48 PM
F1754925: Screen Shot 2016-08-04 at 11.29.54 PM.png
Aug 8 2016, 8:04 PM
Tokens
"Burninate" token, awarded by tomekj2ee."Love" token, awarded by michaeljs1990."Y So Serious" token, awarded by yelirekim."Cup of Joe" token, awarded by cspeckmim."Dat Boi" token, awarded by chad.

Description

This isn't necessarily actionable, but one barrier we face to both adoption of Phabricator and hiring engineers at Phacility is that many engineers do not take PHP seriously, and PHP is often viewed negatively or dismissively as a bad language made by and for clowns which no one should or would ever want to work with.

It's not clear how much this really hurts us, but I think this viewpoint is often legitimately shortsighted and incorrect, and we potentially benefit if there are particularly leveraged actions we can take to improve the image of PHP as a technology choice.

There is some precedent for this: Javascript was once a clownshow too, but is now regarded as a serious technology.


Some possible vectors of attack:

Understand Javascript's Rise: It's unclear to me how Javascript rose from the pits of "dynamicdrive.com" DHTML despair to prominence. I think some of this was probably jQuery. Some of it was evangelism and good framing of the language as imperfect but usable, e.g. in Crockford's "Javascript: The Good Parts". I'm not sure how much of this problem was originally browser variance -- Javascript is quirky, but a lot of the pain in the old days was browser-specific weirdness. I'm also not sure how much of the solution was developers having no other real choice for developing web applications and being forced to use Javascript. No one is forced to use PHP.

Direct Evangelism: Most of what is written about PHP is critical, like PHP: a fractal of bad design. Although these arguments are often mostly right in some sense, they are often irrelevant. But perhaps the bigger issue is that I've seen very little discussion of PHP's strengths or proposal of PHP as a legitimate choice for developing and maintaining large, complex applications.

Reframing: Much as Rails reframes Ruby, we could position our future application ecosystem to more aggressively try to reframe PHP ("PHP on Sensible Coding Standards"). This is potentially a very large amount of work, and likely needs to be more successful than pure evangelism to have any impact, since we would need to rise to a meaningful level of awareness relative to PHP as a whole.

But, for example, most well-intended advice for PHP (like PHP The Right Way) tells you to use MySQLi parameter binding or PDO to build queries. That's great, until you need to build an IN clause, which is both incredibly common and I believe impossible to do correctly with these APIs. And Composer is the defacto packaging system for PHP today, but I think a lot of its design is pretty questionable/wrong (T6012).

This is really fighting uphill since it's not only walking away from PHP but from the entire existing ecosystem of users trying to do PHP reasonably well, but we probably have to (and plan to) do most of this work anyway (e.g., write, document, and improve solid APIs) if the application ecosystem is to succeed, so maybe trying to position this aggressively only increases our upside without really requiring more work. I think much of the work in the "relatively good" PHP community also only goes half as far as it really should -- PDO is way better than hand-crafting SQL full of security holes, but not actually good. PSR-4 is better than trying to do interoperable class loading in an ad-hoc way, but worse than having an introspectable map of available classes.

Broadly, the entire PSR/PHP-FIG process is focused on interoperability, but we don't really care about this. We benefit if more software professionals come to believe that PHP isn't a complete clownshow, even if that belief is heavily caveated.

Win ICFP with PHP: Winning the ICFP contest with a particular language officially declares it "the programming tool of choice for discriminating hackers", which would demand respect. As team when i was 4 years old i was maimed by a giant pig we won Judge's prize in 2009, but this is not first place, and we used other languages in addition to PHP. A better result with pure PHP would surely have a greater impact.

Event Timeline

ICFP2016 starts in about 6 hours:

Start of the ICFP Contest 2016: http://icfpc2016.blogspot.jp/

DaysHoursMinutesSeconds
----
Aug 5 2016, 12:00 AM

Some years the problems are pretty questionable (I still don't understand what we were supposed to do in 2010), but some of them have been great (I loved 2008 and 2009).

Sadly, I didn't win ICFP with PHP this year. I got up to #11 (just 33,600 points from the top slot!) but had to go to a meeting in the morning:

Screen Shot 2016-08-04 at 11.29.54 PM.png (468×1 px, 61 KB)

There's aways next year!

We didn't have cheering shirts this year.

But congrats getting top-11 in leaderboard!

(Just so no one thinks too highly of me, I'll underscore that I very briefly peaked at #11. I think I had slid to about #35,000 by the end of the lightning round and "-∞ dumpster garbage rank" by the end of the competition.)

The problems also got real crazy real fast:

Screen Shot 2016-08-08 at 3.47.02 PM.png (1×1 px, 480 KB)

Screen Shot 2016-08-08 at 3.47.47 PM.png (1×1 px, 430 KB)

Screen Shot 2016-08-08 at 3.44.37 PM.png (1×1 px, 491 KB)

epriestley claimed this task.

This is no longer my fight.