You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It appears that disk_usage (path) does not report the size of the directory tree in the specified path but instead reports the size of the partition | mountpoint that contains the path.
This is not what I expected and the current documentation does not describe this behavior:
psutil.disk_usage(path)[source] Return disk usage statistics about the given path as a named tuple including total, used and free space expressed in bytes, plus the percentage usage. OSError is raised if path does not exist.
I suggest updating the documentation to make it clear that you do not get the disk used by the 'path'.
Better still, modify code to actually report the disk used by the path - like du command
Bill
The text was updated successfully, but these errors were encountered:
Return disk usage statistics about the partition which contains the given path as a named tuple including total, used and free space
expressed in bytes, plus the percentage usage.
It appears that disk_usage (path) does not report the size of the directory tree in the specified path but instead reports the size of the partition | mountpoint that contains the path.
This is not what I expected and the current documentation does not describe this behavior:
psutil.disk_usage(path)[source]
Return disk usage statistics about the given path as a named tuple including total, used and free space expressed in bytes, plus the percentage usage. OSError is raised if path does not exist.
I suggest updating the documentation to make it clear that you do not get the disk used by the 'path'.
Better still, modify code to actually report the disk used by the path - like du command
Bill
The text was updated successfully, but these errors were encountered: