Recursive check for locked files
Bugs:


After building your list, you throw it away without printing anything (and if not, please supply all your code)


Minor:


pathlib >>> os. It leads to much better readable code, and less boilerplate.
is_locked=list() should be: is_locked = [] Note spaces and the literal.
pf.close() isn't a reliable statement. Instead, consider using something like with open(full_filename) as pf: pass
"path/to/directory" is a magic variable. Make it a global constant instead.
Use a if __name__ == "__main__": guard. Always.


Are you going to manually unlock all the files?

If not, you can just break after the first error and inform the user.