I've been playing around (as usual) in my worlds and I mostly give myself strength 255 and night vision by commands also putting true NBT at the end. Whenever I go through End Portal to exit, I lose all my effects. Here are the commands I entered:
/effect give @s night_vision 99999 99 true
/effect give @s strength 99999 255 true
Linked issues
Comments

Thank you for your report!
However, we are already tracking this issue, and this report is a Duplicate of MC-6431, which is a report that has not been resolved yet.
If you want, you can upvote the parent ticket, and enable watching to receive any updates about it - if you believe you have any information that may be important for this issue, please leave a comment on the parent. Please also use the search function in the future to prevent duplicate reports.
Quick Links:
📓 Issue Guidelines – 🛠 Community Support – 📧 Customer Support – ✍️ Feedback and Suggestions – 📖 Game Wiki
💬 Mojira Subreddit – 💬 Mojira Discord