pluggy currently offers only tryfirst and trylast booleans to control hook order, which remains arbitrary within each of the three categories. Some users want to declare that their hookimpl must run before or after a specific other plugin or hookimpl, and so several pytest issues conclude that the fix (if any) belongs in pluggy:
Personally I'm inclined to close this issue as wontfix, because it's absolutely classic "what if two programs did this" fodder. Even if we proposed to error on such cases and do a fancy toposort on the rest, I don't think it'd be worth the complexity.
pluggy currently offers only
tryfirstandtrylastbooleans to control hook order, which remains arbitrary within each of the three categories. Some users want to declare that their hookimpl must run before or after a specific other plugin or hookimpl, and so several pytest issues conclude that the fix (if any) belongs in pluggy:before=/after=ordering relative to named plugins._HookCaller._nonwrappers(private API), which shows people already reach for unsupported internals to get this.Personally I'm inclined to close this issue as wontfix, because it's absolutely classic "what if two programs did this" fodder. Even if we proposed to error on such cases and do a fancy toposort on the rest, I don't think it'd be worth the complexity.