My experiment in bringing Drupal Module Upgrader back from the dead in less than 24 hours

By Gábor Hojtsy , 7 March, 2026
Claude Code plan to update transformations for Drupal 10/11

Drupal Module Upgrader (DMU) was created by Angie Byron and Adam Hoenich way back in 2014 at Acquia to help folks upgrade custom Drupal 7 modules to modern Drupal. It was magic. Cameron Zemek at PreviousNext built the crucial underlying library, Pharborist, which abstracted PHP manipulation into a generic dependency. Many relied on DMU to upgrade custom code, and it was even updated for Drupal 9; however, keeping it current over time proved challenging.

Rector came on the scene, well-built and actively supported. Pharborist—a library predating Rector that essentially did the same thing but lacked a large community—didn't quite survive. Yay for Rector, I say, but it was unfortunate for the tool that had supported our community for so long. Nobody had the time or interest to convert DMU's transformations to Rector. But DMU kept working, so for a while, it wasn't an issue. 

PHP 8 language changes

However, Drupal 10 introduced support for PHP 8, and DMU started showing serious problems. PHP 8 brought new language tokenization rules, and neither Pharborist nor DMU was up to the task.

Four years ago, Joao Ventura (at 1xInternet) forked Pharborist into an "official project repo" so we could continue making it work, and he collaborated with Joseph Olstad to bring DMU back to life. That allowed me to start chipping away at the Pharborist blockers, but I only got halfway before it became too complex for me to deal with.

Andy Fowlston at FABB picked up where I left off two years later, making various test and PHP compatibility updates to Pharborist. In 2024—10 years after the tool was originally created—he commented:

Hi, I'm completely new to the project, but was hoping I might be able to use it via drupalmoduleupgrader to help with a Drupal 7 upgrade.

Woah! Talk about longevity of useful tools! While many of his fixes landed, his final big pull request sat untouched, and DMU effectively became abandoned. There is nobody to fault here; I think everyone involved did their absolute best. People move on, but the code stays around. Still, even in 2025, there were people in the DMU issue queue wondering if it would ever work again.

Enter the LLM

Recently, LLMs have become not just popular, but significantly capable. It may very well be that a developer today would just use an LLM to upgrade a Drupal 7 module to Drupal 11. But what if we could resurrect a deterministic tool to help take a first stab at it? We could convert the transformations to Rector, but maybe not as a first task...

I hoped that taking Andy's most recent work and building on top of it would be a good, self-contained task for an LLM. So, I fed the PR to Claude Code to analyze and got a very thorough code review that looked great on a human scan, too. Then, I had it fix the bugs it found and add more test coverage. From there, we went on to fix dependencies and deprecation notices.

Suddenly, I was staring at a full green Pharborist test run that was even ready for PHPUnit 12—all in just a few hours. Woah! Who would have thought, after so many years!

But updating Pharborist was only part of the story. I continued working with Claude Code to update the module itself so it runs smoothly on Drupal 10 and 11. Once that was out of the way, I had DMU and Pharborist running fine, but it was still producing Drupal 8/9-era transformations.

This seemed like the hardest part, but the wonderful humans before me had added ample test coverage. This showed perfectly what the tool was supposed to do, allowing the LLM to understand and assess what needed updating. I had it make a plan (see screenshot above) and then let it run with it. 

The Result

In less than a day, the result is a whole new branch of Drupal Module Upgrader that works on Drupal 10 and 11, passing the full test suite. It makes a best-effort attempt to produce code compatible with the latest versions of Drupal core. I released Drupal Module Upgrader 2.0.0-alpha2 less than 24 hours after I started resurrecting Pharborist and DMU.

Should you use DMU for Drupal 7 custom code updates? It was never meant to be a complete solution and still is not one. But it can be an excellent tool in your toolbox—especially when combined with other tools to keep your project moving. Will it get active development going forward? No.

All in all, this little one-day experiment proved how modern tools can be used to save precious work created by very caring humans. Hopefully, it will be useful for the developers who come after me, helping them carry a few more Drupal 7 sites into the modern age!