When I went to school at least, starting grade 10 it was up to you. If you missed too many classes without valid excuse, you got kicked out of class, and had to take the class again next semester / year if you wanted to graduate. Teachers didn't give a shit, because we were all 15+ by then, so all big boys who can make our own decisions. If you didn't want to be there, they didn't want you there, because you'd be disrupting the kids who actually wanted to learn.
Then I moved to Texas for grade 11, and it was lockdown at 7:30am with security guards wandering the halls, and me having to get written permission from the teacher to take a piss during class. Talk about a change of pace.
Yeah. Most state laws now say that all children age 7-18 are to attend school everyday. I think generally a student is considered truant if they have missed 3 unexcused/unverified days in a row, 5 unexcused/unverified days in a semester, or 7 unexcused/unverified days in a school year.