I agree with the other top-level comment next to yours (at the time of writing): when we're willing to enforce consequences for them in the same way we would for people. If I violate laws, I can get put in jail, and then I (most likely) can't use any computers until I get out. To consider an AI a person, it needs to have legal liability in the same way a fleshy person does.
Being a legal person is not a logical prerequisite for being named as an inventor on that argument alone, because there's not a legal liability that stems from being named as an inventor.
(That's not to say AI should or should not be capable of being named as an inventor).