Drupal 8 First Impressions

I took a break from Drupal development for about 2 years, and decided recently (largely for practical purposes) to dive back in. I had spent many years developing websites in Drupal - I started back in 2005 using Drupal 4.7, and I have developed websites on every version since, except for Drupal 8, which came out just as I was taking a break. I had done some early beta testing on it, but hadn't gotten to develop any sites using it.

So I took an afternoon to have a go at it. I first tried a standard install, downloading the package, unpacking it locally, and doing the standard install. It was as easy as Drupal usually is, and it seems fairly straightforward - no changes on the admin side that didn't look at least a little familiar.

But as a back-end developer, using command-line tools, like drush is essential. And that's when things got a bit, well, janky, in my explorations. Drush has a new version, 9, which has two unfortunate oddities: 1) it requires Composer, and 2) only works with sites using Drupal 8.4 and above. So if you are maintaining sites that are Drupal 8.3 and under, and also building sites with the current version of Drupal (Drupal 8.5.2) somehow you have to maintain two versions of drush. But, luckily, I did find the Drush Launcher which can make maintaining multiple drush versions easier.

I have to admit, I'm spoiled by Python's pip, so I assumed Composer would be comparable. But, alas, no. It isn't even close. The good news, is you can install Composer locally to one project, which I guess might help with the multiple drush problem above, and can be sort of similar to Python's virtual environments.

The bad news is multi-fold. First, installing Composer is a pain. It's not like apt-get install python-pip. It's weird and annoying. Second, it's slow - it takes quite a while to install all of the dependencies for Drupal. Third, if it fails for some reason (a failed php dependecy, for example,) it doesn't clean up properly - it leaves stuff in place, so that when you go and fix the dependency, then come back to re-do a composer create-project, it will fail because it didn't clean up after itself. And there are a lot of php dependencies you might not think of, so you'll likley have to try to install, delete the folder the install created, fix the dependency, then try again.

I'm really not sure what we're gaining here by using composer, but I expect to wrestle it all into a working development workflow soon enough.