Problem/Motivation
Drupal\feeds\EventSubscriber\PubSubHubbub.php is using
use GuzzleHttp\Url;
// Used to make other URLs absolute.
$source_url = Url::fromString($feed->getSource());
$hub = (string) $source_url->combine($hub);
Which are no longer existing nor supported on 6.0 version of the GuzzleHttp library.
Proposed resolution
Use an alternative for making URLs absolute and combining them.
Reading the Upgrade.md file of guzzlehttp/guzzle library, it states that from 6.0:
- Guzzle now uses `Psr\Http\Message\UriInterface` (implements in
`GuzzleHttp\Psr7\Uri`) for URI support. `GuzzleHttp\Url` is now gone.
But neither `Psr\Http\Message\UriInterface` nor `GuzzleHttp\Psr7\Uri` can be considered drop-in replacements as they don't implement static `fromString` or `combine` methods.
Remaining tasks
User interface changes
API changes
Data model changes
| Comment | File | Size | Author |
|---|---|---|---|
| #8 | pubsubhubbub-disabled.png | 38.27 KB | megachriz |
Issue fork feeds-3341361
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
megachrizIn the approximately 10 years that I now work on Feeds, I never got into figuring out how to use PubSubHubbub, so I can imagine that this part of Feeds could be broken. It is quite probable that there's no good test coverage for it.
Do you use PubSubHubbub? If so, you're welcome to become co-maintainer of Feeds just to maintain this part.
Comment #3
idiaz.ronceroI was trying to get a Youtube feed. Feeds Youtube seems abandoned (and is not working) and Youtube Import is a standalone solution that has no integration with Feeds and thus lacks some of its power (mappings, etc).
I found that YouTube somehow still supports PubSubHubbub channels (it's hidden, but exists) and then tried to use this part of the Feeds module, and this is when I hit with this problem.
For the time being I'm actually working on a patch (or an alternative) to Feeds Youtube since using Youtube API V3 seems to be the most reliable and long-term supported solution.
And no, I haven't the faintest idea about how Pubsubhubbub is supposed to work, sorry.
So... unless more people complains about PubSubHubbub not working, I think maybe the best solution is to skip this issue as Closed / Won't fix (or even remove pubsubhubbub completely!) and focus on more modern, contemporary solutions to the problem.
Comment #4
kopeboyNever used PubSubHubbub either but it actually might be worth to still support it since there are some "recent" (in W3C terms and relative to relevant issues on this module) news.. check "WebSub" (linked from here) which is a W3C Recommendation from 23 January 2018. The interesting part should be that it uses HTTPS Webhooks, but since I'm a noob developer I don't know what that means for Drupal (specifically how they interact with / if they require Cron).
I found this video "Drupal Webhook Entities / DrupalCon Global 2020" to be very informative.
Comment #5
megachrizThis now also comes up in PHPStan reports. I'm going to disable the feature in the UI for now.
Comment #8
megachrizThe option "Use PubSubHubbub" is now disabled in the UI and a link to this issue is added underneath:

I also checked Drupal 8.0.0 and I saw that GuzzleHttp\Url was already gone in there. So apparently this feature is broken in Feeds 8.x-3.x for many years (Drupal 8.0.0 was released 8.5 years ago). So it looks like that not a single Feeds 8.x-3.x user is using PubSubHubbub currently. Or they fixed it without reporting or giving back. So that would make this feature candidate from being removed from Feeds in the future, if still no one cares about it.