Why doesn't my custom OutboundPathProcessorInterface work anymore? I wrote my own implementation of OutboundPathProcessorInterface to rewrite the URL of nodes to use the content of their field_project_url field.

namespace Drupal\mymodule\PathProcessor;

use Drupal\Core\Render\BubbleableMetadata;
use Drupal\Core\PathProcessor;
use Drupal\Core\PathProcessor\InboundPathProcessorInterface;
use Drupal\Core\PathProcessor\OutboundPathProcessorInterface;
use Drupal\node\Entity\Node;
use Symfony\Component\HttpFoundation\Request;

class MymoduleFieldRedirectPathProcessor implements OutboundPathProcessorInterface {

  public function processOutbound($path, &amp;$options = array(), Request $request = NULL, BubbleableMetadata $bubbleable_metadata = NULL) {

    if (isset($options['entity']) &amp;&amp; is_object($options['entity']) &amp;&amp; method_exists($options['entity'], 'hasField')) {
      $node = $options['entity'];

      if ($node-&gt;hasField('field_project_url') &amp;&amp; !$node-&gt;field_project_url-&gt;isEmpty()) {
        $project_url = $node-&gt;field_project_url-&gt;getValue();

        if (preg_match("/^\/node\/[0-9]+\/(edit|translate|delete|translations)$/i", $path)) {
          // dont alter operational paths
        }
        else {
          $path = $project_url[0]['uri'];

          dpm($project_url[0]['uri']); // 'http://url.com'

          $options['absolute'] = TRUE;
          $options['external'] = TRUE;
          $options['base_url'] = null;
          $options['prefix'] = null;
        }

        if ($bubbleable_metadata) {
          $bubbleable_metadata-&gt;addCacheableDependency($node);
        }
      }
    }
    return $path;
  }

}


The teaser of that view has a title, an image linked to the content, and smart trimmed version of the body field, also linking to the content. 

The value is appended, giving (for example) http://localhost:8888/myprojecthttp%3A//url.com.

This used to work, but I can't even get this right with older Drupal 8 versions. 

What am I doing wrong?
That's the right code of the processOutbound method
  public function processOutbound($path, &amp;$options = array(), Request $request = NULL, BubbleableMetadata $bubbleable_metadata = NULL) {

if (isset($options['entity']) &amp;&amp; is_object($options['entity']) &amp;&amp; method_exists($options['entity'], 'hasField')) {
  $node = $options['entity'];

  if ($node-&gt;hasField('field_project_url') &amp;&amp; !$node-&gt;field_project_url-&gt;isEmpty()) {
    $project_url = $node-&gt;field_project_url-&gt;getValue();

    if (preg_match(&quot;/^\/node\/[0-9]+\/(edit|translate|delete|translations)$/i&quot;, $path)) {
      // dont alter operational paths
    }
    else {
      $path = ''; //Don't use $path variable at all

      dpm($project_url[0]['uri']); // 'http://url.com'
      $options['base_url'] = $project_url[0]['uri']; //Add your url as base_url

    }

    if ($bubbleable_metadata) {
      $bubbleable_metadata-&gt;addCacheableDependency($node);
    }
  }
}
return $path;

}