Just for information if you are planning getting a re-entry permit for your visa at Chiang Mai Airport its not open 24 hours and literally nobody here has heard of a re-entry permit anyway. There office that issues it is working Government hours not 24 hours as was mentioned on another post here.
TLDR : Answer Summary
This discussion highlights the current situation regarding obtaining a re-entry permit at Chiang Mai Airport. The airport does not issue re-entry permits outside of government operating hours, and recent comments indicate that there are no international flights operating from Chiang Mai at the moment. Consequently, it is suggested to obtain a re-entry permit in Bangkok instead, as Chiang Mai Airport may not provide this service currently due to lack of international travel.