The .session file is likely outdated or incompatible with your script's version of Pyrogram or Telegram. To fix this, try deleting the .session file, and run the script again to create a new session file (which should be compatible). Also, make sure all the fields in the .json file are correctly filled.