my login page code is not working and ideas how to fix it? Python

You need to define 'found' before your loop, best as 'False'.

import time as t
f_content = open("info.txt",'r').read()
while True:
    username = input("Username:")
    password = input("Password:")
    infos = [username,password]
    found = False
    for user in f_content:
        user_info = user.split(":")
        if user_info == infos:
            found = True
            print("Successfully logged in!")
            #some code

    if not found:
        print("User was not found!\nWait 20 seconds to reset")
        t.sleep(20)