I wanted to get file's inode in my windows machine, so first I tried os.stat('./filename.txt').st_ino
in my REPL and the output I got was 0L
.
I tried the same for a couple of other files and got the same output.
Then, I tried
os.fstat(open("filename.txt", "r").fileno()).st_ino
and I got a long integer in output. For different files the integer was getting changed. So, I think os.fstat worked for windows while os.stat did not. Can someone explain to me the reason for this behavior and other differences between both?