Categories
Programming WordPress

Ten Commandments for Automated Testing

Though Shalt Write Tests

If you are not writing tests, none of the rest of these matter. You must always start somewhere, and getting some tests is better than not having any.

Though Shalt Prove Bugs Exist With Tests Before Fixing Them

A bug report is one of the best times to write a test. And one of the worst feelings as a developer is fixing the same bug over and over again. Test driven development isn’t something that always works for features, but test driven bug fixing always leads to a concrete issue being fixed.

Though Shalt Aim For High Test Coverage

You don’t need to get 100% test coverage for almost everything. It’s often an unachievable target for legacy software projects, but that doesn’t mean we can’t aim for high coverage. Aiming for high coverage allows you to take calculated risks on where the return on writing a test is low

Though Shalt Setup Test Processes Whenever Setting Up A Project

This should be as innate a process as possible and you should never have an excuse to not write tests. By having your test infrastructure as a part of your boilerplate, you reduce the friction of writing tests and it can be a normal part of your development.

Though Shalt Understand the Code You Test

It’s unrealistic to expect someone to write tests without knowing how and why code works the way it does. It’s why it’s best not to go back and add tests to old code but instead to get in the habit of writing new tests for new code or when changing existing code.

Thou Shalt Never Trust The User

User entered data is one of the most important things to test since it’s something that is going to be hard to predict and the area where you have the greatest likelihood of a security issue. Tests will help safeguard your application.

Though Shalt Never Merge Code That Hasn’t Been Tested

Auomated tests aren’t perfect. There is no substitite to a human doing a real test, but when you get a high amount of test coverage, you can deploy with higher confidence without using as much human testing time.

Though Shalt Never Delete or Ignore Tests Without Removing Code

Deleting or ignoring tests without removing code is tantamount to having never written the tests in the first place. If you’re having problems with your tests, you are better off fixing them since…

Though Shalt Never Allow Flaky Tests to Remain Flaky

Inconsistent failures should be fixed as tests that provide false failures can reduce your trust in your tests. Some of the areas it’s important to consider when testing include anything related to time and anything that relies on the network.

Though Shalt Never Trust The User

Seriusly. This is important enough to mention twice since user input is the most likely thing to cause a problem for your application.


My team is currently hiring for a developer to work on our RevOps team. If things like testing interest you, please check it out and apply.

Categories
Programming WordPress

Potential Tech Conference Talks

I am constantly thinking of new potential talks that I would want to either give or convince others to give. Some of these have been on my list for almost a decade, while others are relatively recent ideas.

Roles on a web team

There is a big difference between roles, jobs, and titles. I cosider a role to be the atomic unit and they bunch up into a job. So for example, a role is “Writer of CSS” and that might be a part of the “Front end developer” job. It also might be a part of the “Designer” job. I want to look at all the roles that need to be filled (I think there are somewhere around 100-200) in order to build, launch, and maintain a website and how successful teams are able to define jobs.

Improv for Web Developers

It’s been a long time since I did improv, but many of the things I learned from it are foundational things I use every day. This could be participatory; this could be a disaster. Just like an improv scene.

This is likely closer to a lightening talk than a full talk.

Axioms for the Web

Axioms are ideas we use to start our reasoning that are so fundamentally true, we use them to define what is true. They come from a Greek term that roughly translates to ‘that which commends itself as evident.’ They are phrases as simple as: A + B = B + A. One look at this phrase and we understand the truth within it.

I want to expand on a lightening talk I did a few years ago to look at what things are so fundamentally true for websites that they define what is true.

DUX – Developer User Experience

What is the experience of contributing to and using your code base like and how can we use lessons from user experience design to influence ways in which we improve it?

Interviewing developers

I’ve refined my interview questions over the last decade and think it could be interesting to share these questions, perhaps even doing a mock interview on stage. I might even talk about questions I used to use and why I don’t use them any more.

Foundations of HTTP

A look at the http standard, how it has evolved to http/2, how it is evolving to http/3 and the foundational concepts of http verbs and status codes that are incredibly relevant to all web developers.


Get in touch if you would like for me to give one of these at an event you are organizing. None of these are fully flushed out so they will take some time, but I think there would be interest in all of them.

Categories
WordPress

Random Thoughts on… Keynotes and WordCamps

Dave Bisset shared some of his thoughts in response to my random thoughts on travel and WordCamps post. One paragraph stood out to me:

Some organizers associate keynotes with “headline speakers”. I personally don’t like keynotes as a speaker organizer and in 12+ years with WordCamp Miami I only did two official planned ones. I’ve too often seen events have a single keynote that is often executed poorly – where it’s seen to put a spotlight on a local or national speaker that was meant to be used as a “see… see… our conference has someone important!”. You can tell this because their subject material didn’t apply to the majority of the audience – they were just there because they were a “big name”. I’m not saying keynotes are bad, but i’ve walked out of more awkward keynotes at WordCamps that I have feel good ones.

I’ve given three WordCamp keynotes and have also organized camps with and without keynotes. In that time, I’ve developed a handful of random thoughts on the topic.

  • Not every WordCamp needs a keynote. It’s far from a requirement.
  • When it is decided to have a keynote, I think it’s best to come in one of three flavors:
    • If you are a new camp and want to bring in someone who can really help build up your community.
    • If you have someone in your local community who should be given a chance to give “One Big Message”, a message that everyone should hear. The best one of these I have seen is Tracy Levesque at WordCamp Philly. Boone Gorges also gave a fantastic one at WordCamp NYC.
    • If you can bring someone from outside that wouldn’t normally be a part of the WordPress community who has an interesting thing to share. WordCamp Lancaster 2017 had a local computer science professor.
  • Keynotes should leave the audience asking questions of themselves, and this should be for just about everyone in the audience.
    • My WordCamp Baltimore Keynote from 2013 “Citizenship in the Open Source World” aimed to ask what does it mean to be a part of Open Source.
    • My WordCamp Philly 2015 Keynote “Why WordPress Works This Way” aimed to get the audience to question what philosophies they wanted to use in their decision making
    • My WordCamp St. Louis 2016 keynote was somewhat last minute, so I based it on my 2015 WordCamp Philly one. Though this time it was more based on “We can learn from something without emulating it exactly” and asked “What can we learn from WordPress?”
  • A poorly executed keynote makes a sizable portion of the audience question why they were there.
  • Keynotes are opportunities for “Big Messages”, not minutia. It’s not a time for “How”, it’s a time for “What”.
  • You should never take questions at the end of a Keynote. If you are giving one, it’s your stage and your message. The hallway is the right place for the conversation to continue.
  • Opening/Closing/Mid day keynotes all are ok.
  • I would rather no keynote than a bad keynote.
  • I would rather no keynote than an ok keynote.
  • A “regular talk” should not become a keynote simply because they are the biggest ”name” attending. Great keynotes and Great instructional talks are different
    • You still want to be careful with your scheduling. Don’t put another developer talk at the same time as Andrew Nacin preparing an “Advanced Topics in WordPress Development” talk.
  • It’s ok to save a good talk idea for when you are going to keynote. Or let organizers know in your application that you only want a specific topic considered if it would be a keynote.

Comments and ping backs are open: What are your thoughts on keynotes and WordCamps?

Categories
Art

Museums I visited in 2019

I went to 19 different art museums in 2019. No idea what my previous record was, but this destroys it.Already starting to look at exhibits and museums for next year, let’s see if I can get 20 in 2020!

New York

Gugenheiem

The Basquit exhibit was my favorite small exhibit of 2019. For as few works of art as it was, the power was incredible.

The Death of Michael Stewart, also known as Defacement, by Jean-Michel Basquiat

Whitney

Warhol, and Protests, and Color of the 60’s! The Whitney had a lot going on. Rachel Harrison’s mid career retrospective was a lot of fun to see, I also really love the rehang of the permanent collection on the 7th floor.

Alexander The Great by Rachel Harrison

PS1

Gina Beavers is someone who I haven’t been able to shut up about since seeing her works. Nancy Spero inspired me alot. Was especially powerful seeing her work in contrast to her husband Leon Golub’s work at Met Breuer in 2018.

Nancy Spero
Gina Beavers’ Van Gogh’s Starry Night rendered in bacon

MoMA

Back in the New York Groove. Bigger and more badass. It was odd going 4 months between visits, but for the increase in space, It was absolutely worth it.

Met

Play it Loud was a fun exhibit. One thing that the Met always reminds me is that Art is much more than Pictures and Sculptures, which is ironic since it also has an incredible collection of both pictures and sculptures.

Saint Jerome Praying in the Wilderness by Leonardo da Vinci

Met Brauer

This museum is not for long, as the space is scheduled to become the temporary home of the Frick Collection, but I like that they are doing a long term show entitled “Home is a Foreign Concept”. What has really made this place special in 2019 for me was the individual artist shows which allowed me to see in depth work by a number of artists.

Freedom of Speech by Faith Ringgold

Los Angeles

LACMA

Going to an art museum and having a 3 year old show me some of her favorite works was a different experience and one that was a lot of fun since my friends I was with are incredible. I need to go back to see more of this musuem.

Hammer

My team took an evening last year to do some team building wandering together around the Hammer. Getting to know my coworkers better by discussing art and learning just how many of us had studied art in some way was awesome.

Getty

The views were better than the art, but the art was also really good. I mostly prefer more modern and contemporary art, but the Bauhaus Beginnings show was great. Awesome to see some of the educational materials and lessons that the great artists used to teach with at that transformative institute.

Minneapolis

MIA

This was like a mini version of The Met. Almost all the greats were represented, and some phenomenal examples of a lot of different types of art. I want to go back as I didn’t give myself enough time to fully appreciate all that they had.

Lake Superior Landscape by George Morrison

Walker Center + Sculpture Garden

Incredible collection of art and highly inspiring. The individual shows and the main collection (formatted around the themes of Self, Inside, Outside, Everyday, Everything) were fantastic. The Sculpture Garden is something I want to spend many more hours exploring. Especially want to look at every Jenny Holzer bench. And eat that damn cherry.

Columbus

Wexner Center

I am lucky in that I got to see the Jason Moran exhibit here and then see it again when it came to the Whitney. This was a smaller museum, but I enjoyed how it had multiple areas that could be setup in what appeared to be isolating ways. I often felt alone in galleries, but in a good way.

Billy Ireland

If you are ever in Columbus, I highly encourage you to check out this political cartoon museum. It’s free! It’s also not very large but both exhibits I saw were extremely informative and entertaining.

Philadelphia

Pennsylvania Academy of the Fine Arts

This one is kind of cheating on my behalf, since I was here for a conference and other than 20 minutes at the end of lunch, I didn’t spend much time looking at the art.I really enjoyed a piece by Lee Krasner who I don’t feel is given enough credit or space in art museums.

Boston

MFA

I was in Boston for a wedding and decided to take a vacation day and visit the MFA. I was not disappointed. It was a large museum, so I’m glad I gave myself a full day. I loved how they had the Kehinde Wiley/John Singer Sargent duality. Listen to Wiley talk about Sargent.

San Francisco

SFMoMA

Before visiting SFMoMA, I would have told you that MoMA was the premier modern art museum. Now I’m not so sure. Everything was incredible but the Leichenstein Nudes are what stood out to me. I had just started my own work on nudes (contact me for the Instagram I am posting those on if you are interested) so it was very timely.

De Young

I was a bit underwhelmed by this museum. I think in part since I had just been blown away by SFMoMA and expected a premier institute in a city like San Francisco to have more.

St Louis

St. Louis Art Museum

I was very impressed with the German art. The Contemporary collection was incredible and the Shape of Abstraction was the one exhibit I visited this year that was so good I bought the book.

Chicago

Art Institute of Chicago

A fitting final museum of the year for me to visit as it is also the first art museum I ever went to. This is the second time I visited as an adult and I could spend hours with the Chagall windows. I also had a little fun using google translate.

Categories
Programming

My developer interview questions

I have interviewed over 100 candidates for developer positions over the last decade. In that time, there has been one consistant refrain on twitter: “Interviewing is broken”. And as someone who has been on the other side of the interview, I agree. I’ve evolved my developer interview questions with this in mind.

I’ll note that this is what I’m using now and will likely evolve. My questions aren’t tricks, they aren’t academic, and they don’t necessarily have right and wrong answers. My goal with them is to start some conversations and try to learn how a candidate thinks and reacts.

I’m a bit worried that putting these out here will “ruin” them, but I also think part of what is broken about interviewing is the idea that things need to be a surprise and we need to see how people think on their feet. The majority of the time, this isn’t how we work so why interview with that in mind?

Most interviews, I use just two questions as my base. For more experienced people, I have a third I use as well if I’m trying to understand if they are truly senior. I also am generally looking for people who will work throughout the stack, even if they have a specialty. I also don’t expect candidates to be experts at the entire stack. My developer interview questions are thus general and not generally language specific.

How do you ensure you write quality code?

What I’m looking for here is that they have a definition of quality and they put in some sort of process to make sure it happens. I’m trying to weed out people who won’t write tests, while also learning if someone is going to be overly cocky or has lone wolf tendencies.

Some of the best responses to this are questions along the lines of “How should I define quality code” as it shows they don’t just rush to solutions, they try to define the problem better.

I usually end up having follow up questions here depending on how they answer. If they mention automated tests, I might ask how they decide what should be a unit test and what should be a functional test. If they mention code review, I might ask what are the big things you look for when doing code review.

Hypothetical situation: The CEO says the homepage is slow

For this one, I put on my old Simulation Director hat from Model UN and we go through a hypothetical situation where you get an email from the CEO saying the homepage seems slow and asking you to look into it. Totally hypothetical, no one has ever gotten this email at any job ever.

I’m trying to see how people approach being given minimal information and needing to debug. I’m trying to see if they look for tools, such as asking me what metrics they have available. I want to know if they can identify backend performance issues vs. front end performance issues.

This question goes in a different direction every time as I tend to follow the path the candidate leads me on. Thankfully, I’ve written and encountered a lot of slow code in my life, so I am able to go in many different directions.

In this question, I might ask them for ideas for how they would fix some issue. I might see how familiar they are with concepts like RUM, Server Push, and using EXPLAIN in sql.

*Programming Language You know* has changed a lot, what’s your favorite new feature?

This is my experienced developer question. I’m trying to make sure they stay current and continue to learn. I’ll follow up often with “What do you like about it” and then I’ll ask them to explain why it is better than some older alternative and then I’ll ask them how they would explain it to a more junior colleague.

I always pick the language that their resume seems to most emphasize and I only use this for people who have been coding in it for at least 7 years. I’m hoping to see someone that stays current, that has opinions, and can share them.


The candidates I am usually looking for are people who like to learn, people who can debug, and people who aim for greatness, but know that often perfect is the enemy of complete. I hope my developer interview questions help me find them and I hope they want to work with me after the conversation. I hope to always work at places that pass the Jorbin Test so people will want to work with me.

Do you think my questions could be better? Do you see flaws in them? I would love to hear your feedback so I can itterate. To paraphrase Akin’s Third Law:

Interviewing is an iterative process. The necessary number of iterations is one more than the number you have currently done. This is true at any point in time.

Categories
Random Opinions WordPress

Random Thoughts on… Travel and WordCamps

While looking at the list of WordCamps that I’ve spoken at, it got me thinking about travel and going to WordCamps away from home. Here are some random thoughts on that matter.

  • In General, I think it’s best for local camps (i.e. not specialized events like WordCamp for Publishers or regional camps like WordCamp US) to be majority local.
  • Defining local is hard. Am I local to Montclair? It’s less than an hour for me to get there via train. If yes, does that also mean I am local to Philly? I would say I’m not really local to either of them even though they are all NYC Suburbs.
  • I like to think of things as being in kind of four different classifications:
    • Very Local. This is the place you live or the place you work.
    • Day trippable. These are the places where it’s super realistic to wake up one morning and decide “I’m going to visit X today”. It’s generally things in like a 2 hour not flying radius.
    • Hard Day Trips. These are the places that it is possible to do a not flying day trip to, but it’s not going to be the easiest trip. If flight times work, a flying day trip is completely doable.
    • Overnight trip required. There is no way around, this is real travel
  • For the past few years, I’ve limited myself to speaking in the first 3 categories. Partially to take it easy on travel, and partially since I took 2018 off from speaking entirely.
  • It’s important for people who can be considered “Names” to make space for the next group of contributors and this includes not speaking all the time.
    • Sidenote: I was chatting with another core committer recently and we noted “We are not the future of WordPress”. I don’t intend to go anywhere, but I also recognize that my strength for the project today isn’t to be the loudest voice.
  • I’m not at all convinced that “Names” sell tickets for local WordCamps. I am convinced that developing and nurturing a quality community sells tickets to WordCamps.
  • It’s important to visit other communities to meet people, but that doesn’t mean I need to speak. One of my favorite camps was WordCamp Seattle 2014 as I got to meet a number of people and see some old friends that it had been years since we spent time in person.
  • My first ever camp that I went to with no connection to the local community was super important to my growth as it allowed me to meet a lot of folks, many who became long time friends. WordCamp Phoenix 2011 was a special event.

Overall, I think going forward I’m going to try to travel a bit more, while staying firmly in my local and near local communities.

What are your thoughts on WordCamps and travel? How do you approach your decisions on when to fly to a different city for a camp?

Categories
About Aaron Current Events mostly pointless.

Top 10 posts I didn't publish this decade

Over the last 10 years, I’ve not published a lot. By that I mean I’ve started drafting a post 198 times and left it in purgatory. I also have 4 that have sat for over a decade. Some of those are things I’m working on, but the vast majority of those will never see the light of day. Here are 10 excerpts of things I should delete, but haven’t.

14 posts with no title

Some of these are clearly me testing out bugs, others are me playing with Gutenberg as it started to take shape, but the one that stood out to me was about air travel and I last worked on it 14 December 2011. It’s one that has this as the last written paragraph

The story I grew up hearing of my grandparents first date was that they went to Midway Airport to watch the planes take off (and that my grandfather invited his future in laws to tag along). Going to the airport was something that people would look forward to doing. It was something special. It is something i worry I will never experience again.

A child theme developers guide to Post Formats

This post has no content, but it feels like it could have been interesting to write. It’s also from 2011, only much earlier: 27 February. It’s also much less relevant today, so it should likely go in the trash.

Accessability

6 different posts about Accessibility that I didn’t write

Accessibility is about making the web usable for everyone.
Accessibility is about understanding other people.
Accessibility is about
Accessibility is about people.
Therefore Accessibility is important.
Happy Global Accessibility Awareness Day.

I started drafting this one in 2015 right around Global Accessibility Awareness Day. I am guessing that I stopped and din’t publish it when I couldn’t think of a good third beat. That or I saw a squirrel.

Axioms For The Web

I have two different drafts intitled Axioms for the web. Both are fundemently the same: they are based on a talk I gave at a Big WP NYC in 2014. This is one I would love to actually finish and publish. It starts:

Axioms are ideas we use to start our reasoning that are so fundamentally true, we use them to define what is true. They come from a Greek term that roughly translates to ‘that which commends itself as evident.’ They are phrases as simple as:
A + B = B + A

One version is 1079 words and the other is 1377 words, so hopefully this is something I can actually do. Maybe 2020 is the year I finish this 6 year old post.

Can WordPress 5.0/Gutenberg be released in 2018?

This was a potential roadmap to getting Gutenberg into WordPress core in 2018. I wrote this post up at the tail end of September of 2018 and while I was getting feedback on it, the post announcing the 5.0 release came out. My post was going to propose releasing on December 4th which ended up only being 2 days off when WordPress 5.0 came out.

Degrassi still goes there

I didn’t know that Degrassi: Next Class season 3 was premiering on netflix yesterday, but when I sat down intending to veg out after a hectic week with little sleep, It was there and I couldn’t have been more excited.

That’s the one and only paragraph of my love letter to Degrassi. I just rewatched all four seasons of Next Class and it made me wish the show never left the air

Introducing Slidedown.js

This was a nodejs presentation tool that I worked on for a few years that never really got beyond the point that only I could use it. I stopped using it soon after I finished it, since I can’t seem to actually stick with a single JavaScript library for building slideshows. The repo is still public if someone wants to use it. My goal was to have a set of themes, each named after a bar. The first one being named after my college bar, Remies.

The Situation in Mali

Back when I was the simulation director of a security council simulation, I did a lot of reading and writing about situations happening in the world. This included conflicts that didn’t get much attention, such as this March 2013 post about when the Tuareg declared independence for the region of Azawad. Sadly, this is a conflict that still persists to this day, but one that you need to search for information if you want to stay informed.

WordPress and PWA

The emergence of Progressive Webapps are one of the most exciting development for the open web.

That’s as far as I got. Despite having built aaron.jorb.in as a PWA, I haven’t taken many further steps. I do think that many parts of PWA have a lot of potential to improve WordPress, but haven’t written them down. Maybe this is another 2020 post?

Rejected Taglines for WordPress 4.6

A little bit of humor that I must not of thought was funny enough. Here are the 3 taglines I had written. I’m guessing I was hoping to add more before publishing it.

WordPress 4.6 is living in the future so the present is it’s past

WordPress 4.6 has a pikachu hidden inside.  Take a look inside for it

Thanks for Updating.  WordPress 4.6 is humble with a little bit of Kanye

Random Thoughts

Conference Badges, Scaling, WordPress Contributor Retention, Half Baked Ideas, committing to WordPress Core, Gutenberg…seven weeks in, Why I contribute to WordPress, WordCamp Lancaster.

What do those have in common? All are things I started a random thoughts post on but never finished it. Maybe one of these will join the 15 random thoughts posts I have written.


Overall, I published more than I let waste away in draft, but I should take my own advice from Always Press Publish from when I was blogging every day

It’s easy to fall in the trap of wanting something to be perfect before you share it. It’s similar to the “one more feature” trap that hurts the ability for software to be released. By having a deadline of every single day something needs to be published, I force my self to understand that perfect is the enemy of complete.

What do you have sitting in your draft pile from the last decade? I’m sure you have some good stuff there

Categories
Code Programming WordPress

__DIR__ vs dirname( __FILE__ )

Calling a constant should always be faster than a function call, right? PHP contains two different ways to get the directory that a file is currently in. __DIR__ is a magic constant added to PHP in 5.3. The official PHP documentation specifically states: “This is equivalent to dirname(__FILE__).” Equivalent in return doesn’t necessarily mean equivalent in performance though, so I decided to test the performance of both accross a couple of variables.

Testing Methodology

When running lots of tests, I’ve found that travis-ci can be a big helper. You can define the matrix of the tests you want to run as your testing matrix and then use the results. So I setup a repo for my tests. The repo contains four main pieces:

  1. A file generator which creates the code I’ll actually run the performance test on.
  2. A test running script which runs the actual tests.
  3. The travis.yml file to define my tests matrix
  4. Files used for the actual test. This is not linked, there are 400,000 files. The generator shows them off.

My test calls the function I am looking for 100,000 each. One run has all the files in 1 directory, and the other has one file per directory. I wanted to rule out the possibility that a single directory could affect this call.

I ran this test on six version of PHP: 5.6.40, 7.0.33, 7.1.27, 7.2.15, 7.3.9 and 7.4-dev. Each test did 650 runs and I looked at the user time for each of those runs. This means that I called both __dir__ and dirname( __file__ ) 130,000,000 times each. I then took the times for each of these runs and looked at that maximum (slowest) run for each and the 95% time ( the average between the 618th and 619th slowest) to rule out any extreme cases. Overall, the results between maximum and 95% are similar.

User is the amount of CPU time spent in user-mode code (outside the kernel) within the process. This is only actual CPU time used in executing the process. Other processes and time the process spends blocked do not count towards this figure.

Stack Overflow

__DIR__ vs dirname( __FILE__) Test Results

95% performance

Script5.67.07.17.27.37.4
dir ( 1 folder)1.42.762.082.512.271.3615
dir ( many folders)1.382.292.552.36152.651.57
dirname( 1 folder)1.58152.272.74153.242.411.5215
dirname( many folders)1.682.292.08153.292.68151.87

Overall, the results show that __dir__ is generally faster, but it’s rarely much faster. Consider that in the slowest run ( using PHP 7.2 and calling dirname( __FILE__ ) on multiple folders), each call took 0.0000329 seconds. The fastest run was 2 hundred-thousandths of a second faster. This is such a micro optimization that except under extreme scale, it’s unlikely you will ever notice a difference. That said, under most versions of PHP, __DIR__ is faster.

So: __dir__ or dirname?

At the end of the day, the performance of __DIR__ is ever so slightly better, but more importantly I think it’s clearer and easier to read. So I’m on team __dir__, but the performance is only a bonus.

If you have a different thought, or think that my testing methodology could be improved, please let me know in the comments below.

Categories
WordPress

This might be the first post ever published on WordPress using PHP7.4.

I have every reason to believe that this is the first post ever published on WordPress using PHP7.4. It’s likely coming a bit premature, but if you aren’t willing to have some fun, then why maintain upstream language compatibility of an open source project. I’ve worked on php version support in WordPress since PHP7.0 and made the first post using WordPress on php7.3, so this is becoming a fun tradition.

Yesterday I added code to WordPress core to fix a number of deprecations in PHP7.4. PHP7.4 is scheduled to be released on November 28, which is 74 days and 5 release candidates away. The goal for WordPress is that version 5.3 will fully support PHP7.4 and that version is scheduled to be released 12 November 2019.

The biggest deprecations in 7.4 that affect WordPress core are around magic quotes and

For plugin and theme authors, you’ll want to look into:

PHP7.4 features for WordPress Developers

It’s not just deprecations in PHP7.4 that WordPress developers can look forward to, but the PHP internals team has added some new features for us to use as well.

Typed Properties continue the evolution of PHP’s type system to allow for class properties to be type strict. The only Property types you can’t use are void and callable, otherwise every type decleration is supported.

Arrow Functions allow for simpler anonymous functions. I recommend only using these in callbacks such as with array_map in order to make your debugging simpler.

Coalescing Assignment is here as syntactical sugar. ??= allows for you to add default values easier.

If you see any errors or notices on this site, let me know in the comments. Assuming this actually publishes, then WordPress can be used with PHP7.4, but I only recommend it for those feeling especially adventurous.

Categories
Uncategorized

My friend’s Dads

I can’t say I knew John well, but his son has been a part of my life for half of it and for so much of that, my best friend. I can’t even say I knew John well, but his presence in my life provided a fewstrong and distinct memory.

Dan became a friend that I knew for my whole life from virtually the moment I met him. Hockey, baseball, the Dead: I had tons of things to chat about with a man 25 years my age.

The last time I saw John was at Tom’s wedding. John greeted me as a second son. He loved Tom and if someone was important to him, he was going to do his best to love him as well. John didn’t need a lot to be happy. A cold drink, some tasty meat and the people he loved would make him smile. He didn’t need much to make home smile.

Dan has this hockey game that involved picking the winners of each playoff series and talking some shit to each other. It’s a game his son introduced me to and Dan invited me to be a part of his league. It’s a game I look forward to playing every year.

The first time I hung out with John is a memory that will stay with me more than any other. You see, Tom and I had just turned 21 and John was happy to take us to the bar. We went to the top of the Landmark Inn, overlooking Lake Superior. And John bought us broke college students drinks. He wanted us to have fun. This was my first time meeting John but he treated me like he knew me forever. He became a friend instantly.

In jokes can take years to develop or in the case of Dan, an instant. The first time I hung out with Dan he demonstrated leadership in a way that authors spend years working on and it earned him the name Cap’n. Or at least I think that’s the story. It’s sort of lost to the annals of time.

This year, I lost my mom and two of my best friends lost their fathers. It’s pain that all of us will process and it’s pain inspired by memories of great people. Hug the people you love. Tell them you love them. Tell them every time you talk to them. John and Dan never met but im sure if they sat next to each other at the bar they would end up laughing and smiling. So today I’ll laugh and smile and be glad I had them in my life.