What happens is that both states want income tax like you lived in the state for the full year.
[0]https://www.maine.gov/revenue/faq/income_faq.html#faq1040_4
This 'audit' has been happening in states with lots of mobile high earners (CA and NYS) for awhile. Other states are catching on, and now doing the same.
I was honestly just happy to pay it and get it over with.