This is a new bug that is specific to using spectator mode to travel to other players. It wasn't in earlier version, probably like 1.19. You lose effects when spectating another player in different dimension. see clip. https://clips.twitch.tv/HeadstrongVivaciousLegOSkomodo-nnH-8yeykyc5sRrn
Related issues
Comments


Thank you for your report!
We're tracking this issue in MC-124177, so this ticket is being resolved and linked as a duplicate.
If you would like to add a vote and any extra information to the main ticket it would be appreciated.
If you haven't already, you might like to make use of the search feature to see if the issue has already been mentioned.
Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki
-- I am a bot. This action was performed automatically! The ticket was resolved by one of our moderators, and I left this message to give more information to you.

please reopen as it's not the same as MC-124177 this uses spec gamemode. This is new to recent versions afaik.

This has happened regardless of game mode for years. Nothing about this is new.

please reopen as this is a new bug that is specific to using spectator mode to travel to other players. It wasn't in earlier version, probably like 1.19.

Just because it has slightly different reproduction steps, doesn't mean it's a different bug.
Duplicate of MC-124177.