lemon24 / reader

A Python feed reader library.
https://reader.readthedocs.io
BSD 3-Clause "New" or "Revised" License
444 stars 37 forks source link

Consider using pluggy for plugin management #329

Open lemon24 opened 10 months ago

lemon24 commented 10 months ago

https://pluggy.readthedocs.io/

Pros:

Cons:

lemon24 commented 5 days ago

I had another look at pluggy, and confirm the pros still stand.

However, the following two cons remain:

  • update-style hooks where we continue to run after failure may be fiddly to implement
  • requests wrapper style hooks where the return value from a plugin is passed to the next plugin might be fiddly to implement

As far as I can see, the calling logic is buried deep within the codebase, so it likely can't be / isn't meant to be changed.

There's also https://github.com/pytest-dev/pluggy/issues/419 says collecting exceptions is out of scope, but it also mentioned further down that it may be solved in https://github.com/pytest-dev/pluggy/issues/321; it may be worth describing the reader usage patterns in that issue?