I don't remember exactly when the Vista-20P came out, but I'm pretty sure it was sometime in the mid- 2000s. It sounds like you have an earlier Vista-20 or Vista-20SE, and your KP's address of 31 is correct.
I'm afraid I misspoke before: Unless you have two partitions in your system, then your Master Code is User 01. If your fob is programmed as User 02, then it's arming and disarming Partition #2, even if there are no zones programmed for Partition 2. You might find you can "Arm" with your fob, but wait a minute to let the Exit Delay run out, then open your usual entry door and see if that trips the Entry Delay. I'd guess it won't.
Program the fob as User 01 and see if that clears the problem. If it doesn't, then post back and we'll try something else, like re-programming your Master Code (for Partition 1).
I gather that you have only the one KP, so it's a safe bet that your system uses only one partition, like 99% of the systems out there. If you have a 2nd partition, now would be the time to mention it. If you don't even know what I'm talking about, then good: It's an even safer bet that there's only one partition and you don't have to worry about it.
You apparently have an Installation and Programming Manual, since you've done programming. But if you have a Vista-20P manual, then you need to download a Vista-20 or Vista-20SE Installation and Programming Manual. The "P" manual can actually be used for most fields, but you're programming something where the parameters changed with the zones and codes of the "P" Model.
https://alarmhow.net/manuals/Ademco/Control Panels/Vista-20/Vista-20SE Installation Manual..pdf
And no, KP address 31 and Zone 31 have nothing to do with each other and don't affect each other.
I strongly recommend:
DO
NOT test your codes by trying to Arm the system!!
A rule of thumb of code-setting/changing in NEVER Arm the system unless you
know you have a working User Code to disarm. That's why I always set at least one Secondary User Code, i.e., a User # 3 or more. About once a month, on average, someone Arms their system and can't Disarm it because there are ways to arm the system without a User Code. Once the system is Armed, you can't get into programming without Disarming it first, so it becomes an order of magnitude harder to work with it if you don't have a valid User Code.
Test new codes by entering [CODE + 6] to toggle the Chime function on and off. If it toggles the Chime, it will Arm and Disarm the system. Once you've confirmed a Code is valid and working, THEN you can Arm & Disarm with it.
Another thing: Don't be cute and try to make the Installer Code and Master Code the same code. The system won't allow duplicate codes and you _could_ wind up with an Armed system you can't Disarm without a
lot of bother.