Closed Karmenzind closed 3 years ago
The doc https://godoc.org/github.com/shirou/gopsutil/v3/process#Process.MemoryInfo said this function will return Swap value.
This function invoked fillFromStatmWithContext https://github.com/shirou/gopsutil/blob/478eb4c76adf46eb175d1c729e25d0993ee418f3/process/process_linux.go#L735 and this method didn't collect the Swap value after initialization so it will always be zero.
fillFromStatmWithContext
Please at least delete the "Swap" from the doc because this bug exists from a long time ago.
Thank you so much! You are correct, it does not return Swap information.
And psutil removes memory_info_ex and adds memory_full_info. We should align those but not scheduled yet.
The doc https://godoc.org/github.com/shirou/gopsutil/v3/process#Process.MemoryInfo said this function will return Swap value.
This function invoked
fillFromStatmWithContext
https://github.com/shirou/gopsutil/blob/478eb4c76adf46eb175d1c729e25d0993ee418f3/process/process_linux.go#L735 and this method didn't collect the Swap value after initialization so it will always be zero.Please at least delete the "Swap" from the doc because this bug exists from a long time ago.