when i was much younger about 6 i used to get up and pee in the middle of the night so many times back to back to back probably an hour straight of me just walking back and forth to the bathroom to try and while i knew i eventually wasnt peeing anymore when i got up to go i also knew i had to continue to get up and go  now that im older i still like to be the last one to pee before bed like if i go to the bathroom and pass my partner in the hall as im on my way back to the bedroom i have to go again before bed if i go to the bathroom and then lay in bed and scroll on my phone for say 10 minutes i need to get up to go again before i sleep i also find myself doing this before i leave the house and overall i think it stems from anxiety some nights ill go to the bathroom get a sip of water scroll for a couple of minutes on my phone and sleep just fine but if i have an alarm set i feel like i have to go right before i sleep or else i worry ill wake up to go and interrupt my sleep and in terms of before leaving the house i think that that stems from anxiety that i may not have a bathroom available while out  just for funsies if you can wrap your head around it - my partner who god bless is so patient with me and doesnt make me feel like shit for doing all my weird shit - will sit on the couch and watch a movie with me get up get ready for bed and just get in bed to sleep without even trying can you even the first time i ever witnessed it i was so genuinely confused and when i questioned it all i got was no why would i try if i dont have to go im still shook every time it happens