If a plugin registers itself as of PType 'block', paragraph tags are incorrectly inserted within its output before and after nested inline (PType 'normal') syntax modes.
The block handler isn't able to differentiate between plugin instructions that require paragraph tags and those that don't. The information isn't there.
One Possible Solution:
Add some extra information to the plugin instruction - something equivalent to the $mode parameter passed to the plugin's handler() method. ENTER & SPECIAL would be treated as 'block_open' instructions, EXIT & SPECIAL as 'block_close' instructions. MATCHED & UNMATCHED would be skipped. Or perhaps simplified to P_OPEN = 2, P_CLOSE = 1, P_SKIP = 0, P_BOTH = (P_OPEN | P_CLOSE) = 3.
This information could be added by the Doku_Handler->plugin() method or be added to the information the plugin's handler() method must return.
I can sort a patch out for one of these if its ok.