This is how Line of Sight works with temporary objects like ice blocks and is not a bug.
Continue reading ยป
Some users have reported issues with line of sight on Ice Blocks during the Sindragosa encounter in Icecrown Citadel on the Wrath of the Lich King Classic PTR. Blizzard has offered some clarity around the confusion, explaining that if you are auto attacking from behind the Ice Block, you won't be granted line of sight to avoid mechanics.