this bug is related to MC-171739, i also believe that this was an issue since MC-171739 was fixed (in 20w27a); however i only test this in 1.19.4 and 1.20-rc1.
when you right-left clicking at the same on a block that both the block at the top and the bottom of the block is bamboo, and the top and the bottom is different thickness while holding a bamboo, it will make a glitched bamboo where the top and the bottom have different thickness.
step to reproduce: there are 2 ways to reproduce this:
option 1:
step 1: place a bamboo on the ground.
step 2: apply bone meal twice on it, if the bamboo is 4-block-tall or more, remove the bamboo and return back to step 1, else if the bamboo is 3-block-tall, right-click and left-click on the 2nd bamboo at the same time while holding a sand.
step 3: apply bone meal on the top bamboo
step 4: right-click and left-click on the sand at the same time while holding a bamboo -> you will make a glitched bamboo.
option 2:
step 1: place a bamboo on the ground.
step 2: apply bamboo 2-3 times on it.
step 3: place the sand on top of it.
step 4: place the bamboo on top of the sand, then apply bone meal on it.
step 5: right-click and left-click on the sand at the same time while holding a bamboo -> you will make a glitched bamboo.
Can confirm in 1.20