#[feeless_if(..)]
breaks when used in a #[pallet_section]
#5981
Labels
I2-bug
The node fails to follow expected behavior.
I10-unconfirmed
Issue might be valid, but it's not yet known.
Is there an existing issue?
Experiencing problems? Have you tried our Stack Exchange first?
Description of bug
Right now one of the bugs with
#[pallet_section]
is if the external pallet section has a#[feeless_if(..)]
anywhere in it, for some reason this causes a string of compile errors. A recent example is here but it is quite easy to reproduce: https://github.com/opentensor/subtensor/actions/runs/11215301673/job/31172208884#step:6:1609I imagine this has something to do with how
feeless_if
is implemented interfering in some way with themacro_magic
import_tokens_attr
call. In theory this sort of thing should never happen so my guess is there is something weird going on in the parsing/expansion code forfeeless_if
, but I have not had a chance to look at it in depth.debugging steps I would take would be:
#[feeless_if(..)]
, see if you can print something to the terminal from there and use bisection to figure out where the compile error is originating fromSteps to reproduce
#[pallet_section]
#[import_section]
#[feeless_if(..)]
#[pallet::pallet]
macro invocation site.The text was updated successfully, but these errors were encountered: