To reproduce this bug, you need to create a block tag within a custom datapack and obtain a pickaxe whose "can_break" component references this tag.
At this point, two distinct bugs may occur through different approaches:
If you disable the datapack without attempting to mine any blocks beforehand, the pickaxe will be able to break one qualifying block but fails to destroy it or generate any dropped items.
If you disable the datapack after having attempted to mine, the pickaxe will successfully break one qualifying block but will subsequently be unable to mine blocks elsewhere. Other abnormally obtained pickaxes with this issue also cannot mine any block. After breaking the block and generating items, the player will be kicked from the save, producing the error message: "Internal Exception: io.netty.handler.codec.DecoderException: Failed to decode packet 'clientbound/minecraft:container_set_slot' ". (Plus, mining progress freezes when you stop mining, and can be resumed anytime)
Haven’t tested in multiplayer servers.
(I think it’s a big issue. hope it fixed before 1.21.6 release)
Environment
Vanilla with datapack (simply providing block tag)
Duplicate:MC-272908 A similar error is being dealt with here.