Your domicile (which determines residency) is dependent on a number of factors:
1. Where you have registered to vote,
2. Where you have a drivers license,
3. Where you tell people to mail things to you.
4. Where you own property,
5. Where you have a landline (as if anyone does that any more),
6. Where you plan to return to when you finish a temporary job elsewhere.
and a number of other factors...
Based on what you have said, you are not a resident of the state you were temporarily working in.
P.S. be sure to enter your permanent address in the Personal Info or My Info, because the IRS needs to know where you will pick up your mail in case they need to mail you anything.
**Mark the post that answers your question by clicking on "Mark as Best Answer"