I was running into the same issue. Turns out my user wasn't the "Account Holder" (you can see that in the AppStore Connect = "User and Access" screen) so I couldn't agree to the terms myself.
The "Account Holder" user could login and accept the terms.
Topic:
App Store Distribution & Marketing
SubTopic:
App Review
Tags: